ci status should cover also newly created pipeline
<!--- Please read this! Before opening a new issue, make sure to search for keywords in the issues filtered by the "bug" label: - https://gitlab.com/gitlab-org/cli/-/issues/?label_name%5B%5D=type%3A%3Abug and verify the issue you're about to submit isn't a duplicate. ---> ### Checklist <!-- Please test the latest versions, that will remove the possibility that you see a bug that is fixed in a newer version. --> - [x] I'm using the latest version of the extension (Run `glab --version`) - Extension version: v1.57.0 - [x] Operating system and version: MacOS 15.4.1 - [x] Gitlab.com or self-managed instance? both - [x] GitLab version (if self-managed) 17.11 (Use the `version` endpoint, like this: gitlab.my-company.com/api/v4/version) - [x] I have performed `glab auth status` to check for authentication issues - [x] Run the command in debug mode (like `DEBUG=true glab mr list`) and attach any useful output ### Summary <!-- Summarize the bug encountered concisely --> ### Environment <!-- on POSIX system (Linux, MacOS), run bash -c 'printf -- "- OS: %s\n- SHELL: %s\n- TERM: %s\n- GLAB: %s" "$(uname -srm)" "$SHELL" "$TERM" "$(glab --version)"' and replace the following section with the result. If you use non-POSIX system, fill in the section manually: - OS: Darwin 24.4.0 arm64 - SHELL: /bin/zsh - TERM: xterm-256color - GLAB: v1.57.0 --> - OS: Darwin 24.4.0 arm64 - SHELL: /bin/zsh - TERM: xterm-256color - GLAB: v1.57.0 <!-- Please include any other information that you believe might be relevant in debugging. For example, you may include a shell framework like oh-my-zsh or other customizations like editing the prompt (PS1, PS2, and others). --> ### Steps to reproduce <!-- How one can reproduce the issue - this is very important --> Simply run: ```sh glab ci status --live ``` ### What is the current _bug_ behavior? If we monitor current pipeline everything works fine, however when we create a new pipeline and status will be returned as "created" or "cancelled" due to rebasing, ``glab ci status`` will exit with success. ### What is the expected _correct_ behavior? If new pipeline will be created and/or previous pipeline will be cancelled, glab should always try to fetch latest pipeline status. ### Relevant logs and/or screenshots <!--- Paste the activity log from your command line --> ### Possible fixes [status.go](https://gitlab.com/gitlab-org/cli/-/blob/main/commands/ci/status/status.go?ref_type=heads#L138) Modify conditions to: ```go if (runningPipeline.Status == "pending" || runningPipeline.Status == "running" || runningPipeline.Status == "created" || runningPipeline.Status == "cancelled") && live { ``` Caution: above should be tested if it will not cause infinite loop
issue