[bug]: Blank page and endless /meta/ requests after signing in from a work item e-mail link
Los mantenedores suelen responder en 1 día
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Aptitud para principiantes
- 32/100
- Tipo de issue
- Error
- Claridad
- Bien especificado
- Estado de actividad
- Activo
- Stack tecnológico
- react, typescript
- Área
- frontend
Línea de trabajo
Start in apps/web/lib/wrappers/authentication-wrapper.tsx: router.push() runs in the render body of the NON_AUTHENTICATED branch, so each re-render restarts navigation. Follow the old work item URL's clientLoader (getIssueMetaFromURL, then the redirect to /<workspace>/browse/<KEY>-<N>/) to see why interrupted loaders keep firing /meta/. Note pull request #10290 is already open against this, so read it before starting. Done means one /meta/ request and a completed redirect.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Is there an existing issue for this?
- I have searched the existing issues
Current behavior
Signing in from a work item link of the form /<workspace>/projects/<projectId>/issues/<issueId> (the link format used in notification e-mails) leaves a blank page, and the browser sends GET /api/workspaces/<workspace>/projects/<projectId>/issues/<issueId>/meta/ over and over.
On a self-hosted instance, one browser tab sent the same /meta/ request about 35 times a second for more than half an hour. Every request opened a database connection, so the database ran out of connections and other requests began to fail. Reproduced locally with a production build of preview against a stub API: about 1,200 /meta/ requests in 9 seconds, until the browser refused new ones (net::ERR_INSUFFICIENT_RESOURCES), and the page never left /?next_path=….
Expected: one /meta/ request, then the redirect to /<workspace>/browse/<KEY>-<N>/.
Cause. AuthenticationWrapper (apps/web/lib/wrappers/authentication-wrapper.tsx) calls router.push() in its render body, for example in the NON_AUTHENTICATED branch used by the sign-in page:
if (currentUserProfile?.id && isUserOnboard) {
const currentRedirectRoute = getWorkspaceRedirectionUrl();
router.push(currentRedirectRoute);
return <></>;
}
React Router re-renders the route tree on every navigation state change, so every render starts another navigation, which interrupts the one before it. When next_path is a route whose clientLoader waits on the network, as the old work item URL does (it calls getIssueMetaFromURL and then redirects to /browse/…), no navigation ever finishes. The interrupted loaders' requests are not aborted, so each one still reaches the API.
Steps to reproduce
- Sign out (or let the session expire).
- Open a work item link in the old form, e.g. the one in a notification e-mail:
/<workspace>/projects/<projectId>/issues/<issueId>. - You land on
/?next_path=/<workspace>/projects/<projectId>/issues/<issueId>. Sign in. - The page stays blank. In the network tab,
GET …/issues/<issueId>/meta/repeats continuously.
Visiting /?next_path=/<workspace>/projects/<projectId>/issues/<issueId> while already signed in reproduces it too. It is easier to see when the API is slow (tens to hundreds of milliseconds per request), e.g. from a distant region.
Environment
Production
Browser
Mozilla Firefox (also reproduced in Chromium)
Edition
Community
Version
v1.3.1. The same code is in v1.4.3, v1.5.0-rc2 and preview.
- Lenguaje dominante
- TypeScript
- Estrellas
- 63k
- Forks
- 6.5k
- Merge medio
- 2 d 16 h
- PR fusionados (30 d)
- 70
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de makeplane/plane
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
[bug]: Comment external_id is deduplicated per project instead of per work itemPosiblemente ocupada @MishraTanishq619 la tomó hace 21 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
makeplane/plane#10195 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
Los mantenedores suelen responder en 1 día
-
Missing optional chaining on actor_details and reaction_items in apps/space reactions and votesPosiblemente ocupada @ghazy2001 la tomó hace 29 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
makeplane/plane#10111 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 85/100
makeplane/plane#10082 · 1 comentario ·
Los mantenedores suelen responder en 1 día
Todos los issues de makeplane/plane
Issues similares
-
good first issue help wanted
Dificultad 2/5 Menos de una hora Aptitud para principiantes 86/100
Intelligenza-Umana/intelligenza-umana-web#16 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
open-webui/open-webui#35184 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
danielmiessler/LifeOS#3001 ·
Los mantenedores suelen responder en 5 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día