Skip to content

Fix ruff errors - #715

Merged
guillaume-vignal merged 28 commits into
MAIF:masterfrom
milton-minervino:fix/ruff-errors
Jun 11, 2026
Merged

Fix ruff errors#715
guillaume-vignal merged 28 commits into
MAIF:masterfrom
milton-minervino:fix/ruff-errors

Conversation

@milton-minervino

Copy link
Copy Markdown
Collaborator

Description

This PR deals with ruff linting errors. Originally, ruff check returns several errors. We solve them by refactoring all the necessary code.
Furthermore, we refactor and fix code to get rid of many ruff lint exceptions listed under [tool.ruff.lint.per-file-ignores] in pyproject.toml.

Fixes #587

Type of change

  • Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Pass all unit tests with pytest.

ruff check returns All checks passed!

Test Configuration:

  • OS: Linux (Ubuntu)
  • Python version: 3.12.3
  • Shapash version: 2.9.0

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

@milton-minervino milton-minervino self-assigned this Jun 9, 2026
it seems too heavy to use optional import logic in this case
deals with S310, B904 Ruff errors
resolves ruff error B028
deals with ruff error UP031
deals with ruff error PLW0127
deals with ruff errors S101
deals with ruff errors A002, E721
deals with A002 ruff error
deals with ruff errors A002, S307, E721, A001
deals with UP031 ruff error
however keep F401 for __init__ files
@milton-minervino
milton-minervino marked this pull request as ready for review June 9, 2026 15:27
@guillaume-vignal
guillaume-vignal merged commit 220a0d0 into MAIF:master Jun 11, 2026
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.

ruff warnings are ignored

3 participants