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

Release v1.1.2 #53

Merged
merged 7 commits into from
Dec 17, 2019
Merged

Release v1.1.2 #53

merged 7 commits into from
Dec 17, 2019

Conversation

sco1
Copy link
Owner

@sco1 sco1 commented Dec 10, 2019

[v1.1.2]

Changed

  • Request source from flake8 as lines of code rather than parsing it from the requested filename ourselves, allowing for proper parsing of stdin inputs
  • Remove flake8-string-format from dev dependencies, as str.format() isn't used anywhere

Fixed

This also adds some tox/CI related changes & cleanup.

Closes #52
Closes #48

Add tox to the dependabot exclusions for the same reason as the other ignored dev dependencies: they are already pinned fairly liberally so we don't need to keep up with every minor version.
Previously, when the checker instance is created it requested the filename from flake8 in order to load the source and parse to obtain a typed AST, as the flake8 provided AST is not guaranteed to contain type information. While sufficient for parsing files, this falls apart when attempting to parse code piped to stdin & causes our plugin to error out.

To mitigate these issues, the source is requested from flake8 as lines (list of strings), which is joined & passed into the typed AST generation rather than farming to a file IO task. This also allows us to drop the request for the AST from flake8 that we don't use, as requesting the lines will ensure that the plugin is registered.

The related test helpers have been updated to accommodate the change in instantiation.

Closes #52
@sco1 sco1 added this to the v1.1.2 milestone Dec 10, 2019
We don't use format strings anywhere
@sco1 sco1 marked this pull request as ready for review December 14, 2019 20:07
@sco1
Copy link
Owner Author

sco1 commented Dec 14, 2019

Opening for review to fix #52.

CI improvements still need to be worked on (namely #47), but this doesn't need to block a new release.

@sco1 sco1 merged commit b3cdb41 into master Dec 17, 2019
@sco1 sco1 deleted the v1.1.2-dev branch December 17, 2019 23:34
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.

The plugin fails when flake8 is invoked with stdin Leverage tox in CI
3 participants