Skip to content

Introduce lower bound on attrs version - #179

Merged
Karthik Nadig (karthiknadig) merged 1 commit into
microsoft:mainfrom
alcarney:attrs-min-bound
Mar 6, 2023
Merged

Karthik Nadig (karthiknadig) merged 1 commit into
microsoft:mainfrom
alcarney:attrs-min-bound

Conversation

@alcarney

@alcarney Alex Carney (alcarney) commented Mar 6, 2023 •

Copy link
Copy Markdown
Contributor

lsprotocol uses the import attrs API which was only introduced in v21.3.0 .

This PR sets a minimum version for attrs in the python package's pyproject.toml to hopefully guard against issues like this one in the future.

Question: Is it sufficient to rely on the version bound set here to ensure the correct version is also installed for pygls and esbonio? Or since both downstream packages also import attrs themselves, is it more correct to have a version bound set in both pygls and esbonio? 🤔

`import attrs` is only available in versions 21.3.0 and newer
@karthiknadig Karthik Nadig (karthiknadig) added the bug Issue identified by VS Code Team member as probable bug label Mar 6, 2023
@brettcannon

Copy link
Copy Markdown
Member

Question: Is it sufficient to rely on the version bound set here to ensure the correct version is also installed for pygls and esbonio?

Yes, as your installer's resolver will have to make sure that any version of a distribution that gets installed is compatible with all requirements for that distribution. Basically pip has to walk the dependency graph and make sure whatever it chooses to install for attrs satisfies every requirement it comes across.

@karthiknadig
Karthik Nadig (karthiknadig) merged commit 5778454 into microsoft:main Mar 6, 2023
@alcarney
Alex Carney (alcarney) deleted the attrs-min-bound branch March 6, 2023 22:05
@alcarney

Copy link
Copy Markdown
Contributor Author

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Issue identified by VS Code Team member as probable bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants