Skip to content

Conversation

@joeherm
Copy link
Collaborator

@joeherm joeherm commented Nov 11, 2025

This PR fixes MPP-4420.

How to test:

  • l10n changes have been submitted to the l10n repository, if any.
  • I've added a unit test to test for potential regressions of this bug.
  • I've added or updated relevant docs in the docs/ directory.
  • All UI revisions follow the coding standards, and use Protocol / Nebula colors where applicable (see /frontend/src/styles/colors.scss).
  • Commits in this PR are minimal and have descriptive commit messages.

Description

  • Adds a toast when we receive an error from API calls
  • Adds basic error layout for /accounts/profile and /phone

Possible blockers / follow-up tickets

  • Better design for error page
  • Don't show errors for /runtime_data endpoint. We have defaults, maybe we don't care if the user knows about that endpoint erroring
  • Don't show toast and page error at the same time

Screenshot (if applicable)

Screenshot when we get an error on a call after already loading some UI. For example, phone number suggestion:
Screenshot 2025-11-11 at 9 57 54 AM

Screenshot when we get an error for section where partial UI load isn't possible. For example, listing email addresses:
Screenshot 2025-11-11 at 10 36 11 AM

How to test

  1. Pull the repo and build the frontend
  2. Add a raise Exception("test") to RelayAddressViewSet.get_queryset
  3. Attempt to load the email page in the browser

@joeherm joeherm force-pushed the MPP-4420/frontend-error-toast branch from 68dfa1f to 2a39d6f Compare November 11, 2025 16:43
@joeherm joeherm force-pushed the MPP-4420/frontend-error-toast branch from 2a39d6f to f8132c3 Compare November 11, 2025 16:45
@joeherm joeherm marked this pull request as ready for review November 11, 2025 16:46
@@ -1,5 +1,6 @@
/// <reference types="next" />
/// <reference types="next/image-types/global" />
/// <reference path="./.next/types/routes.d.ts" />
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure why this is being added now 🤔

@joeherm joeherm changed the title feat(toast): Add toast for API error handling in the frontend feat(toast): Add toast and error page for API error handling in the frontend Nov 11, 2025
@joeherm joeherm force-pushed the MPP-4420/frontend-error-toast branch from f8132c3 to b12c86c Compare November 12, 2025 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants