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

Failing pipeline due to new flake8-bugbear version #118

Closed
cr-xu opened this issue Jan 16, 2024 · 3 comments · Fixed by #119
Closed

Failing pipeline due to new flake8-bugbear version #118

cr-xu opened this issue Jan 16, 2024 · 3 comments · Fixed by #119

Comments

@cr-xu
Copy link
Member

cr-xu commented Jan 16, 2024

It looks like the pipeline is failing due to the new flake8-bugbear version.

This needs to be fixed before #94

@jank324
Copy link
Member

jank324 commented Jan 16, 2024

This is a bit weird. The flake8 warning is:

./cheetah/converters/dontbmad.py:429:35: B038 editing a loop's mutable iterable often leads to unexpected results/bugs

But I would argue that this loop doesn't actually edit its iterable 🤔

for property in properties:
    assert property in understood, (
        f"Property {property} with value {properties[property]} for element type"
        f" {properties['element_type']} is currently not understood. Other values"
        f" in properties are {properties.keys()}."

@cr-xu
Copy link
Member Author

cr-xu commented Jan 16, 2024

Looks like it's a common issue: PyCQA/flake8-bugbear#451
For now, shall we add --extend-ignore=B038 or just leave it until they update to fix this issue?

@jank324
Copy link
Member

jank324 commented Jan 16, 2024

Ignoring it is probably the way to go then, but I would ignore it inline.

@jank324 jank324 linked a pull request Jan 16, 2024 that will close this issue
14 tasks
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 a pull request may close this issue.

2 participants