Skip to content

Commit

Permalink
fix: do not throw error if race condition cannot be detected due to m…
Browse files Browse the repository at this point in the history
…issing branch
  • Loading branch information
dgellow committed Aug 31, 2023
1 parent 9455e3f commit 228526c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/manifest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1254,9 +1254,11 @@ export class Manifest {
}
} catch (err: unknown) {
if (isOctokitRequestError(err) && err.status === 404) {
throw new Error(
// note: this really should trigger an alert of some sort, but that's not yet a thing
this.logger.error(
`Branch comparison between '${pr.headBranchName}' and '${branchName.changesBranch}' failed due to a missing branch. As a result branches '${pr.baseBranchName}' and '${branchName.changesBranch}' won't be re-aligned which may result in git conflicts when the next release PR is created. Note: the release branch '${pr.headBranchName}' used for the PR ${pr.number} has likely been deleted manually before the release process could run, resulting in this error.`
);
return;
}
}

Expand Down

0 comments on commit 228526c

Please sign in to comment.