Repository navigation
feat(python-cli-parity): compare pull request scans with base scans - #1766
Conversation
PR SummaryLow Risk Overview Fails closed when the checkout has no commit SHA or when no scan exists for that hash, with messages that tell users to scan the base commit first. Unit tests cover exact-match selection, missing SHA, and missing scan cases. Reviewed by Cursor Bugbot for commit 78a47bb. Configure here. |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using high effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Comment @cursor review or bugbot run to trigger another review on this PR
Reviewed by Cursor Bugbot for commit 78a47bb. Configure here.
78a47bb to
dd297c3
Compare
dd297c3 to
e448ee6
Compare
e448ee6 to
b4ef271
Compare
b4ef271 to
188401c
Compare
188401c to
288c05c
Compare
966dbba to
fd769f4
Compare
8dfdee2 to
0a38ea8
Compare
06c8d05 to
67c11c7
Compare
67c11c7 to
6db7906
Compare
2d52a82 to
f0cccb6
Compare
f0cccb6 to
a132a3b
Compare
Allow the Windows Python shim test more time.
a132a3b to
083aa37
Compare

Python CLI behavior
The Python CLI already compares a pull request scan with a selected baseline. It accepts a base scan ID or commit SHA; for a SHA, it prefers an exact scan and can fall back to the nearest scanned first-parent ancestor with a warning. Without an override, it uses a matching repository head scan when available. Python baseline selection
What this adds to Socket CLI
This PR adds automatic baseline comparison to Socket CLI's
socket ci. For a pull request, it uses CI's base SHA to find the scan for the repository and target branch, then compares that scan with the PR scan through the diff-scan API. A blocking finding in a new or changed package fails the check.Socket CLI requires an exact baseline match. If CI omits the base SHA or the base commit has no scan, the command reports what's missing and stops rather than comparing against an unrelated scan. The lookup uses the PR context from #1772. The Socket API token needs
full-scans:list,diff-scans:create, anddiff-scans:list.Slides