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

feat(organizations): implement 'retry later' message for resend TASK-1532 #5505

Merged
merged 2 commits into from
Feb 12, 2025

Conversation

pauloamorimbr
Copy link
Contributor

@pauloamorimbr pauloamorimbr commented Feb 10, 2025

🗒️ Checklist

  1. run linter locally
  2. update all related docs (API, README, inline, etc.), if any
  3. draft PR with a title <type>(<scope>)<!>: <title> TASK-1234
  4. tag PR: at least frontend or backend unless it's global
  5. fill in the template below and delete template comments
  6. review thyself: read the diff and repro the preview as written
  7. open PR & confirm that CI passes
  8. request reviewers, if needed
  9. delete this section before merging

📣 Summary

  • Headers are now returned by API error handler FailResponse object
  • When trying to resend an organization invitation too often now the user gets a proper message

📖 Description

We're using the response status 429 and the retry-later header information to properly format an error message to the user.

👀 Preview steps

  1. ℹ️ be part of an organization
  2. be admin or owner
  3. invite a new member to the organization
  4. Try to resend the invite via invitee actions
  5. There should be a proper message if the resend is sent too soon

Copy link
Contributor

@jamesrkiger jamesrkiger left a comment

Choose a reason for hiding this comment

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

When a non-429 error comes in we end up getting two notifications:
image

@pauloamorimbr pauloamorimbr force-pushed the pamorim/task-1532-retry-later-message-for-resend branch from 4c60c12 to 8cadb62 Compare February 12, 2025 13:38
Copy link
Contributor

@jamesrkiger jamesrkiger left a comment

Choose a reason for hiding this comment

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

lgtm

@pauloamorimbr pauloamorimbr merged commit f3020b1 into main Feb 12, 2025
5 checks passed
@pauloamorimbr pauloamorimbr deleted the pamorim/task-1532-retry-later-message-for-resend branch February 12, 2025 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants