Skip to content

Conversation

@jameslamb
Copy link
Member

@jameslamb jameslamb commented Jan 27, 2026

Description

Moves ruff configuration into pyproject.toml.

I noticed this project has a .flake8, but doesn't actually run flake8 directly... I think the configuration in that .flake8 is getting ignored (based on https://docs.astral.sh/ruff/configuration/, I don't believe ruff reads .flake8 files).

This PR ensures ruff respects this project's configuration. Any other changes were made automatically by pre-commit hooks.

Issue

N/A

Notes for Reviewers

How I chose these checks

I only selected checks that flake8 would run.

I think it'd be worthwhile to expand this in the future, especially with (B) flake8-bugbear and (PERF) perflint. I'll leave that to you all in a follow-up if you'd like. Here's a list of rules I like to use in Python projects: https://github.com/jameslamb/pydistcheck/blob/3bf39fd2f0c9328e519b8892b6dfde029381d7a0/pyproject.toml#L133

Checklist

  • I am familiar with the Contributing Guidelines.
  • Testing
    • New or existing tests cover these changes
  • Documentation
    • The documentation is up to date with these changes

Summary by CodeRabbit

  • Chores

    • Removed flake8 configuration file and related ownership settings
    • Updated copyright year to 2026
  • Documentation

    • Updated CuOpt documentation version to 26.04.00
  • Style

    • Improved regex string literal formatting

✏️ Tip: You can customize this high-level summary in your review settings.

@jameslamb jameslamb requested review from a team as code owners January 27, 2026 18:26
@jameslamb jameslamb added non-breaking Introduces a non-breaking change improvement Improves an existing functionality labels Jan 27, 2026
@jameslamb jameslamb requested a review from tmckayus January 27, 2026 18:26
{
"version": "26.02.00",
"url": "https://docs.nvidia.com/cuopt/user-guide/26.02.00/",
"version": "26.04.00",
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change was made by just running pre-commit run --all-files. I'm not sure what's causing it.

@coderabbitai
Copy link

coderabbitai bot commented Jan 27, 2026

📝 Walkthrough

Walkthrough

The PR removes the flake8 configuration file and its references, migrates linting rules to ruff configuration in pyproject.toml, updates copyright year to 2026 across pre-commit and utility files, and updates CuOpt documentation version from 26.02.00 to 26.04.00.

Changes

Cohort / File(s) Summary
Linting Configuration Migration
.flake8, .github/CODEOWNERS, .pre-commit-config.yaml, pyproject.toml
Removed flake8 config file and CODEOWNERS reference. Expanded ruff-check arguments in pre-commit to include --config pointing to pyproject.toml. Added new [tool.ruff.lint] section with select and ignore rules, migrating from flake8-based linting.
Metadata & Utility Updates
ci/utils/nbtestlog2junitxml.py
Converted regex string literals to raw strings (STARTING, SKIPPING, EXIT CODE, FOLDER, real time patterns). Updated SPDX copyright year from 2025 to 2026.
Documentation Version
.pre-commit-config.yaml, docs/cuopt/source/versions1.json
Updated copyright year from 2025 to 2026 in pre-commit config. Updated CuOpt docs latest version from 26.02.00 (external URL) to 26.04.00 (relative URL); archived 26.02.00 as previous version.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: moving ruff configuration from .flake8 to pyproject.toml, which is the primary objective reflected in the file modifications.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

improvement Improves an existing functionality non-breaking Introduces a non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant