Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[UI] Handle Segment Union Types Properly #2803

Open
nicholas-codecov opened this issue Oct 31, 2024 · 2 comments
Open

[UI] Handle Segment Union Types Properly #2803

nicholas-codecov opened this issue Oct 31, 2024 · 2 comments
Assignees
Labels
bug Something isn't working Medium Medium Priority Issues (to be fixed or re-evaluated in 3 months

Comments

@nicholas-codecov
Copy link

nicholas-codecov commented Oct 31, 2024

Currently we do not handle the segment union type properly in Gazebo, we only handle the happy path. What happens instead, is that the user sees an entire error page which is not ideal.

The ideal outcome is that we update the GQL queries that call segments field and handle all of the different types, see the screenshot below.

After updating the queries we'll also need to update the zod schemas with a discriminated union type on the __typename field, similar to that of Repository.

Once those two things are done, we'll have to update the respective file diffs to display a custom error messages in these cases.

segments union type:

Image

@nicholas-codecov nicholas-codecov added the bug Something isn't working label Oct 31, 2024
@suejung-sentry
Copy link

Here's some more info on the probable cause / how to reproduce - #2811

@drazisil-codecov drazisil-codecov added the Medium Medium Priority Issues (to be fixed or re-evaluated in 3 months label Nov 7, 2024
@eliatcodecov
Copy link

Assigning to @katia-sentry such that this can be assigned along with #2811 when that is handed off to an engineer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Medium Medium Priority Issues (to be fixed or re-evaluated in 3 months
Projects
None yet
Development

No branches or pull requests

5 participants