You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(ci): skip the diff-based audits on branch creation instead of guessing a base
Follow-up to #7033, which merged with this thread open.
A push that creates a branch reports an all-zero `github.event.before`, and the
fallback answered that with `HEAD~1` — auditing the single tip commit while
reporting on the whole push. That is the same partial-audit-reported-as-complete
failure #7033 set out to remove, one case further along.
There is no correct base to substitute here: nothing precedes the push, and
diffing the whole history would lint every migration ever written. So the audits
now skip with a `::notice::` naming the reason. A stated skip is honest; a
partial audit wearing a green check is not.
Reachable only by deleting and recreating `main`, `staging` or `dev`, so this
fixes a gap rather than an incident.
Dropping the fallback also drops its only consumer: `fetch-depth: 2` existed to
give `HEAD~1` something to resolve to, and `before` is fetched by SHA, so the
checkout returns to the default depth. Net -9 lines against #7033.
Verified both audits still pass against a raw SHA base.
0 commit comments