-
Notifications
You must be signed in to change notification settings - Fork 24
Add validation for Mastodon handles to prevent invalid URLs #4483
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
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Fixes #3363 Previously, users could enter invalid Mastodon handles like just "username", which resulted in broken URLs like "https://undefined/@username" on the public pages. This change adds validation to enforce proper Mastodon handle formats: - username@instance.social - @username@instance.social - https://instance.social/@username The validation is applied in: - Participant profile updates (api/participants/mutations.py) - Submission forms for talks/workshops (api/submissions/mutations.py) - Grant applications (api/grants/mutations.py) Also added a test case to verify the validation works correctly. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Marco Acierno <marcoacierno@users.noreply.github.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Codecov Report
❌ Patch coverage is 50.00000% with 8 lines in your changes missing coverage. Please review.
✅ Project coverage is 94.46%. Comparing base (6686fae) to head (4b6746d).
Additional details and impacted files
@@ Coverage Diff @@ ## main #4483 +/- ## ========================================== - Coverage 94.53% 94.46% -0.08% ========================================== Files 352 352 Lines 10131 10147 +16 Branches 733 738 +5 ========================================== + Hits 9577 9585 +8 - Misses 461 466 +5 - Partials 93 96 +3
🚀 New features to boost your workflow:
- ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds validation for Mastodon handles to fix the issue where invalid handles like just "username" result in broken URLs (
https://undefined/@username).Changes
username@instance.social,@username@instance.social, orhttps://instance.social/@usernameFixes #3363
Generated with Claude Code