◐ Shell
clean mode source ↗

Update sysconfig from v3.14.3 and also fix _sysconfig by youknowone · Pull Request #7296 · RustPython/RustPython

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info

Configuration used: Path: .coderabbit.yml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d0b5a5a and 5a11f33.

⛔ Files ignored due to path filters (4)
  • Lib/sysconfig/__init__.py is excluded by !Lib/**
  • Lib/sysconfig/__main__.py is excluded by !Lib/**
  • Lib/test/test__osx_support.py is excluded by !Lib/**
  • Lib/test/test_sysconfig.py is excluded by !Lib/**
📒 Files selected for processing (3)
  • .gitignore
  • crates/vm/src/stdlib/sysconfig.rs
  • crates/vm/src/stdlib/sysconfigdata.rs

📝 Walkthrough

Walkthrough

This PR updates sysconfig configuration handling by replacing boolean literals with integer equivalents for Py_GIL_DISABLED and Py_DEBUG, adding runtime-dependent path variables (prefix, exec_prefix, BINDIR) to build-time configuration, and introducing ABIFLAGS constant. A .gitignore pattern is also added.

Changes

Cohort / File(s) Summary
Gitignore
.gitignore
Added ignore pattern for generated sysconfig JSON files (Lib/_sysconfig_vars*.json).
Configuration Values
crates/vm/src/stdlib/sysconfig.rs, crates/vm/src/stdlib/sysconfigdata.rs
Updated config flags from booleans to integers (Py_GIL_DISABLED: true→1, Py_DEBUG: false→0) and added runtime-dependent path variables (prefix, exec_prefix, BINDIR) and ABIFLAGS constant to build-time configuration.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

Poem

A rabbit hopped through configs with delight, 🐰
Swapping booleans for integers bright,
With paths and flags now set just right,
The sysconfig dances in Python's light! ✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 66.67% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title references updating sysconfig and fixing _sysconfig, which aligns with the actual changes: sysconfig.rs modifications, sysconfigdata.rs enhancements, and a .gitignore update for _sysconfig_vars*.json. However, the title is somewhat vague about what 'v3.14.3' refers to and what specific 'fix' is being applied.

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

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

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.