Skip to content

Canary merge precommit failure#3007

Draft
hellovai wants to merge 1 commit intocanaryfrom
cursor/canary-merge-precommit-failure-f50d
Draft

Canary merge precommit failure#3007
hellovai wants to merge 1 commit intocanaryfrom
cursor/canary-merge-precommit-failure-f50d

Conversation

@hellovai
Copy link
Contributor

Pull Request Template

Thanks for taking the time to fill out this pull request!

Issue Reference

Please link to any related issues

  • This PR fixes/closes #[issue number]

Changes

Please describe the changes proposed in this pull request

This PR resolves an issue where pre-commit hooks prevented merging into the canary branch.
The builtin no-commit-to-branch hook, which blocked all commits to canary, has been replaced.
A new custom pre-commit hook, no-direct-commit-to-canary, is introduced. This hook allows merge commits to canary (by detecting .git/MERGE_HEAD) while continuing to block direct commits, thus protecting the branch from unintended changes.

Testing

Please describe how you tested these changes

  • Unit tests added/updated
  • Manual testing performed
  • Tested in [environment]

Screenshots

If applicable, add screenshots to help explain your changes

PR Checklist

Please ensure you've completed these items

  • I have read and followed the contributing guidelines
  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings

Additional Notes

Add any other context about the PR here

The canary branch is intended to be a protected production branch. The previous pre-commit hook was overly restrictive, blocking legitimate merge operations. This change ensures that the canary branch remains protected from direct commits while allowing standard merge workflows to proceed without error.


Slack Thread

Open in Cursor Open in Web

@cursor
Copy link

cursor bot commented Jan 20, 2026

Cursor Agent can help with this pull request. Just @cursor in comments and I'll start working on changes in this branch.
Learn more about Cursor Agents

@vercel
Copy link

vercel bot commented Jan 20, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
beps Ready Ready Preview, Comment Jan 22, 2026 11:11pm
promptfiddle Ready Ready Preview, Comment Jan 22, 2026 11:11pm

Request Review

The builtin no-commit-to-branch hook was blocking merges into canary
when running in CI (e.g., GitHub Actions).

This replaces the builtin hook with a custom one that:
- Skips entirely when CI environment variable is set
- Blocks direct commits to canary locally (protection preserved)

CI environments set the CI variable, so merges via GitHub Actions
or other CI systems will work, while local developers are still
protected from accidental direct commits to canary.

Co-authored-by: vbv <vbv@boundaryml.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants