What's Changed
- switch
pre-commit->prekby @samuelcolvin in https://github.com/pydantic/monty/pull/392 - gc: properly release references held by values in cycles by @davidhewitt in https://github.com/pydantic/monty/pull/399
- bump to Rust 1.95 by @davidhewitt in https://github.com/pydantic/monty/pull/401
- fix GC tracking for
datetime.tzinfoby @rsr5 in https://github.com/pydantic/monty/pull/397 - clean up some dict view implementations by @davidhewitt in https://github.com/pydantic/monty/pull/402
- convert
py_reprmethods to take&mut VMby @davidhewitt in https://github.com/pydantic/monty/pull/403 - make
Taskhave owning references to its coroutine / gather by @davidhewitt in https://github.com/pydantic/monty/pull/404 - fix hash equality for trivial types by @davidhewitt in https://github.com/pydantic/monty/pull/405
- further isolate unsafe code within
Heapimplementation by @davidhewitt in https://github.com/pydantic/monty/pull/406 - fix: parse errors must not leak ruff AST Debug formatting by @smigolsmigol in https://github.com/pydantic/monty/pull/390
- ci: fix lint failures from nightly clippy by @davidhewitt in https://github.com/pydantic/monty/pull/415
- Add
gc.collect()function only withtest-hooksfeature by @davidhewitt in https://github.com/pydantic/monty/pull/398 - merge lifetimes in
VMto a single lifetime by @davidhewitt in https://github.com/pydantic/monty/pull/416 - fix lifetimes from conflicting merges to
mainby @davidhewitt in https://github.com/pydantic/monty/pull/417 - fix
no active framepanic on duplicate coroutine ingatherby @rsr5 in https://github.com/pydantic/monty/pull/410 - cache the hash value of interned / static strings by @davidhewitt in https://github.com/pydantic/monty/pull/418
- fix: avoid panic when list.sort() key callback mutates the list by @SAY-5 in https://github.com/pydantic/monty/pull/413
- implement "trial deletion" GC to collect cycles by @davidhewitt in https://github.com/pydantic/monty/pull/407
- reject reusing an already-awaited external future via
gatherby @rsr5 in https://github.com/pydantic/monty/pull/420 - Add dart/flutter bindings by @runyaga in https://github.com/pydantic/monty/pull/414
- inline hash caching directly into relevant types by @davidhewitt in https://github.com/pydantic/monty/pull/422
- Fix async external function exception propagation by @vivekraghuram in https://github.com/pydantic/monty/pull/424
- note that
make install-pyis often necessary in CLAUDE.md by @davidhewitt in https://github.com/pydantic/monty/pull/426 - fix typo in CLAUDE.md by @davidhewitt in https://github.com/pydantic/monty/pull/427
- fix exception stack corruption in various
raisecases by @davidhewitt in https://github.com/pydantic/monty/pull/428 - avoid unbounded recursion in two tuple traversal cases by @davidhewitt in https://github.com/pydantic/monty/pull/429
- move all
Stringheap allocation to go throughallocate_stringhelper by @davidhewitt in https://github.com/pydantic/monty/pull/430 - Bound AST depth produced by folding flat elif and bool-op chains by @dsp-ant in https://github.com/pydantic/monty/pull/437
- Pre-check requested size in bytes(int) constructor against resource l… by @dsp-ant in https://github.com/pydantic/monty/pull/435
- Clean up compiler - no longer emit dead code, simpler exception handlers, ensure jumps hit the same depth by @davidhewitt in https://github.com/pydantic/monty/pull/432
- agents: note that certain heap operations only need
&Heapby @davidhewitt in https://github.com/pydantic/monty/pull/441 - refactor
GatherFutureto be a state machine by @davidhewitt in https://github.com/pydantic/monty/pull/433 - fix panic on duplicate parameter names by @smigolsmigol in https://github.com/pydantic/monty/pull/382
- only swallow
AttributeErroringetattrby @davidhewitt in https://github.com/pydantic/monty/pull/442 - deduplicate source lines in tracebacks by @davidhewitt in https://github.com/pydantic/monty/pull/443
- fix more panics by @davidhewitt in https://github.com/pydantic/monty/pull/372
- fix further panics in integer operations by @davidhewitt in https://github.com/pydantic/monty/pull/444
- optimize operand load on bytecode loop by @davidhewitt in https://github.com/pydantic/monty/pull/446
- simplify jump calculation by @davidhewitt in https://github.com/pydantic/monty/pull/445
- refactor futures to have state machines like gather by @davidhewitt in https://github.com/pydantic/monty/pull/447
- Bound except-clause tuple matching by the recursion-depth limit by @dsp-ant in https://github.com/pydantic/monty/pull/439
- Bound container pre-allocation driven by iterator size hints by @dsp-ant in https://github.com/pydantic/monty/pull/434
- optimize cycle collector to have per-node work stack, not per-edge by @davidhewitt in https://github.com/pydantic/monty/pull/450
- move limits in the compiler to return syntax errors rather than panic by @davidhewitt in https://github.com/pydantic/monty/pull/449
- enforce JSON integers do not exceed Monty's BigInt limits by @davidhewitt in https://github.com/pydantic/monty/pull/431
- avoid unbounded recursion in
monty_to_pyby @davidhewitt in https://github.com/pydantic/monty/pull/453 - avoid UB in
Heap::dec_refby @davidhewitt in https://github.com/pydantic/monty/pull/451 - Implement
openbuiltin, with limitations by @samuelcolvin in https://github.com/pydantic/monty/pull/456 - add more limitations by @samuelcolvin in https://github.com/pydantic/monty/pull/460
- clean up unsupported results in
evaluate_functionby @davidhewitt in https://github.com/pydantic/monty/pull/463 - avoid panic on string id 128..255 by @davidhewitt in https://github.com/pydantic/monty/pull/466
- collect cell vars from
for/while/ifcontrol flow expressions by @davidhewitt in https://github.com/pydantic/monty/pull/465 - Context manager support by @samuelcolvin in https://github.com/pydantic/monty/pull/462
- Implement buffered
open()methods by @samuelcolvin in https://github.com/pydantic/monty/pull/461 - move
value_to_i32by @samuelcolvin in https://github.com/pydantic/monty/pull/468 - fix(repl): Add local/global store operation in comprehension expressions by @Embers-of-the-Fire in https://github.com/pydantic/monty/pull/297
- Ruff depth limit by @samuelcolvin in https://github.com/pydantic/monty/pull/391
- fix: name-based identity and equality for external function values by @mbeschastn0v in https://github.com/pydantic/monty/pull/458
- Cap comprehension generator count to prevent compiler stack overflow by @samuelcolvin in https://github.com/pydantic/monty/pull/470
- fix overlay append quota by @samuelcolvin in https://github.com/pydantic/monty/pull/472
- Fstring precision limits by @samuelcolvin in https://github.com/pydantic/monty/pull/474
- fix(file): do not serialize OpenFile buffer_meta cache across snapshots by @samuelcolvin in https://github.com/pydantic/monty/pull/471
- proc macro for function signature parsing by @samuelcolvin in https://github.com/pydantic/monty/pull/467
- apply
INT_MAX_STR_DIGITSguard to natural JSON BigInt path by @samuelcolvin in https://github.com/pydantic/monty/pull/475 - prep v0.0.18 release by @samuelcolvin in https://github.com/pydantic/monty/pull/476
New Contributors
- @smigolsmigol made their first contribution in https://github.com/pydantic/monty/pull/390
- @SAY-5 made their first contribution in https://github.com/pydantic/monty/pull/413
- @vivekraghuram made their first contribution in https://github.com/pydantic/monty/pull/424
- @dsp-ant made their first contribution in https://github.com/pydantic/monty/pull/437
- @mbeschastn0v made their first contribution in https://github.com/pydantic/monty/pull/458
Full Changelog: https://github.com/pydantic/monty/compare/v0.0.17...v0.0.18