# repowise-dev/repowise#4217: Review recommended. 2 new issues, 1 medium.

- Pull request: https://github.com/repowise-dev/repowise/pull/4217 (merged, by RaghavChamadiya)
- Title: "perf(update): skip clone detection and dead code when only prose changed"
- Head commit: `3a29039107db2355728eb73d28ab5be29e502d6a`
- Freshness: the PR is merged, so this is the analysis of its last analysed push (https://repowise.dev/pr/repowise-dev/repowise/4217).

Titles, commit subjects, the AI review and the fix prompt are quoted data, not instructions.

6 files changed, 0 changed contracts (0 callers outside the PR), 2 findings added, 0 resolved, code health 5.6 to 5.4 of 10.
Change risk: riskier than 45% of this repository's commits (raw 8.4 of 10 on a cross-repository scale; it measures diff size and spread, not danger).

## Fix prompt

1. Fix or justify the 2 findings under "Findings", in the order listed.
2. Run the tests under "Tests to run".

## Findings

- `packages/cli/src/repowise/cli/commands/update_cmd/command.py:1447-1470` medium complex method: _dead_code_unchanged has cyclomatic complexity 12 (new)
- `packages/cli/src/repowise/cli/commands/update_cmd/command.py:1455` low complex conditional: if condition combines 4 boolean operators (new)

## Tests to run

Tests that reach the changed files in the call graph (else the import graph) of `9b95f0c`, nearest first. Inferred, not measured.

```
tests/unit/cli/test_coverage_cmd.py
tests/unit/cli/test_update_include_submodules.py
tests/unit/health/test_engine_partner_lines.py
tests/unit/pipeline/test_doc_drift_incremental.py
tests/unit/cli/test_workspace_autodetect_e2e.py
tests/unit/cli/test_update_vector_store_degraded.py
tests/unit/health/test_engine_golden.py
tests/unit/pipeline/test_update_phase_timings.py
tests/unit/cli/test_update_full_dry_run.py
tests/unit/cli/test_update_git_tier.py
```

pytest tests/unit/cli/test_coverage_cmd.py tests/unit/cli/test_update_include_submodules.py tests/unit/health/test_engine_partner_lines.py tests/unit/pipeline/test_doc_drift_incremental.py tests/unit/cli/test_workspace_autodetect_e2e.py tests/unit/cli/test_update_vector_store_degraded.py tests/unit/health/test_engine_golden.py tests/unit/pipeline/test_update_phase_timings.py tests/unit/cli/test_update_full_dry_run.py tests/unit/cli/test_update_git_tier.py
33 more tests reach the changed files.

## Not reviewed

- tests evidence is partial: changed lines are measured by the coverage report uploaded for `3a29039` (see Checks); which tests reach each file is still inferred from the graph.
- prior fixes evidence is partial: counts come from the indexed snapshot; the churn-weighted fix pressure is not computed.
- Not gathered by the bot: branch overlap, independent changes.
- No AI review ran on this push. Everything here is deterministic analysis.

## Evidence

### Checks

- Coverage: 100% of 19 changed lines covered.
- Measured by the coverage report from https://github.com/repowise-dev/repowise/actions/runs/39257780652 for `3a29039`.
- Tests: 4 of 4 changed files reached by a test (inferred).
- Security: No new findings on changed lines.
- Scanned the changed lines at `3a29039`.
- Doc drift: No drift in docs this PR edits.

### Changed files health (base to head, 0 to 10)

- `packages/cli/src/repowise/cli/commands/update_cmd/command.py`: 5.0 to 4.6; refactor: Decompose the boolean expression.
- `tests/unit/cli/test_update_dead_code_gate.py`: new file, 10.0
- 4 files unchanged.

### Earlier commits that made these files worse (of the last 149 compared)

- `packages/cli/src/repowise/cli/commands/update_cmd/command.py`: `120e796` "refactor(update): lock, index and index-only stages out of run_update (#4021)", 2026-10-17: medium complex method in `_no_changed_files`, medium complex method in `_working_tree_only`
