buf_from_list of a non-list answers null in every state of EIGS_STRICT
維護者通常 1 天內回覆
還沒有人認領這個 Issue。
評估
研究方向
Start with the buf_from_list builtin implementation and the strict type guard pattern used by similar builtins; then read tools/strict_differential.sh, tests/strict_guard_release_messages.tsv, and the buf_* constructor probes. Run the strict differential checks in the default and both strict modes. Done means wrong-typed inputs raise type_mismatch under EIGS_STRICT=1 without setting a variable, preserve current behavior under EIGS_STRICT=0, and the builtin documentation describes non-list behavior.
由索引模型根據 Issue 內容生成。
描述
buf_from_list given something that is not a list answers null, in every state of EIGS_STRICT, where a wrong-typed argument of a builtin raises by default (#2439):
$ cat p.eigs
try:
x is buf_from_list of 1
print of [x, type of x]
catch e:
print of [e.kind, e.message]
try:
y is buf_from_list of "a"
print of [y, type of y]
catch e:
print of [e.kind, e.message]
$ eigenscript p.eigs # phase2-numbers at f9f3e49b; the same with EIGS_STRICT=0 and EIGS_STRICT=1
[null, "null"]
[null, "null"]
The last release (v0.48.0) answers null too, so this is not from the branch: the builtin has never had a guard, and it is not among the guard probes of tools/strict_differential.sh (no row for it in tests/strict_guard_release_messages.tsv).
It is easy to reach by accident: brackets after of are an argument list, so buf_from_list of [1] passes the number 1, not a list of one. A program that writes it gets a null buffer and fails later, somewhere else.
Found beside a reading of the documents against the runtime (#1776); not one of that reading's findings.
Done when
-
buf_from_listof a value that is not a list (a number, a string,null, a dict) raisestype_mismatchwith no variable set and underEIGS_STRICT=1, with a message that names the builtin; underEIGS_STRICT=0it keeps today's answer. - The builtin has a guard probe in
tools/strict_differential.sh, in the default mode and the two others, and its row intests/strict_guard_release_messages.tsv, or the row's absence is explained there (the release does not raise, so the release is not its oracle). - The other
buf_*constructors that take a list or a size are probed the same way once, and each that answers quietly for a wrong type is listed on this issue (fixed here or filed). -
docs/BUILTINS.md's row forbuf_from_listsays what a non-list gives.
— Claude DevBox
- 主要語言
- C
- 星號
- 3
- 分支
- 7
- 平均合併
- 3 小時 28 分鐘
- 30 天內合併 PR
- 270
環境準備
在瀏覽器裡用你自己的 GitHub 帳號啟動這個專案的開發容器。
- 提供 Dockerfile 或 Docker Compose 檔案
- 有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
InauguralSystems/EigenScript 的其他 Issue
-
area:gates kind:gate-defect
難度 2/5 1-3 小時 新手友好度 83/100
InauguralSystems/EigenScript#2476 ·
維護者通常 1 天內回覆
-
area:gates needs-triage
難度 2/5 1-3 小時 新手友好度 78/100
InauguralSystems/EigenScript#2462 · 1 則留言 ·
維護者通常 1 天內回覆
-
The hosted-RNG check refuses a clean tree that has a tracked file with a double quote in its name未關閉area:gates kind:gate-defect needs-triage
難度 2/5 1-3 小時 新手友好度 78/100
InauguralSystems/EigenScript#2461 · 1 則留言 ·
維護者通常 1 天內回覆
-
area:gates kind:gate-defect needs-triage
難度 2/5 1-3 小時 新手友好度 86/100
InauguralSystems/EigenScript#2458 · 1 則留言 ·
維護者通常 1 天內回覆
-
`http_post`: `headers` text with something after its JSON value now means no headers, without a word未關閉area:http kind:silent-wrong
難度 2/5 1-3 小時 新手友好度 72/100
InauguralSystems/EigenScript#2394 · 1 則留言 ·
維護者通常 1 天內回覆
查看 InauguralSystems/EigenScript 的全部 Issue
相似的 Issue
-
難度 1/5 1 小時以內 新手友好度 92/100
flipperdevices/flipperzero-firmware#4520 ·
維護者通常 1 天內回覆
-
area/build-framework kind/enhancement priority/low
難度 2/5 1-3 小時 新手友好度 77/100
yugabyte/yugabyte-db#38826 ·
維護者通常 1 天內回覆
-
難度 1/5 1 小時以內 新手友好度 88/100
meshcore-dev/MeshCore#3891 · 1 則留言 ·
維護者通常 1 天內回覆
-
bug grammar sev-3
難度 2/5 1-3 小時 新手友好度 76/100
-
status: needs-triage type: bug
難度 2/5 1-3 小時 新手友好度 75/100