Refactor verify-action-build into modular package with tests#675
Open
Refactor verify-action-build into modular package with tests#675
Conversation
Split the 3068-line monolithic script into 15 focused modules organized by responsibility (GitHub client, action parsing, Docker building, diff engines, security analysis, PR extraction, etc.), extracted the inline Dockerfile to a standalone file, and added 112 unit tests. Generated-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Previously force_terminal=False was passed outside CI, disabling color on real terminals. Now we only override Rich defaults inside CI. Generated-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
RAT check failed because these empty files had no license header. Generated-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Member
Author
|
Hey @raboof -> since the tool has gone through a series of iterations and seems to be getting closer to regular maintenance - as asked in the #652 (comment), this one should make it far easier to review further changes. |
Replace `uv run utils/verify-action-build.py` with `uv run --directory utils verify-action-build` in README, PR template, CI workflow, and package docstring. Generated-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
uv run doesn't install console script entry points, so the --directory approach doesn't work. Keep a thin wrapper script with PEP 723 metadata that delegates to the package, preserving the original invocation that docs, CI, and users expect. Generated-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
5541d43 to
2a3532b
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
utils/verify-action-build.pyinto 15 focused modules organized by responsibilitydockerfiles/build_action.Dockerfilefilepyproject.tomlfilesModule structure
console.pyUserQuit,ask_confirm,link,rungithub_client.pyGitHubClientclass (gh CLI + REST API)action_ref.pyorg/repo@hash, extractinguses:refs, detecting action typeapproved_actions.pyactions.ymldatabase interactiondocker_build.pydiff_display.pydiff_js.pydiff_node_modules.pynode_modulescomparisondiff_source.pysecurity.pyanalyze_*security check functionspr_extraction.pydependabot.pyverification.pycli.pymain()entry pointTest plan
uv run pytest utils/tests/ -v)uv run pytest -v— 161 total)uv run verify-action-build <action_ref>🤖 Generated with Claude Code