Repository navigation
Show and tell: A Codex-built check for numeric-looking IDs in a live case catalog #65056
xiaoyaohou19910610-bit
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
On 精选副业, a Chinese-language side-project case catalog, each public case URL carries an opaque decimal ID. It looks like a number but no calculation uses it. I used Codex to put together and run a read-only check against the live sitemap: can case IDs still be used to build the same URLs after a JavaScript JSON round trip?
I parsed the XML, extracted the digit strings from
/cases/scys-<id>/, and compared each withString(Number(id)). In the December 2, 2026 Beijing-time snapshot, 475 of 633 distinct case ID strings failed that comparison on Node 24.15.0. The sample below is from one real public case URL. That URL returned HTTP 200 and identified itself as canonical. The two shorter values used for the collision test are synthetic. The live sitemap IDs did not collide with each other in this sample.The part I would keep in a Codex task or review checklist: the ID's data type is part of the interface. Compare exact string values at the input and output boundaries, and test distinct IDs as well as a single round trip. If JSON already carries the ID as a bare number, converting it to a string after default parsing cannot restore the original digits. The decimal string is the value to preserve. The check did not modify the site or imply that it currently has a routing bug.
中文:在「精选副业」的公开站点地图里,633 个不同案例 ID 中,475 个经过 JavaScript 的
Number再转字符串会变样。这里附了一个真实 URL 的往返对照,以及一组造出来的碰撞用例。让 Codex 改采集、去重或路由时,可把「ID 始终按字符串保留,往返后逐字相同」列入验收条件。All reactions