Skip to content

Fix work item loading as signed out user

What does this MR do and why?

Fix work item loading as signed out user

This fixes a bug where a signed out user would see a GraphQL error message when loading a public work item. The reason is that we try to load the namespace as part of the work item query. However, Namespace is only allowed to be read when the user is a team member.

As we only require the fullPath from the namespace to perform our GraphQL query, we can also use the injected fullPath in our Vue component, instead of changing the permissions on the GraphQL API layer.

Changelog: fixed

Screenshots or screen recordings

Before After
Screenshot_2023-12-04_at_13.34.41 Screenshot_2023-12-04_at_13.34.29

How to set up and validate locally

  1. Create a work item in a public group
  2. Go to the Work Item with a signed out user (easiest to replicate with an anonymous browser window)

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports