Skip to content

"For current branch" sidebar section shows items for a wrong project in multi-root workspace

Summary

The "For current branch" section of the sidebar returns items (pipeline, MR and closing issue) for a wrong project.

Steps to reproduce

For reproducing this issue, you must have two workspaces:

  • Multi-root workspace
    • I have this (gitlab-vscode-extension) and one more project in this multi-root workspace
  • normal workspace with GitLab project (I used gitlab-org/gitlab project)
  1. Quit the VS Code
  2. Open VS Code with the normal workspace (e.g. gitlab-org/gitlab)
  3. Switch to master branch in the gitlab-org/gitlab project
  4. Additionally, open the multi-root workspace
  5. make sure that in the multi-root workspace there are no open files
  6. open the GitLab Workflow sidebar

What is the current bug behavior?

The "For current branch" section of the sidebar returns items from gitlab-org/gitlab project (Different workspace!)

What is the expected correct behavior?

No items should be shown (because we are picking which project is active based on an open file, if none is open, we can't decide which project from the multi-root workspace is active)

Relevant logs and/or screenshots

Welcome___mixed-github-gitlab__Workspace__and_actions_js___gitlab

Possible fixes

!174 (merged)