Skip to content

Duo settings bug fix for group/subgroups not available in 17.7

What does this MR do and why?

The purpose of this MR is to fix the bug indicated in the related issue below, where Duo settings became unavailable in SM groups/subgroups and SaaS subgroups with the introduction of the new Duo settings page.

Related Issues:

References

Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Self-managed

Before After Page Notes
Screenshot_2025-01-08_at_7.50.37_PM Screenshot_2025-01-09_at_8.57.53_AM General Settings Top-level Group Settings missing
Screenshot_2025-01-08_at_7.51.35_PM Screenshot_2025-01-08_at_7.34.13_PM General Settings Subgroup Settings missing
Screen Recording
Screen_Recording_2025-01-09_at_9.01.12_AM

SaaS/Gitlab.com

Before After Page Notes
Screenshot_2025-01-08_at_7.34.59_PM N/A General Settings Top-level Group No changes made, just validate banner redirects to new Duo page
Screenshot_2025-01-08_at_8.03.41_PM Screenshot_2025-01-08_at_7.34.13_PM General Settings Subgroup Banner linked to dead page, should display settings again
Screen Recording
Screen_Recording_2025-01-08_at_7.30.22_PM

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

For frontend changes:

Make sure you have Duo set up with a group as indicated here. It is also advised to have a GitLab Ultimate license for these changes as well as a connection to CustomersDot. But not sure if it is completely necessary.

Make sure you have Duo is set up for a group, as noted here.

In gitlab-development-kit

  • env.runit example
export GITLAB_SIMULATE_SAAS=1
export GITLAB_LICENSE_MODE=test
export LLM_DEBUG=1
export AI_GATEWAY_URL=http://0.0.0.0:5052
export CLOUD_CONNECTOR_SELF_SIGN_TOKENS=1
export CUSTOMER_PORTAL_URL=https://customers.staging.gitlab.com/
  • gdk.yml example to set up CDot
license:
  customer_portal_url: https://customers.staging.gitlab.com
  license_mode: test

Testing the Top-Level Group & Subgroups on General Settings Page

Group - SaaS Instance

  1. Run GITLAB_SIMULATE_SAAS=1 gdk restart in your GDK.
  2. Go to Groups > Settings > General in the left nav of the top-level group you are in.
  3. Validate the GitLab Duo features section is a banner that redirects to new Duo page.
  4. Navigate to a subgroup of the group that you are in.
  5. Go to Groups > Settings > General in the left nav of the subgroup you are in.
  6. Validate the GitLab Duo features section is configurable with no experiment settings checkbox (as indicated in SSs).

Group - SM Instance

  1. Run GITLAB_SIMULATE_SAAS=0 gdk restart in your GDK.
  2. Go to Groups > Settings > General in the left nav of the top-level group you are in.
  3. Validate the GitLab Duo features section is configurable with no experiment settings checkbox (as indicated in SSs).
  4. Navigate to a subgroup of the group that you are in.
  5. Go to Groups > Settings > General in the left nav of the subgroup you are in.
  6. Validate the GitLab Duo features section is configurable with no experiment settings checkbox (as indicated in SSs).

Tests

  1. Run npx jest ee/spec/frontend/ai/settings/components/ai_common_settings_form_spec.js
  2. Run npx jest ee/spec/frontend/ai/settings/components/ai_common_settings_spec.js
  3. Run bundle exec rspec ee/spec/helpers/ee/groups/settings_helper_spec.rb

Related to #510679 (closed)

Edited by Lindsey Shelton

Merge request reports

Loading