patchrelay 0.55.0 → 0.55.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "service": "patchrelay",
3
- "version": "0.55.0",
4
- "commit": "bd44ea445936",
5
- "builtAt": "2026-05-01T12:06:57.419Z"
3
+ "version": "0.55.1",
4
+ "commit": "ec34142b31f4",
5
+ "builtAt": "2026-05-01T12:38:54.375Z"
6
6
  }
@@ -65,8 +65,9 @@ export class ReactiveRunPolicy {
65
65
  if (!issue.prNumber || issue.prState !== "open") {
66
66
  return undefined;
67
67
  }
68
- if (!run.sourceHeadSha) {
69
- return `Requested-changes run finished for PR #${issue.prNumber} without a recorded starting head SHA. PatchRelay cannot verify that a new head was published.`;
68
+ const blockingReviewHeadSha = resolveRequestedChangesBlockingHead(run, issue);
69
+ if (!blockingReviewHeadSha) {
70
+ return `Requested-changes run finished for PR #${issue.prNumber} without a recorded blocking review or starting head SHA. PatchRelay cannot verify that a new head was published.`;
70
71
  }
71
72
  try {
72
73
  const snapshot = await readReactivePrSnapshot(this.config, run.projectId, issue.prNumber);
@@ -75,8 +76,8 @@ export class ReactiveRunPolicy {
75
76
  if (!snapshot.headSha) {
76
77
  return `Requested-changes run finished for PR #${issue.prNumber} but GitHub did not report a current head SHA.`;
77
78
  }
78
- if (snapshot.headSha === run.sourceHeadSha) {
79
- return `Requested-changes run finished for PR #${issue.prNumber} without pushing a new head; PatchRelay must not hand the same SHA back to review.`;
79
+ if (snapshot.headSha === blockingReviewHeadSha) {
80
+ return `Requested-changes run finished for PR #${issue.prNumber} without pushing a new head past blocking review SHA ${blockingReviewHeadSha.slice(0, 8)}; PatchRelay must not hand the same SHA back to review.`;
80
81
  }
81
82
  return undefined;
82
83
  }
@@ -153,8 +154,9 @@ export class ReactiveRunPolicy {
153
154
  return this.db.issues.getIssue(run.projectId, run.linearIssueId) ?? issue;
154
155
  }
155
156
  const headAdvanced = Boolean(snapshot.headSha && snapshot.headSha !== issue.lastGitHubFailureHeadSha);
157
+ const blockingReviewHeadSha = resolveRequestedChangesBlockingHead(run, issue);
156
158
  const reviewFixHeadAdvanced = isRequestedChangesRunType(run.runType)
157
- && Boolean(snapshot.headSha && run.sourceHeadSha && snapshot.headSha !== run.sourceHeadSha);
159
+ && Boolean(snapshot.headSha && blockingReviewHeadSha && snapshot.headSha !== blockingReviewHeadSha);
158
160
  this.upsertIssueIfLeaseHeld(run.projectId, run.linearIssueId, {
159
161
  projectId: run.projectId,
160
162
  linearIssueId: run.linearIssueId,
@@ -311,6 +313,9 @@ function resolveReactiveBaselineHead(run, issue) {
311
313
  }
312
314
  return undefined;
313
315
  }
316
+ function resolveRequestedChangesBlockingHead(run, issue) {
317
+ return issue.lastBlockingReviewHeadSha ?? run.sourceHeadSha;
318
+ }
314
319
  function isReactiveScopeRiskPath(filePath) {
315
320
  return REACTIVE_SCOPE_RISK_EXACT_PATHS.has(filePath)
316
321
  || REACTIVE_SCOPE_RISK_PREFIXES.some((prefix) => filePath.startsWith(prefix));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "patchrelay",
3
- "version": "0.55.0",
3
+ "version": "0.55.1",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "repository": {