Repository navigation
Only ask the AI to resolve actual patch conflicts - #432
Merged
Merged
Conversation
`./mach vendor --patch-mode only` applies the mozilla patches and then runs the post-patch actions, and we gave any failure of it to the AI. A failed post-patch action (e.g. libjpeg's update.py on the dev instance) isn't something the AI can fix by editing the patches. mach logs "Could not apply <patch>" only when a patch didn't apply, so only involve the AI then; anything else is reported as before.
There was a problem hiding this comment.
🟢 Approval recommended
The focused guard preserves failure reporting and has regression coverage for both routing paths, with no blocking issues identified.
No open issues 🎉
What changed in this PR
Limits AI patch resolution to failures containing mach’s “Could not apply” message, while preserving reporting for other vendoring failures.
Changes:
- Skips AI resolution for non-conflict patch-step failures.
- Adds regression coverage and updates conflict test messages.
| File | Description |
|---|---|
| tests/functionality_all_platforms.py | Verifies AI invocation for conflicts and avoidance for other failures. |
| tasktypes/vendoring.py | Adds conflict detection before invoking AI resolution. |
Review effort: Balanced
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
./mach vendor --patch-mode onlyapplies the mozilla patches and then runs the post-patch actions, and we gave any failure of it to the AI. A failed post-patch action (e.g. libjpeg's update.py on the dev instance) isn't something the AI can fix by editing the patches. mach logs "Could not apply " only when a patch didn't apply, so only involve the AI then; anything else is reported as before.