refactor: remove prevent-cli and flatten codecov-cli to repo root#709
Merged
Conversation
Remove the prevent-cli sub-project entirely and move every
codecov-cli/* file up to the repository root so codecov-cli is once
again a top-level Python project.
Layout changes:
- Delete prevent-cli/.
- git mv codecov-cli/{codecov_cli,tests,samples,pyproject.toml,
uv.lock,setup.py,MANIFEST.in,ruff.toml,codecovcli_commands,
README.md,LICENSE} to the repo root.
- Replace the prevent-cli root README and LICENSE with the
codecov-cli ones (they're identical, so LICENSE shows as a
pure delete + retained file).
Companion edits to make the flat layout build cleanly:
- Makefile: drop `cd codecov-cli` from `test`, point
`command_dump` at the new top-level command_dump.py.
- command_dump.py: restored at the repo root, dumps only
codecovcli (sentry-prevent-cli no longer exists).
- hooks/pre-commit: stop staging prevent-cli/preventcli_commands.
- .craft.yml: point at codecov/codecov-cli and drop the
sentry_prevent_cli targets.
- .github/workflows/broadcast_api_changes.yml: watch
codecovcli_commands at the root.
- .github/workflows/ci.yml: drop all prevent-cli/sentry-prevent-cli
jobs and `cd codecov-cli`, fix repository_owner == 'codecov'
so dogfood / codecov-startup jobs actually run.
- .github/workflows/build.yml: build codecov-cli only, from the
repo root (no more dual-CLI matrix or Cosign signing).
- .github/workflows/release-codecov-cli.yml: download/publish from
./dist instead of codecov-cli/dist.
- scripts/build_alpine.sh, scripts/build_linux.sh: rewritten to
build codecov-cli only out of the repo root with uv.
- scripts/{bump-version.sh,pre-build.sh,uv-installer-0.7.8.sha256sum}:
deleted (prevent-cli specific).
- tests/helpers/test_versioning_systems.py: update the exotic
filename assertion from `codecov-cli/tests/data/...` to
`tests/data/...` now that tests live at the root.
- pyproject.toml + README.md: project URLs and badges now point
at codecov/codecov-cli instead of getsentry/prevent-cli.
Verified locally: `uv sync` succeeds, the full pytest suite passes
(697 tests), `ruff check` is clean, and `make command_dump`
produces no diff against the checked-in codecovcli_commands.
❌ 1 Tests Failed:
View the full list of 1 ❄️ flaky test(s)
To view more test analytics, go to the Prevent Tests Dashboard |
calvin-codecov
approved these changes
May 19, 2026
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
Roll the codecov-cli project structure back to a single, top-level Python package. The
prevent-cli/subproject is deleted outright and everycodecov-cli/*file is moved up to the repository root.This PR is the structural counterpart to #708 (which restores the original release flow). The two PRs are independent and either order is fine; whichever lands second will need a trivial rebase to reconcile workflow/script edits.
Layout changes
prevent-cli/(sources, lock, README, command dump, all of it).git mv codecov-cli/{codecov_cli,tests,samples,pyproject.toml,uv.lock,setup.py,MANIFEST.in,ruff.toml,codecovcli_commands,README.md,LICENSE}to the repo root.README.md/LICENSEwith the codecov-cli versions (LICENSE was byte-identical to the root one, so it shows up as a pure delete).Tooling and config touchups
Makefile: dropcd codecov-clifromtest; repointcommand_dumpat the new top-levelcommand_dump.py.command_dump.py: restored at the repo root, dumps onlycodecovcli(no moresentry-prevent-cli).hooks/pre-commit: stop stagingprevent-cli/preventcli_commands..craft.yml: point atcodecov/codecov-cli, drop thesentry_prevent_cliartifact patterns..github/workflows/broadcast_api_changes.yml: watchcodecovcli_commandsat the root..github/workflows/ci.yml: drop all prevent-cli / sentry-prevent-cli jobs andcd codecov-cli; fix the owner guard fromgetsentrytocodecovsocodecov-startupand dogfood jobs actually run..github/workflows/build.yml: build codecov-cli only, from the repo root; drop the dual-CLI matrix, the prevent-cli wheel, and the Cosign signing step (only used for sentry-prevent-cli binaries)..github/workflows/release-codecov-cli.yml: download / publish from./distinstead ofcodecov-cli/dist.scripts/build_alpine.shandscripts/build_linux.sh: rewritten to build codecov-cli only out of the repo root withuv.scripts/{bump-version.sh,pre-build.sh,uv-installer-0.7.8.sha256sum}: deleted (all prevent-cli specific).tests/helpers/test_versioning_systems.py: update the exotic-filename assertion fromcodecov-cli/tests/data/...totests/data/....pyproject.toml+README.md: project URLs and badges now point atcodecov/codecov-cliinstead ofgetsentry/prevent-cli. (CHANGELOG.mdis left alone; the historical PR links live ongetsentry/prevent-cli.)Test plan
Verified locally on this branch:
uv syncsucceeds with the flat layout.uv run pytest— 697 passed, includingtests/helpers/test_versioning_systems.pyafter the path fix.uv run ruff check --ignore F401 --exclude languages --exclude samplesis clean.uv run python command_dump.pyproduces no diff against the checked-incodecovcli_commands.Still to verify in CI / on merge:
CLI CIlint / detect-command-change / codecov-startup / build-test-upload matrix).build.ymlproduces sdist + wheel + per-OS pyinstaller binaries from the new root paths.Made with Cursor