A failed "Turn reminders back on" reloads the page with no error
I maintainer di solito rispondono entro 1 giorno
Valutazione
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Idoneità per principianti
- 25/100
- Tipo di issue
- Bug
- Chiarezza
- Specificata chiaramente
- Stato di attività
- Ferma
- Stack tecnologico
- nextjs, typescript
Direzione di ricerca
Start in src/app/s/[slug]/unsubscribe/page.tsx, where the opted-out branch of UnsubscribePage ignores the error param, then check src/app/api/public/reminder-optout/route.ts for the redirect with error=1. Open pull request #788 already targets this, so review it before starting. Done means the opted-out branch shows the existing error message when error is set, with page and route tests added and the listed pnpm checks passing.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
What happens
On the reminders page (src/app/s/[slug]/unsubscribe/page.tsx), a participant who has turned reminders off sees "Reminders are off" and a "Turn reminders back on" button. That button posts action=start to src/app/api/public/reminder-optout/route.ts.
If the request fails, the route sends the participant back to the same page with error=1. A failure is a refusal from optInToReminders, the per-IP rate limit, or any thrown error.
UnsubscribePage reads error, but only the opted-in branch shows "That didn't work — nothing has changed. Try again below." The opted-out branch only looks at done. After a failed opt-in the participant is still opted out, so the page looks exactly as it did before the click. They can't tell the click did nothing, and they keep getting no reminders.
Turning reminders off already shows the error. Only turning them back on doesn't.
Fix, in outline
- Show the same
FormErrorin the opted-out branch whenerroris set, or move it into the sharedShellso both branches have it.
Watch for
- Wording. Use the same wording as the existing message. Don't write a new one.
- Existing route test.
route.db.test.tscoverserror=1for opting out only.
Done when
- A page test: rendering the opted-out branch with
error: '1'shows the error message, and without it doesn't. - A route test: a failed
action=startfrom the confirm page redirects witherror=1. pnpm lint && pnpm typecheck && pnpm knip && pnpm testandpnpm test:dbpass.
Found by the pipeline's bugs scout in the participant's reminder opt-out path (src/app/s/[slug]/unsubscribe, src/app/api/public/reminder-optout), at 8e63fab. Checked by an independent verifier: a page render with optedOut: true and error: '1' was identical to one without the error, and route tests showed both a rate limit and a refused opt-in redirect with error=1. https://claude.ai/code/session_016YZ9SUw2vvaNxfSUsArR5B
Held back by the scout's cap. Add pipeline:ready to queue it.
- Lingua principale
- TypeScript
- Stelle
- 19
- Fork
- 4
- Merge medio
- 19h 46m
- PR unite (30g)
- 194
Preparare l'ambiente
- Include un Dockerfile o un file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di richshaw/OpenSignup
-
enhancement
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
richshaw/OpenSignup#794 ·
I maintainer di solito rispondono entro 1 giorno
-
enhancement pipeline:proposed pipeline:ux
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
richshaw/OpenSignup#654 ·
I maintainer di solito rispondono entro 1 giorno
-
Two breadcrumb pages belong to URLs that always redirect, so they never showForse già presa @richshaw l’ha presa oggi. Apertaenhancement good first issue pipeline:stuck
richshaw/OpenSignup#793 · 1 commento · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
The Build tab lets a list get a 21st item or one over 60 characters, then rolls it back with a cryptic errorForse già presa @richshaw l’ha presa 1 giorno fa. Apertabug pipeline:building pipeline:ux
richshaw/OpenSignup#784 · 1 assegnatario ·
I maintainer di solito rispondono entro 1 giorno
-
bug pipeline:proposed pipeline:ux
Difficoltà 3/5 1-2 giorni Idoneità per principianti 25/100
richshaw/OpenSignup#783 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di richshaw/OpenSignup
Issue simili
-
Report: &TV InternationalApertacheck:passed streams:remove
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 67/100
I maintainer di solito rispondono entro 1 giorno
-
bug priority-p1
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
-
beginner blocked
Difficoltà 2/5 1-3 ore Idoneità per principianti 82/100
hiero-ledger/hiero-sdk-js#4670 ·
I maintainer di solito rispondono entro 1 giorno
-
[Exploratory] Expense - 2 selected drop-down is shown twice when selecting hold from more option.ApertaMonthly Not a priority
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
Expensify/App#106080 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno