Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: simplify repodata_gateway function #1793

Merged
merged 1 commit into from
Jan 13, 2025

Conversation

olivier-lacroix
Copy link
Contributor

@olivier-lacroix olivier-lacroix commented Aug 12, 2024

A follow-up on #1767

@olivier-lacroix olivier-lacroix force-pushed the feat/repodata branch 2 times, most recently from 1ee0f1d to db009a4 Compare August 12, 2024 13:06
@olivier-lacroix olivier-lacroix marked this pull request as ready for review August 12, 2024 13:10
@olivier-lacroix
Copy link
Contributor Author

olivier-lacroix commented Aug 12, 2024

Progress report is not the best, as messages such as fetching repodata for environment can end up being displayed a fair few times. Is there a way to make this better?

@baszalmstra
Copy link
Contributor

Progress report is not the best, as messages such as fetching repodata for environment can end up being displayed a fair few times. Is there a way to make this better?

Yes but it requires implementing a Reporter.

@olivier-lacroix
Copy link
Contributor Author

@baszalmstra I am not sure what this entails. But it does not sound straightforward 🥲 . Is it worth it? Or should we pull the messaging out of the function and wrap it when / it needed where it is used?

@baszalmstra
Copy link
Contributor

Yeah that sounds fair! 👍

@olivier-lacroix
Copy link
Contributor Author

Yeah that sounds fair! 👍

Actually that does not work. Even with the messaging outside of the loop, the iterator is still there waiting... Reporter it is then :-)

@baszalmstra
Copy link
Contributor

Rattler-build has a custom implementation here: https://github.com/prefix-dev/rattler-build/blob/a28628bc6d29e227dffc1a64c27fa5f0b50f7dc9/src/render/solver.rs#L136

Its not great but might serve as inspiration!

@baszalmstra baszalmstra self-assigned this Aug 20, 2024
@tdejager
Copy link
Contributor

tdejager commented Sep 9, 2024

Hi guys! What is the status of this PR @olivier-lacroix @baszalmstra?

@olivier-lacroix olivier-lacroix changed the title refactor: factor gateway data fetch and solve into a function refactor: simplify repodata_gateway function Jan 12, 2025
@olivier-lacroix
Copy link
Contributor Author

olivier-lacroix commented Jan 12, 2025

Most of this PR has become irrelevant, due to numerous changes to pixi global. I have just kept a simple refactor of repodata_gateway function and reset the rest.

Note: not sure a trait is really needed to encapsulate that method?

Copy link
Contributor

@ruben-arts ruben-arts left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the cleanup!

@ruben-arts ruben-arts merged commit 4f622f5 into prefix-dev:main Jan 13, 2025
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants