Goal/phb remaining#325
Merged
Merged
Conversation
…rst-only Differential conformance fixtures for the landed host-builtins (tasks 01/04/05) revealed 3 runtime bugs that passed codegen-string tests + 7-engine review + mutation + the green gate: - Math.trunc was not lowered (raw Math.trunc -> Python NameError) - .startsWith/.endsWith were not lowered (-> AttributeError) - .replace replaced ALL occurrences, not the first (JS replaces first only) Adds 19 differential Express-vs-FastAPI fixtures to scripts/conformance.mjs (now 38/38). The codegen-string tests never RAN the lowered Python; these do. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…+ 1-arg max/min) Differential fixtures revealed task 02's landed impl was half-broken despite passing gate + review + judge + mutation: - Math.pow/sqrt/hypot/random were NOT lowered (raw -> Python NameError) - Math.max(x)/Math.min(x) 1-arg emitted max(x)/min(x) -> Python TypeError (Python treats a lone arg as an iterable); JS returns the value. Lowers pow->** , sqrt/hypot->math.*, random->random.random(); 1-arg max/min returns the value. Adds 9 differential fixtures (now 47/47). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…forge target parseInt/parseFloat/(n).toFixed(d)->STRING/Number.isInteger have no Python lowering yet, so these 6 fixtures fail. They become the discriminating fitness for the agon forge: a candidate passes only when 03 lowers correctly on BOTH targets at runtime. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
…/toFixed/isInteger)
Task 03 implemented via 'agon forge' (gemini winner, codex runner-up; both passed
all 53 differential fixtures). Judge (claude) flagged a reachable f-string bug:
(n).toFixed(d) emitted f"{recv:.{d}f}" which is a SyntaxError on CPython <3.12
when recv contains a quote (e.g. data["price"]) — local py is 3.9. Hardened to
quote-safe format(recv, '.'+str(d)+'f') and added a bracket-receiver fixture.
54/54 conformance fixtures green. Closes the host-builtin surface (6/6 groups).
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Why
How
Checklist
tsc -bpassespnpm testpassespnpm test:kernpassespnpm lintpasseskern review packages/ --recursivechecked