Skip to content

Ruff and isort on whole project - #554

Open
dodu94 wants to merge 8 commits into
developingfrom
review
Open

dodu94 wants to merge 8 commits into
developingfrom
review

Conversation

@dodu94

@dodu94 dodu94 commented Oct 27, 2026

Copy link
Copy Markdown
Member

Some cleaning up powered by ruff and isort. A new check on PR is added to verify that ruff has been run on the new code.

@coderabbitai

coderabbitai Bot commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 35 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 53b82f99-a8a1-4cf9-a5e0-35df17f356b4
Commits

Reviewing files that changed from the base of the PR and between 76442ea and caa2b76.

Files selected for processing: 42
  • .github/workflows/lint.yml
  • .github/workflows/pytest.yml
  • .readthedocs.yaml
  • AGENTS.md
  • docs/source/conf.py
  • docs/source/requirements.txt
  • docs/source/usage/installation.rst
  • pyproject.toml
  • src/jade/app/app.py
  • src/jade/app/fetch.py
  • src/jade/config/atlas_config.py
  • src/jade/config/excel_config.py
  • src/jade/config/pp_config.py
  • src/jade/config/raw_config.py
  • src/jade/config/run_config.py
  • src/jade/config/status.py
  • src/jade/helper/__optionals__.py
  • src/jade/helper/aux_functions.py
  • src/jade/helper/openmc.py
  • src/jade/post/atlas.py
  • src/jade/post/excel_routines.py
  • src/jade/post/manipulate_tally.py
  • src/jade/post/plotter.py
  • src/jade/post/raw_processor.py
  • src/jade/post/sim_output.py
  • src/jade/run/benchmark.py
  • src/jade/run/input.py
  • tests/app/test_app.py
  • tests/config/test_atlas_config.py
  • tests/config/test_excel_config.py
  • tests/config/test_raw_config.py
  • tests/config/test_run_config.py
  • tests/gui/test_config_gui.py
  • tests/gui/test_post_config_gui.py
  • tests/helper/compatibility_scripts/convert_oktavian.py
  • tests/helper/compatibility_scripts/derive_iter1d_z_coordinates.py
  • tests/helper/test_auxiliary_func.py
  • tests/helper/test_openmc.py
  • tests/post/test_excel_routines.py
  • tests/post/test_plotter.py
  • tests/post/test_sim_output.py
  • tests/run/test_input.py
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

Critical dependency and D1S parsing issues remain, and GitLab connection handling is incomplete.

4 open issues
What changed in this PR

This pull request applies Ruff/isort-style cleanup across the project, updates dependency and documentation configuration, adds CI linting, and includes targeted fixes and regression tests.

Changes:

  • Reformats imports, expressions, type annotations, and dataframe handling across source and test modules.
  • Adds regression coverage for material headers, D1S irradiation handling, plotting, and tick labels.
  • Updates packaging metadata, supported Python versions, documentation installation, and CI workflows.
  • Adds Ruff checking and formatting validation to continuous integration.
File Summary Review
tests/​run/​test_input.py Adds material-header and D1S daughter regression tests. See related issue in src/jade/run/input.py.
tests/​post/​test_sim_output.py Cleans imports and formatting in simulation-output tests. No final comment.
tests/​post/​test_plotter.py Adds plotting and tick-label regression tests. No final comment.
tests/​post/​test_excel_routines.py Updates test typing and imports. No final comment.
tests/​helper/​test_openmc.py Separates standard-library and third-party imports. No final comment.
tests/​helper/​test_auxiliary_func.py Reformats imports and membership checks. No final comment.
tests/​helper/​compatibility_scripts/​derive_iter1d_z_coordinates.py Adds an ITER coordinate-derivation utility. No final comment.
tests/​helper/​compatibility_scripts/​convert_oktavian.py Removes an unused import. No final comment.
tests/​gui/​test_post_config_gui.py Reformats imports and spacing. No final comment.
tests/​gui/​test_config_gui.py Reformats conditional GUI imports. No final comment.
tests/​config/​test_run_config.py Removes an unused assignment. No final comment.
tests/​config/​test_raw_config.py Reformats imports and removes an unused assignment. No final comment.
tests/​config/​test_excel_config.py Simplifies extension matching. No final comment.
tests/​config/​test_atlas_config.py Simplifies extension matching. No final comment.
tests/​app/​test_app.py Removes an unused import and reformats comments. No final comment.
src/​jade/​run/​input.py Updates material-header construction and D1S reaction/irradiation handling. Critical: the specific-reaction path no longer appends the required library suffix before parsing daughter identifiers.
src/​jade/​run/​benchmark.py Removes redundant subprocess work and applies formatting changes. No final comment.
src/​jade/​post/​sim_output.py Refactors dataframe updates and output handling. No final comment.
src/​jade/​post/​raw_processor.py Cleans benchmark-selection logic. No final comment.
src/​jade/​post/​plotter.py Avoids mutating input data and improves tick handling. No final comment.
src/​jade/​post/​manipulate_tally.py Updates annotations and exception typing. No final comment.
src/​jade/​post/​excel_routines.py Updates dataframe renaming and MultiIndex handling. No final comment.
src/​jade/​post/​atlas.py Adds a shared default image-width constant. No final comment.
src/​jade/​helper/​openmc.py Simplifies dictionary operations and tally processing. No final comment.
src/​jade/​helper/​aux_functions.py Updates PathLike typing and exception handling. No final comment.
src/​jade/​helper/​__optionals__.py Adds import-lint suppressions and reformats logging. No final comment.
src/​jade/​config/​status.py Simplifies key iteration and boolean returns. No final comment.
src/​jade/​config/​run_config.py Removes an empty abstract-method body. No final comment.
src/​jade/​config/​raw_config.py Reorders imports. No final comment.
src/​jade/​config/​pp_config.py Simplifies YAML extension checks. No final comment.
src/​jade/​config/​excel_config.py Simplifies mapping membership checks. No final comment.
src/​jade/​config/​atlas_config.py Simplifies configuration validation. No final comment.
src/​jade/​app/​fetch.py Adds GitLab timeout and connection handling. Moderate: connection failures wrapped by python-gitlab can still escape the handler.
src/​jade/​app/​app.py Clarifies variable naming and benchmark iteration. No final comment.
pyproject.toml Raises the Python minimum, constrains dependencies, and separates optional groups. Critical: add pydata-sphinx-theme for the configured documentation theme and declare python-docx as a runtime dependency.
docs/​source/​usage/​installation.rst Updates Python support and installation guidance. No final comment.
docs/​source/​requirements.txt Removes the standalone documentation requirements file. No final comment.
docs/​source/​conf.py Removes an unused import. No final comment.
AGENTS.md Updates setup, architecture, branching, and CI guidance. No final comment.
.readthedocs.yaml Installs documentation dependencies from project metadata. Affected by the missing documentation theme dependency.
.github/​workflows/​pytest.yml Updates the OS/Python test matrix and coverage configuration. No final comment.
.github/​workflows/​lint.yml Adds Ruff checking and formatting validation. Nit: ruff check does not enable import-sorting rules without selecting I.

Review effort: Lite

Comment thread pyproject.toml
Comment thread pyproject.toml Outdated
Comment thread src/jade/run/input.py
Comment thread src/jade/app/fetch.py Outdated
@codecov

codecov Bot commented Oct 27, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 86.41975% with 11 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/jade/app/fetch.py 33.33% 4 Missing ⚠️
src/jade/helper/openmc.py 76.92% 3 Missing ⚠️
src/jade/run/benchmark.py 60.00% 2 Missing ⚠️
src/jade/helper/__optionals__.py 75.00% 1 Missing ⚠️
src/jade/post/manipulate_tally.py 50.00% 1 Missing ⚠️
Files with missing lines Coverage Δ
src/jade/app/app.py 83.78% <100.00%> (ø)
src/jade/config/atlas_config.py 93.10% <100.00%> (ø)
src/jade/config/excel_config.py 100.00% <100.00%> (ø)
src/jade/config/pp_config.py 100.00% <100.00%> (ø)
src/jade/config/raw_config.py 100.00% <100.00%> (ø)
src/jade/config/run_config.py 89.76% <ø> (+0.41%) ⬆️
src/jade/config/status.py 97.14% <100.00%> (+0.66%) ⬆️
src/jade/helper/aux_functions.py 95.78% <100.00%> (+0.99%) ⬆️
src/jade/post/atlas.py 85.71% <100.00%> (+0.34%) ⬆️
src/jade/post/excel_routines.py 96.56% <100.00%> (+0.36%) ⬆️
... and 9 more
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

dodu94 and others added 3 commits October 27, 2026 15:04
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
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