-
Notifications
You must be signed in to change notification settings - Fork 105
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
Fix compatibility with flake8 version 5 #410
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This patch fixes the issues for us on flake8 5.0.4 from nixpkgs. 👍 |
clalancette
approved these changes
Jun 6, 2023
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks reasonable to me. I'll run CI on it next.
The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org>
Signed-off-by: Timo Röhling <roehling@debian.org>
The aarch64 warning is a known flake, so this looks good. I'll go ahead and merge it. |
emersonknapp
pushed a commit
to emersonknapp/ament_lint
that referenced
this pull request
Sep 5, 2023
This is a backport of ament#410 to Humble. When building on Ubuntu 20.04 Focal (Tier 3 support) and following the instructions in https://docs.ros.org/en/humble/Installation/Alternatives/Ubuntu-Development-Setup.html#install-development-tools-and-ros-tools for that platform, `flake8` is installed via `pip` and so is installed at the newer version 5. `ament_lint` then fails to run with: ``` /opt/ros/humble/install/lib/python3.8/site-packages/ament_flake8/main.py:150: in get_flake8_style_guide config_finder = config.ConfigFileFinder( E AttributeError: module 'flake8.options.config' has no attribute 'ConfigFileFinder' ``` This PR fixes that issue. * Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com>
emersonknapp
pushed a commit
to emersonknapp/ament_lint
that referenced
this pull request
Sep 5, 2023
This is a backport of ament#410 to Humble. When building on Ubuntu 20.04 Focal (Tier 3 support) and following the instructions in https://docs.ros.org/en/humble/Installation/Alternatives/Ubuntu-Development-Setup.html#install-development-tools-and-ros-tools for that platform, `flake8` is installed via `pip` and so is installed at the newer version 5. `ament_lint` then fails to run with: ``` /opt/ros/humble/install/lib/python3.8/site-packages/ament_flake8/main.py:150: in get_flake8_style_guide config_finder = config.ConfigFileFinder( E AttributeError: module 'flake8.options.config' has no attribute 'ConfigFileFinder' ``` This PR fixes that issue. * Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com> Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
emersonknapp
pushed a commit
to emersonknapp/ament_lint
that referenced
this pull request
Sep 6, 2023
This is a backport of ament#410 to Humble. When building on Ubuntu 20.04 Focal (Tier 3 support) and following the instructions in https://docs.ros.org/en/humble/Installation/Alternatives/Ubuntu-Development-Setup.html#install-development-tools-and-ros-tools for that platform, `flake8` is installed via `pip` and so is installed at the newer version 5. `ament_lint` then fails to run with: ``` /opt/ros/humble/install/lib/python3.8/site-packages/ament_flake8/main.py:150: in get_flake8_style_guide config_finder = config.ConfigFileFinder( E AttributeError: module 'flake8.options.config' has no attribute 'ConfigFileFinder' ``` This PR fixes that issue. * Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com> Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
emersonknapp
pushed a commit
to emersonknapp/ament_lint
that referenced
this pull request
Sep 14, 2023
* Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com>
emersonknapp
pushed a commit
to emersonknapp/ament_lint
that referenced
this pull request
Sep 14, 2023
* Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com> Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com>
clalancette
added a commit
that referenced
this pull request
Sep 20, 2023
#451) * Fix exclude regression (#387) * Fix compatibility with flake8 version 5 (#410) * Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com> Signed-off-by: Emerson Knapp <emerson.b.knapp@gmail.com> Co-authored-by: methylDragon <methylDragon@gmail.com>
@Mergifyio backport iron |
✅ Backports have been created
|
mergify bot
pushed a commit
that referenced
this pull request
Dec 20, 2023
* Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com> (cherry picked from commit 6adf864)
clalancette
pushed a commit
that referenced
this pull request
Dec 21, 2023
* Fix compatibility with flake8 version 5 The ConfigFileFinder class no longer exists in flake8 version 5. The get_style_guide() code has been updated from the latest api.legacy.get_style_guide() in flake8. Signed-off-by: Timo Röhling <roehling@debian.org> Co-authored-by: Chris Lalancette <clalancette@gmail.com> (cherry picked from commit 6adf864) Co-authored-by: Timo Röhling <timo@gaussglocke.de>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The
ConfigFileFinder
class no longer exists in flake8 version 5. Theget_style_guide()
code has been updated from the latestapi.legacy.get_style_guide()
in flake8.