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

Optimize the speed of parsing and comparing Versions #73

Open
ryanking13 opened this issue Jul 14, 2023 · 0 comments
Open

Optimize the speed of parsing and comparing Versions #73

ryanking13 opened this issue Jul 14, 2023 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@ryanking13
Copy link
Member

We parse and compare versions lots of times when searching for an appropriate package, but parsing and comparing Version (packaging.version.Version) is quite expensive.

See: #71 (comment)

So it would be nice to do some micro-optimizations for handling versions, such as (#71 (comment)):

If we want to go faster (no need to do it, just an idea). We can probably also subclass Version to something that has a frozen str and hash so it doesn't need to be re-computed at each dict comparison.

@ryanking13 ryanking13 added the enhancement New feature or request label Jul 14, 2023
@ryanking13 ryanking13 changed the title Optimize the speed of dealing with Version Optimize the speed of parsing and comparing Versions Jul 14, 2023
@ryanking13 ryanking13 added the good first issue Good for newcomers label Jul 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant