Skip to content

Resolve chartboost/ruff-action@v1 violations across the repository - #301

Merged
martinpopel merged 7 commits into
masterfrom
copilot/omit-shebang-from-init-main
Aug 18, 2026
Merged

martinpopel merged 7 commits into
masterfrom
copilot/omit-shebang-from-init-main

Conversation

Copilot AI commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

This PR addresses repository-wide failures under chartboost/ruff-action@v1 by aligning code with Ruff auto-fixes and defining an explicit project lint baseline for non-actionable legacy patterns.

  • Ruff baseline configuration

    • Added [tool.ruff.lint] config in pyproject.toml with a focused ignore set for rules currently incompatible with existing architecture/patterns (B019, B020, PLR1704, PLW1508, RUF012, SIM115, SIM117, TRY002, TRY203).
  • Repository-wide autofix pass

    • Applied Ruff fixes across source and tests to normalize imports, typing syntax, and lint-detected style/structure issues that are safe to auto-remediate.
  • Post-autofix correctness cleanups

    • Corrected Dataset constructor handling for langpairs to avoid type-as-default misuse while preserving runtime behavior.
    • Removed dead no-op expression in TER metric utilities introduced by lint rewrite.
    • Added missing future-annotation handling where needed to keep updated typing syntax consistent.
[tool.ruff.lint]
ignore = [
  "B019", "B020", "PLR1704", "PLW1508",
  "RUF012", "SIM115", "SIM117", "TRY002", "TRY203",
]

Copilot AI and others added 6 commits August 18, 2026 11:16
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Co-authored-by: martinpopel <724617+martinpopel@users.noreply.github.com>
Copilot AI requested a review from martinpopel August 18, 2026 18:32
@martinpopel
martinpopel marked this pull request as ready for review August 18, 2026 19:22
@martinpopel
martinpopel merged commit e19573b into master Aug 18, 2026
31 checks passed
@martinpopel
martinpopel deleted the copilot/omit-shebang-from-init-main branch August 18, 2026 19:22
St4r4x added a commit to St4r4x/sacrebleu that referenced this pull request Aug 19, 2026
These files predate the repo-wide ruff cleanup (mjpost#301) merged into
master, so they were never covered by it. Modernizes typing (List/
Dict/Tuple -> builtin generics, Optional -> | None), sorts imports,
and simplifies a min() comparison. No behavior change.

This branch was successfully deployed

1 active deployment
release — 5fe4c8fb Deployed Aug 18, 2026 by Copilot via Build and publish Python distributions to PyPI #45
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.

2 participants