fix(manifest): avoid KeyError when override bottle has repos absent from base #464
Reference in New Issue
Block a user
Delete Branch "fix/457-merge-bottles-git-repo-keyerror"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
merge_bottles_runtimeused.get(n, base_repos_by_name[n])which eagerly evaluates the default, crashing withKeyErrorwhen a repo name exists only in the override bottleCloses #457
Test plan
pytest tests/unit/test_manifest_bottle_merge.py— all 25 tests passpyright— 0 errorstest_git_repo_only_in_override_does_not_raisedirectly exercises the--bottle base --bottle with-repocrash path; no separate manual run neededReviewed: no actionable findings. The fix avoids eager evaluation of the missing base-repository lookup while preserving repository order and override-wins behavior. The focused 25-test unittest suite passes under Python 3.13.