Existing-user invite flow shows registration form and fails with raw DB error on submit
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 57/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 静か
- 技術スタック
- typescript
調査の方向性
Start with application/backend/src/controllers/ParticipantsController.ts and the sendInvite email-sending flow; compare the existing-user path with the registration email path. Check how GET /invites/pending, POST /invites/{inviteId}/accept, and StudyInvites.tsx support existing users. Done means existing users receive a login-and-accept invitation email, while new users retain the registration link.
索引モデルが issue の本文から書いたものです。
説明
When a user who already has a CTRL account is invited to a new study, the current flow is rough:
- Not logged in, clicking the invite link opens the full registration form. Filling everything in and submitting fails with
Error Registering: emailHash already in use. That raw DB-ish message comes fromapplication/backend/src/middlewares/ErrorHandler.tsusing the Prisma unique constraint column name as-is, and shouldn't be exposed to end users. Having users fill the entire form only to fail on submit is bad UX too. - Logged in as the invited user, clicking the same invite link still shows the registration form. Would expect them to just see and accept the invite from their dashboard (that flow already exists via
GET /invites/pending+StudyInvites.tsx). - The registration form doesn't pre-fill the email from the invite. Users could type a slightly different email and only find out on submit that it doesn't match the invite.
Suggested fix
The accept-invite flow for existing users already works in the dashboard (GET /invites/pending + POST /invites/{inviteId}/accept + StudyInvites.tsx). Simplest fix would be at the email-sending step in sendInvite (application/backend/src/controllers/ParticipantsController.ts):
- If a user with the recipient's email already exists: send a "you've been invited to , please log in to accept in your dashboard" email with a login link
- If not: send the current registration email with the /register/{inviteId} link
- 主要言語
- TypeScript
- スター
- 4
- フォーク
- 0
- 平均マージ
- 14時間 50分
- マージ済み PR(30日)
- 5
環境構築
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Garvan-Data-Science-Platform/ctrl のほかの issue
-
難易度 1/5 1〜3時間 初心者へのやさしさ 82/100
-
admin-client backend bug
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
-
backend bug
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
Garvan-Data-Science-Platform/ctrl#970 · コメント 1 件 ·
-
backend bug
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
-
backend bug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
Garvan-Data-Science-Platform/ctrl の issue をすべて見る
似ている issue
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
vercel/streamdown#673 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
docs(stream-protocol): document messageMetatadata on start/finish and the message-metadata chunkオープンfactory-active task-identify-harness-labels-done task-identify-issue-type-done
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
agilepathway/label-checker#721 ·
メンテナーはふだん 1 日以内に返信
-
CLI Empathy needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
chromaui/chromatic-cli#1524 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信