ament / ament_lint

Apache License 2.0
38 stars 107 forks source link

Fix exclude regression #387

Closed methylDragon closed 2 years ago

methylDragon commented 2 years ago

This PR fixes https://github.com/ament/ament_lint/issues/382 by explicitly adding any exclude args in the flake8 config file (normally configuration/ament_flake8.ini) to the exclude arglist.

Notably, this uses the same parsing logic that the version of flake8 ROS is using on focal and jammy (3.9.7 and 4.0.0). I tried to account for differences in the parsing logic between 3.9.7 and 4.0.0 with a try except clause.

methylDragon commented 2 years ago

Demonstration of fix, with flake8 lint errors in listener*.py and talker*.py

image

methylDragon commented 2 years ago
methylDragon commented 2 years ago

Single quotes!! :fist_raised: :fist_raised: :fist_raised:

methylDragon commented 2 years ago

Unstable windows build is unrelated to this PR

methylDragon commented 2 years ago

I've reordered the try-except.

Testing on both jammy and focal since it matters due to the API breaking change for flake8.

Jammy:

Focal:

methylDragon commented 2 years ago

Unstable focal aarch64 build is unrelated to this PR