[2.0 / next] A memo reading latest(a) beside b() computes a torn pass on a batched write; if that pass throws, the error sticks
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
- 1-2 ngày
- Mức phù hợp với người mới
- 48/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ệ
- javascript, typescript
- Lĩnh vực
- frontend
Hướng nghiên cứu
The reproduction is in packages/web/test/async-gen; begin by reading it and tracing how latest, createMemo, and batched writes interact in Solid’s reactive runtime. Add a regression test for the throwing memo and the torn tuple case, then verify that the memo reaches the fresh value after the batch and effects do not commit a mixed tuple. The issue does not name the runtime implementation file or an existing test command.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Found by the async app generator (packages/web/test/async-gen, branch claude/project-thread-bgafe5), minimized. There is no async anywhere in this case.
const [a, setA] = createSignal(1);
const [b, setB] = createSignal(0);
render(() => {
const m = createMemo(() => {
const v = latest(a) + b() + 1;
if (v % 4 === 3) throw new Error("m:" + v);
return v;
});
return <Errored fallback={e => `[E ${e()?.message}]`}><span title={String(m())} /></Errored>;
}, el);
flush();
setB(3); setA(2); flush();
// m computes latest(a)=2 with b()=0 → 3 → throws, and never re-runs: screen stays [E m:3]
Expected: m = 2 + 3 + 1 = 6, <span title="6">. A fresh render with a=2 and b=3 shows that.
Actual on next (1f558e50): the memo runs one pass with the new latest(a) beside the old b(). When that pass throws, the boundary keeps the error, and nothing re-runs m with b=3.
Without the throw, the torn pass still reaches effects. In a memo returning [latest(s), s()] after set(2), a render effect commits [2,1] before [2,2]. That is a torn tuple from a plain write with no transition held, which "latest tears" (#4284) doesn't seem to cover.
- Ngôn ngữ chính
- TypeScript
- Star
- 36.2k
- Fork
- 1.1k
- Merge trung bình
- 10 giờ 28 phút
- Pull request đã merge (30 ngày)
- 379
Chuẩn bị môi trường
- Không có Dockerfile hay tệp Docker Compose
- 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 solidjs/solid
-
`lazy()`: remounting an already-loaded component renders empty (or the Suspense fallback) since 1.9.14Có thể đã có người làm @itisrmk đã nhận 12 ngày trước. Đang mở1.x
Độ 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
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 51/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 45/100
solidjs/solid#4398 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Hydration runs an async memo over latest(...) of a hydrated chain with undefined and re-asksĐang mở
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 1-2 ngày Mức phù hợp với người mới 55/100
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của solidjs/solid
Issue tương tự
-
fix(worker): keep normal prepare waiting states failure-freeCó thể đã có người làm @LichKing-2234 đã nhận hôm nay. Đang mởagent:codex priority:P1
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
AgoraIO-Extensions/agent-infra#3745 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
The five-line work window can drop its oldest line: the per-line byte share ignores the JSON framingCó thể đã có người làm @Eapp1e đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 84/100
makecindy/cindy#7973 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
Độ khó 1/5 Dưới một giờ Mức phù hợp với người mới 78/100
lingdojo/kana-dojo#33337 · 1 bình luận · 5 reaction ·
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 76/100
coder/xum#7733 · 1 bình luận ·
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
code-yeongyu/senpi#4917 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày