[go: up one dir, main page]

Branch names not returned in Jira Connect

Summary

The front-end executes the getProject GraphQL query with the limit parameter on branchNames. This limit is based on a constant value of 20:

https://gitlab.com/gitlab-org/gitlab/-/blob/831145a03638792f7dba921f99cd627a962cbf96/app/assets/javascripts/jira_connect/branches/constants.js#L3

As a result, some branches matching the search pattern are not returned in the dropdown list, which prevents them from being selected.

Steps to reproduce

  1. Create a new project
  2. Create branches dev-one through to dev-twenty, ensuring there are twenty unique branch names
  3. Create branch dev
  4. Access this link: https://gitlab.com/-/jira_connect/branches/new?issue_key=new+branch
  5. Select the project and enter dev into the search dropdown for Source branch

Example Project

https://gitlab.com/gitlab-gold/tmike/zd422715/zd422715

What is the current bug behavior?

dev branch does not appear in the dropdown list

What is the expected correct behavior?

Allow for limiting of returned branches, but allow for more fine-grained searching

Relevant logs and/or screenshots

Output of checks

Results of GitLab environment info

Expand for output related to GitLab environment info

(For installations with omnibus-gitlab package run and paste the output of:
`sudo gitlab-rake gitlab:env:info`)

(For installations from source run and paste the output of:
`sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production`)

Results of GitLab application Check

Expand for output related to the GitLab application check

(For installations with omnibus-gitlab package run and paste the output of: sudo gitlab-rake gitlab:check SANITIZE=true)

(For installations from source run and paste the output of: sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production SANITIZE=true)

(we will only investigate if the tests are passing)

Possible fixes

Edited by Michael Trainor