Unawaited state updates in web settings and remote-assignment tests throw after happy-dom teardown under high worker concurrency
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- react, tailwindcss, typescript
- Lĩnh vực
- testing-qa
Hướng nghiên cứu
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.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
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).
- Ngôn ngữ chính
- TypeScript
- Star
- 119
- Fork
- 19
- Merge trung bình
- 1 ngày 18 giờ
- Pull request đã merge (30 ngày)
- 61
Chuẩn bị môi trường
- Có Dockerfile hoặc tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của DouglasNeuroInformatics/OpenDataCapture
-
Area: API Bug Difficulty: Low Priority: Low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
DouglasNeuroInformatics/OpenDataCapture#1937 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Area: Infrastructure Bug Difficulty: Low Priority: Medium Security
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
DouglasNeuroInformatics/OpenDataCapture#1916 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Area: Infrastructure Chore Difficulty: Low Priority: Medium
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
DouglasNeuroInformatics/OpenDataCapture#1835 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Area: Instruments Bug Difficulty: Low Priority: Low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
DouglasNeuroInformatics/OpenDataCapture#1824 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Completing a series instrument logs a TypeError "Cannot read properties of undefined (reading 'kind')"Có thể đã có người làm @SAY-5 đã nhận 3 ngày trước. Đang mởArea: Shared Bug Difficulty: Low Priority: Low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
DouglasNeuroInformatics/OpenDataCapture#1813 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của DouglasNeuroInformatics/OpenDataCapture
Issue tương tự
-
infra needs-triage
Độ khó 2/5 Dưới một giờ Mức phù hợp với người mới 82/100
LucasSantana-Dev/Lucky#3331 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 78/100
kOaDT/oss-oopssec-store#381 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
nocobase/nocobase#11669 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
iOS: Clear Context (/clear) and model picker fallback use negative agent check instead of isClaudeĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 1 ngày
-
bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 62/100
Maintainer thường phản hồi trong vòng 1 ngày