Commit Graph
15680 Commits
Author SHA1 Message Date
Jeong, YunWon c045593e4e impl more nt (#6984)
* mpl new features

* windows encodings

* impl nt functions

* revert

* codecs

* fix codecs
2026-02-04 09:53:02 +09:00
Jeong, YunWon 9f0cd323b6 Merge pull request #6958 from youknowone/os-posix
Update os from v3.14.2 and fix nt,posix,_os
2026-02-03 23:00:25 +09:00
Jeong, YunWon 674d7dbb3a rework SchedParam 2026-02-03 22:10:31 +09:00
Jeong, YunWon c0f3a09c2b more windows impl 2026-02-03 22:10:31 +09:00
Jeong, YunWon cb2be65a8b fix timeout 2026-02-03 22:10:31 +09:00
Jeong, YunWon 9c29b0c411 Fix windows link 2026-02-03 22:10:31 +09:00
CPython Developers dd6e947122 Update os from v3.14.2 2026-02-03 22:10:31 +09:00
CPython Developers ac1dcf7d4b Update test_posix from v3.14.2 2026-02-03 22:10:31 +09:00
Jeong, YunWon f939a06aa9 fix durartion to round 2026-02-03 22:10:31 +09:00
Jeong, YunWon 8d07c45483 Populate _field_types with real type objects (#6981)
- Add FieldType enum and FIELD_TYPES static table mapping all
  AST node classes to their ASDL field types
- Resolve markers to real Python type objects (GenericAlias,
  Union, plain types) at module init in populate_field_types()
- Set class-level None defaults for optional fields
- Replace hardcoded LIST_FIELDS and class-name checks in
  slot_init with _field_types-based lookup
- Add expr_context default to Load(), fix ImportFrom.level
  default (now None instead of 0)
- Fix __class_getitem__ None check, compile() formatting
- Remove 14 @expectedFailure decorators from test_ast
2026-02-03 22:05:05 +09:00
Shahar Naveh 27d70fd58e Update test_builtin.py from 3.14.2 (#6979)
* Update `test_builtin.py` from 3.14.2

* Mark haning/segfault tests

* Patch failing tests
2026-02-03 21:55:55 +09:00
Jeong, YunWon f71fe9bf3a Add GC infrastructure: tracking bits, tp_clear (#6977)
GC bit operations (_PyObject_GC_TRACK/UNTRACK equivalent):
- Add set_gc_bit() helper for atomic GC bit manipulation
- Add set_gc_tracked() / clear_gc_tracked() methods
- Update is_gc_tracked() to use GcBits::TRACKED flag
- Call set_gc_tracked() in track_object()
- Call clear_gc_tracked() for static types (they are immortal)

tp_clear infrastructure (for breaking reference cycles):
- Add try_clear_obj() function to call payload's try_clear
- Add clear field to PyObjVTable
- Add clear() method to PyType's Traverse impl
2026-02-03 20:00:34 +09:00
Jeong, YunWonandgithub-actions[bot] 023b3b261d Add __replace__ and fix __reduce__ for structseq (#6978)
* Add __replace__ and fix __reduce__ for structseq

- Add __replace__ method to PyStructSequence trait
- Move __reduce__ from #[pymethod] to extend_pyclass with
  contains_key guard, allowing per-type overrides
- Fix repr: remove trailing comma for single-field sequences

* Auto-format: cargo fmt --all

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-02-03 19:09:47 +09:00
Jeong, YunWon 477e20a7a9 Support #[cfg] in with (#6975) 2026-02-03 18:55:59 +09:00
Jeong, YunWon d6aab01424 Improve object traversal for heap types and mro (#6976)
- Fix heap type instance traversal to include type reference
  (enables correct cycle detection for instance ↔ type references)
- Enable mro traversal in PyType (was previously disabled)
2026-02-03 17:54:11 +09:00
Jeong, YunWon 182157291a Merge pull request #6961 from youknowone/unparse
Update _ast_unparse and fix unparse, type_comments
2026-02-03 15:41:01 +09:00
github-actions[bot] 9e7faba7f3 Auto-format: cargo fmt --all 2026-02-03 05:59:58 +00:00
Jeong, YunWon 00cdb307e3 Fix AST field defaults and compile() type check
- Extract empty_arguments_object helper from expression.rs
- Fix LIST_FIELDS ambiguity: "args" and "body" have different
  ASDL types per node (e.g. Lambda.args is `arguments`, not
  `expr*`; Lambda.body is `expr`, not `stmt*`)
- Replace class name string comparison in compile() with
  fast_isinstance to accept AST subclasses
2026-02-03 14:58:43 +09:00
Jeong, YunWon ff49bfe3a7 mark ast & test_genericalias 2026-02-03 14:16:10 +09:00
CPython Developers 69c19f7cd1 Update _ast_unparse from v3.14.2 2026-02-03 14:16:10 +09:00
Jeong, YunWon 63bbb3c804 fix ast fields including type_comments 2026-02-03 14:16:10 +09:00
Jeong, YunWon 1876ac88e0 Fix compiler panics 2026-02-03 14:16:10 +09:00
Jeong, YunWon 0da5931353 fix unparse 2026-02-03 14:16:10 +09:00
Jeong, YunWon 400696c0fd --exclude rustpython-venvlauncher 2026-02-03 14:16:10 +09:00
Noa 5bf13e8642 Switch to Cell::update, slice::{split_first_chunk,split_off}, where appropriate (#6974)
* Use Cell::update, slice::{split_first_chunk,split_off}

* Use more array -> slice methods
2026-02-03 13:45:03 +09:00
Jeong, YunWon ec34befc3c Merge pull request #6949 from youknowone/faulthandler
Update faulthandler to 3.14.2
2026-02-03 13:43:25 +09:00
Jeong, YunWon cdadde55ef Update faulthandler to match CPython 3.14.2
- Rewrite faulthandler with live frame walking via
  Frame.previous AtomicPtr chain and thread-local
  CURRENT_FRAME (AtomicPtr) instead of frame snapshots
- Add signal-safe traceback dumping (dump_live_frames,
  dump_frame_from_raw) walking the Frame.previous chain
- Add safe_truncate/dump_ascii for UTF-8 safe string
  truncation in signal handlers
- Refactor write_thread_id to accept thread_id parameter
- Add SA_RESTART for user signal registration, SA_NODEFER
  only when chaining
- Save/restore errno in faulthandler_user_signal
- Add signal re-entrancy guard in trigger_signals to
  prevent recursive handler invocation
- Add thread frame tracking (push/pop/cleanup/reinit)
  with force_unlock fallback for post-fork recovery
- Remove expectedFailure markers for now-passing tests
2026-02-03 13:41:58 +09:00
CPython Developers b90530cb87 Update test_faulthandler from v3.14.2 2026-02-03 13:41:15 +09:00
dependabot[bot] 169a422ade Bump pyo3 from 0.27.2 to 0.28.0 (#6966)
* Bump pyo3 from 0.27.2 to 0.28.0

Bumps [pyo3](https://github.com/pyo3/pyo3) from 0.27.2 to 0.28.0.
- [Release notes](https://github.com/pyo3/pyo3/releases)
- [Changelog](https://github.com/PyO3/pyo3/blob/main/CHANGELOG.md)
- [Commits](https://github.com/pyo3/pyo3/compare/v0.27.2...v0.28.0)

---
updated-dependencies:
- dependency-name: pyo3
  dependency-version: 0.28.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...
2026-02-03 13:33:25 +09:00
dependabot[bot]andCopilot fda12b2fce Bump malachite-base from 0.9.0 to 0.9.1 (#6965)
* Bump malachite-base from 0.9.0 to 0.9.1

Bumps [malachite-base](https://github.com/mhogrefe/malachite) from 0.9.0 to 0.9.1.
- [Release notes](https://github.com/mhogrefe/malachite/releases)
- [Commits](https://github.com/mhogrefe/malachite/compare/v0.9.0...v0.9.1)

---
updated-dependencies:
- dependency-name: malachite-base
  dependency-version: 0.9.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Align all malachite dependencies to version 0.9.1 (#6970)

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
2026-02-03 09:42:26 +09:00
dependabot[bot] 20a58cbe3e Bump astral-sh/ruff-action from 3.5.1 to 3.6.1 (#6969)
Bumps [astral-sh/ruff-action](https://github.com/astral-sh/ruff-action) from 3.5.1 to 3.6.1.
- [Release notes](https://github.com/astral-sh/ruff-action/releases)
- [Commits](https://github.com/astral-sh/ruff-action/compare/57714a7c8a2e59f32539362ba31877a1957dded1...4919ec5cf1f49eff0871dbcea0da843445b837e6)

---
updated-dependencies:
- dependency-name: astral-sh/ruff-action
  dependency-version: 3.6.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2026-02-03 08:17:01 +09:00
Jeong, YunWon 0a39c66817 skip fork test (#6964) 2026-02-02 17:26:31 +09:00
Jeong, YunWon 2f034130b7 [update_lib] auto-mark original contents recovery (#6960) 2026-02-02 16:03:26 +09:00
Jeong, YunWon f7b2660882 Fix test_asyncio for windows (#6959) 2026-02-02 15:58:16 +09:00
Jeong, YunWon c6499797ea AGENTS.md 2026-02-02 15:57:36 +09:00
CPython Developers 15efc4a808 Update uuid from v3.14.2-288-g06f9c8ca1c 2026-02-02 14:01:59 +09:00
Jeong, YunWonandgithub-actions[bot] babc3c634f Make auto-mark output deterministic and fix blank line leak (#6957)
* Make auto-mark output deterministic and fix blank line leak

Sort set iteration in build_patches and dict iteration in
_iter_patch_lines Phase 2 so expectedFailure markers are
always added in alphabetical order.

Include preceding blank line in _method_removal_range so
removing a super-call override doesn't leave behind the
blank line that was added with the method.

* deps code

* auto-mark handles crash better

* Auto-format: ruff format

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-02-02 13:53:01 +09:00
Jeong, YunWon 100b870175 Implement UTF-32 encode/decode and fix UTF-16 empty encode
- Add UTF-32, UTF-32-LE, UTF-32-BE encode/decode in _pycodecs.py
- Register utf_32 codec functions in codecs.rs via delegate_pycodecs
- Fix PyUnicode_EncodeUTF16 returning "" instead of [] for empty input
- Remove resolved expectedFailure decorators in test_codecs.py
- Add failure reasons to remaining expectedFailure comments
2026-02-02 12:50:34 +09:00
CPython Developers db347b344d Update tabnanny from v3.14.2-288-g06f9c8ca1c 2026-02-02 11:51:53 +09:00
Jeong, YunWon 95624ce818 Merge pull request #6956 from fanninpm/3.14-socket
Update `socket` from v3.14.2
2026-02-02 11:32:39 +09:00
Jeong, YunWon 4541cbab72 Merge pull request #6954 from fanninpm/3.14-imaplib 2026-02-02 11:31:03 +09:00
CPython Developers 453ff6dc98 Update test_runpy from v3.14.2-288-g06f9c8ca1c 2026-02-02 10:45:01 +09:00
Padraic Fanning 92a5cf0ac8 Mark erroring tests 2026-02-01 20:27:22 -05:00
CPython Developers 02537b56fd Update socket from v3.14.2-288-g06f9c8ca1c 2026-02-01 20:23:50 -05:00
Jeong, YunWonandClaude Sonnet 4.5 7004502951 dealloc and finalize_modules (#6934)
* rewrite finalize_modules with phased algorithm

Replace the absence of module finalization during interpreter shutdown
with a 5-phase algorithm matching pylifecycle.c finalize_modules():

1. Set special sys attributes to None, restore stdio
2. Set all sys.modules values to None, collect module dicts
3. Clear sys.modules dict
4. Clear module dicts in reverse import order (2-pass _PyModule_ClearDict)
5. Clear sys and builtins dicts last

This ensures __del__ methods are called during shutdown and modules are
cleaned up in reverse import order without hardcoded module names.

* dealloc the rigth way

* fix finalize_modules: only clear __main__ dict, mark daemon thread tests as expected failure

Without GC, clearing all module dicts during finalization causes __del__
handlers to fail (globals are None). Restrict Phase 4 to only clear
__main__ dict — other modules' globals stay intact for their __del__
handlers.

Mark test_daemon_threads_shutdown_{stdout,stderr}_deadlock as expected
failures — without GC+GIL, finalize_modules clears __main__ globals
while daemon threads are still running.

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-02-02 10:10:58 +09:00
CPython Developers 52d23158ed Update test_asyncgen from v3.14.2 2026-02-02 10:03:42 +09:00
Jeong, YunWon 7f46112984 Merge pull request #6951 from fanninpm/3.14-code
Update `code` from v3.14.2
2026-02-02 09:58:38 +09:00
Padraic Fanning 359920f749 Mark erroring test(s) 2026-02-01 19:45:06 -05:00
CPython Developers a8e93bd8b1 Update imaplib from v3.14.2-288-g06f9c8ca1c 2026-02-01 19:40:43 -05:00
CPython Developers 1079161270 Update test_signal from v3.14.2-288-g06f9c8ca1c 2026-02-02 09:09:35 +09:00