refactor: move all data.lib top-level functions to subcategories#1691
refactor: move all data.lib top-level functions to subcategories#1691dheerajodha merged 2 commits intoconforma:mainfrom
Conversation
st3penta
left a comment
There was a problem hiding this comment.
It would be better to reduce the amount of stuff that ends up in the utils dir, and use meaningful subfolders where possible, even if they have one file each.
I think we could even completely avoid it, if we add these packages:
- assertions
- metadata
- rule_data
- sets
- sigstore
- strings
- volatlie
Codecov Report✅ All modified and coverable lines are covered by tests.
🚀 New features to boost your workflow:
|
|
Try |
|
Important Review skippedToo many files! This PR contains 173 files, which is 23 over the limit of 150. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (173)
You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
- Restructure lib.utils into meaningful subdirectories: - lib.assertions (test assertion helpers) - lib.metadata (policy result builders) - lib.rule_data (configuration data access) - lib.sets (set/array utilities) - lib.sigstore (sigstore configuration) - lib.strings (string helpers) - lib.volatile (volatile config lifecycle) - Replace import aliases with explicit package names for readability - Update 129 files to use specific package imports - Remove generic utils namespace to avoid anti-pattern Addresses code review feedback to improve code organization and readability by using self-documenting package names. resolves: EC-1651 Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
Remove unnecessary stderr redirections (2>&1 and 2>/dev/null) from TEST_CMD and COVERAGE_CMD. The mock functions in tests now properly prevent network calls, making error output suppression unnecessary. resolves: EC-1651 Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
simonbaird
left a comment
There was a problem hiding this comment.
It's gonna be more conflict pain the longer this stays unmerged. Feel free to merge early and make fixups in new PRs if needed.
|
Nice work! |
resolves: EC-1651