fix(config): support runok.yaml for global config file discovery#141
fix(config): support runok.yaml for global config file discovery#141
runok.yaml for global config file discovery#141Conversation
Global config was hardcoded to `runok.yml` while all other scopes (project, local override, global local override) supported both `.yml` and `.yaml` extensions via `find_config`. Unify the file discovery logic so all four config layers use the same approach. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request resolves an inconsistency in how global configuration files are discovered, previously limited to only Highlights
Changelog
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request effectively unifies the configuration file discovery logic to support both runok.yml and runok.yaml for the global configuration, making it consistent with other configuration scopes. The refactoring in DefaultConfigLoader simplifies the loading logic by introducing constants for filenames and a new find_and_parse helper function. The test suite has been significantly improved with better organization and expanded coverage for .yml/.yaml variants using rstest, which is great to see.
I have a few suggestions, primarily focused on further improving the tests by reducing duplication, in alignment with the repository's style guide. These changes should enhance the maintainability of the test suite.
The yml-takes-priority-over-yaml tests for global and project scopes were duplicated across main config and local override variants. Combine each pair into a single parameterized test to reduce duplication, following the project's test style guide.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #141 +/- ##
==========================================
- Coverage 89.98% 89.86% -0.13%
==========================================
Files 31 31
Lines 6469 6391 -78
==========================================
- Hits 5821 5743 -78
Misses 648 648
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Why
runok.yml, preventingrunok.yamlfrom being used.ymland.yamlviafind_config, but the global main config was inconsistentWhat
runok.yaml.yml/.yamlsupport and priority for all scopes in tests