@clerk/testing retries FAPI token refresh after Playwright page/context closure
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 3/5
- Tempo estimado
- 1-2 dias
- Facilidade para iniciantes
- 65/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Ativa
- Stack de tecnologia
- nodejs, playwright, typescript
- Domínio
- testing
Direção de pesquisa
Start by locating the @clerk/testing FAPI retry and route-handler implementation, then reproduce the case with a Playwright page or context closing during a background token refresh. Done means page/context-closure errors are not retried or warned, while genuine FAPI and network failures remain visible.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
@clerk/testing retries a Convex-template token refresh after its Playwright page/context has closed, then logs a FAPI failure between passing tests.
Observed with @clerk/testing 2.2.36, Playwright 1.63.0, Node 24.19.0, macOS arm64. A signed-in test opens a second page with browser.newPage(), signs in using clerk.signIn({ page, signInParams: { strategy: "email_code", identifier } }), performs its authenticated interaction successfully, and closes that page in finally. If a Clerk background token refresh is still routed at that point, the handler retries four times and prints:
[Clerk Testing] FAPI request failed after 4 attempts: <redacted FAPI Convex-token URL> (Error: route.fetch: Target page, context or browser has been closed)
This occurred after two passing cases in one eight-case run; the run exited 0 with all eight cases passing. It is not an observed authentication failure or a 429. The endpoint/query are redacted because they include session/token values.
Our project already has a local patch that returns early when String(error).includes("Test ended"); it does not cover this different Playwright closure error. No other route-handler changes are applied. We have not retested a newer Clerk Testing release.
Expected: do not retry or warn for a request aborted solely because its owning page/context has closed. Keep genuine FAPI/network failures visible. Current workaround: distinguish these post-close diagnostics from the test result; no assertion or authentication bypass was added.
- Linguagem predominante
- TypeScript
- Estrelas
- 1.8k
- Forks
- 477
- Merge médio
- 2d 25min
- PRs com merge (30d)
- 267
Preparar o ambiente
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de clerk/javascript
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
clerk/javascript#10026 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
@clerk/nextjs: onBeforeSetActive never settles when invalidateCacheAction rejects (e.g. after a redeploy), so setActive and signOut hang foreverTalvez já em andamento Um pull request vinculado a esta issue está aberto ou já foi mesclado. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
clerk/javascript#9987 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 50/100
clerk/javascript#9984 ·
Mantenedores costumam responder em até 1 dia
-
M2M Token only authentication in Clerk MiddlewareTalvez já em andamento @wobsoriano assumiu há 7 dias. Abertaneeds-triage
clerk/javascript#9981 · 1 responsável ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 72/100
clerk/javascript#9972 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de clerk/javascript
Issues semelhantes
-
enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 88/100
Small-tailqwq/dsh-deep-whale#187 ·
Mantenedores costumam responder em até 1 dia
-
Tela Marca manda conferir o campo "Razão social", que em Portugal se chama "Denominação social"Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 82/100
melgarafael/DeskcommCRM#2503 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 74/100
0x80/isolate-package#218 ·
-
bug via-triage
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 82/100
pingdotgg/t3code#16859 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 74/100
Mantenedores costumam responder em até 1 dia