Unawaited state updates in web settings and remote-assignment tests throw after happy-dom teardown under high worker concurrency
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 35/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- react, tailwindcss, typescript
- Área
- testing-qa
Línea de trabajo
Start with the two test files named in the issue: apps/web/src/routes/_app/admin/tests/settings.test.tsx (the autosave onSuccess timer and the unmount effect around settings.tsx:161-166) and apps/web/src/routes/_app/session/tests/remote-assignment.test.tsx at the two redirect-URL tests near lines 238 and 250. Reproduce by running the apps/web unit tests under high worker concurrency. Done means the timer is cleared on unmount or the tests wait for the post-submit state to settle, with no uncaught window errors across repeated runs.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Under high Vitest worker concurrency (reproduced on a 32-core Linux host where pnpm test:coverage spawns 31 workers), two apps/web unit test files intermittently fail the run with an uncaught ReferenceError: window is not defined inside React (resolveUpdatePriority in react-dom-client.development.js:944:7) when a state update fires after happy-dom has torn down window:
apps/web/src/routes/_app/admin/settings.tsx:92(apps/web/src/routes/_app/admin/__tests__/settings.test.tsx):autosave'sonSuccesscallback schedulessavedTimerRef.current = setTimeout(() => setSaveState('idle'), 2000), and the unmountuseEffectat lines 161–166 clearsdurationDebounceRef.currentwithout clearingsavedTimerRef.current. Under worker contention, worker teardown can cross the 2s mark and runsetSaveState('idle')afterwindowis gone.apps/web/src/routes/_app/session/__tests__/remote-assignment.test.tsx:238,250: both redirect-URL tests callsubmitForm()and return as soon asawait waitFor(() => expect(mocks.mutateAsync).toHaveBeenCalled())passes, beforeonSubmitand@douglasneuroinformatics/libui'sFormhandleSubmit(Form.js:87:13) finish their post-submitsetStatemicrotasks (comparecreateAssignmentat line 124, which waits for the renderedAssignment Link).
- Lenguaje dominante
- TypeScript
- Estrellas
- 119
- Forks
- 19
- Merge medio
- 1 d 18 h
- PR fusionados (30 d)
- 61
Preparar el entorno
- Incluye un Dockerfile o un archivo de Docker Compose
- Sin 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 DouglasNeuroInformatics/OpenDataCapture
-
Area: API Bug Difficulty: Low Priority: Low
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
DouglasNeuroInformatics/OpenDataCapture#1937 ·
Los mantenedores suelen responder en 1 día
-
Area: Infrastructure Bug Difficulty: Low Priority: Medium Security
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
DouglasNeuroInformatics/OpenDataCapture#1916 ·
Los mantenedores suelen responder en 1 día
-
Area: Infrastructure Chore Difficulty: Low Priority: Medium
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
DouglasNeuroInformatics/OpenDataCapture#1835 ·
Los mantenedores suelen responder en 1 día
-
Area: Instruments Bug Difficulty: Low Priority: Low
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
DouglasNeuroInformatics/OpenDataCapture#1824 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Completing a series instrument logs a TypeError "Cannot read properties of undefined (reading 'kind')"Posiblemente ocupada @SAY-5 la tomó hace 3 días. AbiertoArea: Shared Bug Difficulty: Low Priority: Low
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
DouglasNeuroInformatics/OpenDataCapture#1813 · 1 comentario ·
Los mantenedores suelen responder en 1 día
Todos los issues de DouglasNeuroInformatics/OpenDataCapture
Issues similares
-
infra needs-triage
Dificultad 2/5 Menos de una hora Aptitud para principiantes 82/100
LucasSantana-Dev/Lucky#3331 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
kOaDT/oss-oopssec-store#381 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
nocobase/nocobase#11669 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
iOS: Clear Context (/clear) and model picker fallback use negative agent check instead of isClaudeAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
Los mantenedores suelen responder en 1 día