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

Pin dependencies to non-breaking version ranges #2773

Merged
merged 1 commit into from
Feb 28, 2019

Conversation

jab
Copy link
Contributor

@jab jab commented Feb 27, 2019

Pylint currently specifies unbounded versions of its dependencies. Assuming semver-compliant dependencies, this is dangerous because from one day to the next, your users can end up transitively picking up a breaking version of your dependencies. (This just happened to me via astroid.*)

This pins your dependencies within non-breaking version ranges to hopefully protect your users from breaking this way.

* The fact that astroid's minor version bump was a breaking change goes to show this isn't foolproof, but it's strictly an improvement over the status quo of having no bound whatsoever.

@@ -34,7 +34,7 @@
else:
version = string_version

install_requires = ["astroid>=2.2.0", "isort >= 4.2.5", "mccabe"]
install_requires = ["astroid>=2.2.0,<3", "isort>=4.2.5,<5", "mccabe>=0.6,<0.7"]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

mccabe is pinned more strictly (to within the same minor version) since it is a major version 0 package, which semver says may make breaking releases between minor versions.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It turns out astroid 2.2.0 was a breaking release over 2.1.0. Pinned to 2.1.0 in #2774.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.03%) to 89.728% when pulling 65fd34f on jab:patch-1 into dbc1df3 on PyCQA:master.

@PCManticore
Copy link
Contributor

Thanks @jab !

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.

3 participants