Sort output when installing seed packages (#1822)

This output is technically non-deterministic right now.
This commit is contained in:
Charlie Marsh 2024-02-21 13:33:06 -05:00 committed by GitHub
parent 39ee3969d9
commit b4bc40627c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 2 deletions

View file

@ -6,6 +6,7 @@ use std::vec;
use anstream::eprint; use anstream::eprint;
use anyhow::Result; use anyhow::Result;
use chrono::{DateTime, Utc}; use chrono::{DateTime, Utc};
use itertools::Itertools;
use miette::{Diagnostic, IntoDiagnostic}; use miette::{Diagnostic, IntoDiagnostic};
use owo_colors::OwoColorize; use owo_colors::OwoColorize;
use thiserror::Error; use thiserror::Error;
@ -184,7 +185,10 @@ async fn venv_impl(
.await .await
.map_err(VenvError::Seed)?; .map_err(VenvError::Seed)?;
for distribution in resolution.distributions() { for distribution in resolution
.distributions()
.sorted_unstable_by(|a, b| a.name().cmp(b.name()).then(a.version().cmp(&b.version())))
{
writeln!( writeln!(
printer, printer,
" {} {}{}", " {} {}{}",

View file

@ -232,8 +232,8 @@ fn seed_older_python_version() -> Result<()> {
----- stderr ----- ----- stderr -----
Using Python [VERSION] interpreter at [PATH] Using Python [VERSION] interpreter at [PATH]
Creating virtualenv at: /home/ferris/project/.venv Creating virtualenv at: /home/ferris/project/.venv
+ setuptools==68.2.2
+ pip==23.3.1 + pip==23.3.1
+ setuptools==68.2.2
+ wheel==0.41.3 + wheel==0.41.3
Activate with: source /home/ferris/project/.venv/bin/activate Activate with: source /home/ferris/project/.venv/bin/activate
"### "###