feat(cli): create GitLab merge requests for verified patches - #814
feat(cli): create GitLab merge requests for verified patches#814kmbroai wants to merge 2 commits into
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
faizan-oai
left a comment
There was a problem hiding this comment.
Excellent! Waiting for phabricator and bit bucket support ty
mldangelo-oai
left a comment
There was a problem hiding this comment.
Non-blocking deslop follow-up: these two test reductions preserve the distinct GitLab coverage while removing duplicated setup and workflow runs.
| "patch", | ||
| "--scan", | ||
| "scan-1", | ||
| "--assess-patch-risk", |
There was a problem hiding this comment.
[P3] Keep the routing matrix focused
These nine rows test origin/environment-to-client routing, but each also runs the unrelated patch-risk assessor and checks its summary. Patch-risk publication is already covered above. Drop --assess-patch-risk and the assessor fixture here, and assert the default MR body instead.
| test.each([ | ||
| ["github", "push"], | ||
| ["github", "create"], | ||
| ["gitlab", "push"], |
There was a problem hiding this comment.
[P3] Drop the duplicate GitLab retry rows
The GitLab push/create rows exercise the same provider-neutral retry state machine already covered by GitHub. The routing matrix below verifies glab’s list/create arguments, while the missing-client row drives the GitLab list → resume → push/create → repeat path. Keep that row and delete these two duplicate failure rows.
Summary
patch --create-prcurrently invokes GitHub's CLI for every repository. It now creates a draft GitLab merge request withglabwhen the origin push URL identifies GitLab.Changes
GITLAB_HOSTsetting (including glab'sGITLAB_URIandGL_HOSTaliases).patch --resume-prrecovery. Preserve thepullRequest: { branch, url }JSON result and existing GitHub arguments.Testing
bun test --timeout 30000 tests-ts/cli-patch.test.ts --seed 12345: 42 passed, 0 failed.pnpm run typesandpnpm run formatpassed.Risk and rollout
The existing
--create-prand--resume-prsyntax and defaults are unchanged. GitLab requires an installed, authenticatedglab; self-hosted repositories also require the matching GitLab host setting when creating or resuming publication. Other hosts retain the GitHub workflow. GitLab API calls are mocked in regression tests; no live merge request was created during validation.Public disclosure review