fix(gitlab): remove deprecated --state flag from glab mr list#347
fix(gitlab): remove deprecated --state flag from glab mr list#347Shanmukhcr7 wants to merge 1 commit into
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 43522f3802
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| args = append(args, "--target-branch", base) | ||
| } | ||
| args = append(args, "--state", "opened", "--output", "json") | ||
| args = append(args, "--output", "json") |
There was a problem hiding this comment.
Update GitLab MR list test fixtures
With this invocation now omitting --state, the GitLab test command factory still only registers responses keyed with the old --state opened command (for example internal/scm/gitlab/gitlab_test.go:188 and :223). I checked GitLab's glab mr list docs: it defaults to open merge requests and lists --output, --source-branch, and --target-branch options but no --state option. Running go test ./internal/scm/gitlab now fails with unexpected command: glab mr list --source-branch ... --output json, so this change breaks the package CI until those fixtures are updated to the new CLI invocation.
Useful? React with 👍 / 👎.
43522f3 to
23be3c5
Compare
Fixes #313
Current versions of the
glabCLI have removed the--stateflag from themr listcommand, which causes the pipelineprstep to crash withUnknown flag: --state.Because
glab mr listnow defaults to only showing opened Merge Requests, we can simply drop the--state openedarguments to fix the crash.