Skip to content

Comments

Fix/formatting#2775

Open
galenlynch wants to merge 2 commits intoAllenInstitute:masterfrom
galenlynch:fix/formatting
Open

Fix/formatting#2775
galenlynch wants to merge 2 commits intoAllenInstitute:masterfrom
galenlynch:fix/formatting

Conversation

@galenlynch
Copy link
Contributor

@galenlynch galenlynch commented Feb 21, 2026

Summary

Run auto-formatting and suppress known flake8 warnings.

Linked issue(s)

Code quality fix - no related issue

Change type

  • Bug fix (non-breaking change)
  • Security fix
  • Documentation update
  • Test-only change
  • Compatibility update (non-breaking)
  • New feature (community-contributed)
  • Breaking change

Maintenance mode acknowledgement

  • I have read the maintenance mode policy and understand that changes with high long-term maintenance cost may be declined.

What changed

  • Configure line length to be 120 given the many long lines in this repo
  • Run ruff format
  • Suppress remaining but harmless flake8 warnings
    • Add ambiguous variable and function names (E742, E743) to suppression list, not suited to this repo
    • Add E742 and E743 to ignore list — ambiguous variable names are OK in math-y code
    • F841 — Unused variables (8) These are all tuple unpacking with _-prefixed names like _i_prev, _t_prev, _r_prev and except Exception as _:. The convention communicates intent.
    • F401 — Unused imports (14) These are re-exports in __init__.py files,
      moviepy.editor import * for side effects, and json_utilities re-export. Standard
      pattern.
    • E721 — Type comparison (15) Most are type(self) != type(other) in __eq__ methods
      or exact type dispatch where isinstance would have different semantics (matching
      subclasses)

Validation

Ran all tests and notebooks locally.

Test evidence

  • Unit tests added/updated
  • Integration tests added/updated (if applicable)
  • Local test run passed
  • CI checks passed

Compatibility and risk

  • Backward compatibility impact: None
  • Dependency/platform impact: None

Checklist

  • I followed the contribution guide
  • My changes are scoped and focused
  • I added/updated tests appropriate for this change
  • I ran relevant tests locally
  • I updated documentation/docstrings where needed
  • I performed a self-review
  • My PR targets the master branch

Additional notes

Did not suppress many meaningful lint warnings in the code base, like F821, which will cause runtime errors if that code is ever run.

Clears ~15,000 flake8 warnings
Add E742 and E743 to ignore list - ambiguous variable names are OK in math-y code

F841 — Unused variables (8) These are all tuple unpacking with _-prefixed names
like _i_prev, _t_prev, _r_prev and except Exception as _:. The convention
communicates intent.

F401 — Unused imports (14) These are re-exports in __init__.py files,
moviepy.editor import * for side effects, and json_utilities re-export. Standard
pattern.

E721 — Type comparison (15) Most are type(self) != type(other) in __eq__ methods
or exact type dispatch where isinstance would have different semantics (matching
subclasses)
@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

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.

1 participant