59 Commits

Author SHA1 Message Date
Jeong, YunWon
2d676e7f4d A few windows fix (#7458)
* Disallow instantiation of sys.getwindowsversion type

Add slot_new to PyWindowsVersion that raises TypeError,
matching sys.flags behavior.

* Remove incorrect WSAHOS errno constant

WSAHOS was hardcoded as an alias for WSAHOST_NOT_FOUND, but
CPython guards it with #ifdef WSAHOS which doesn't exist in
modern Windows SDK headers.

* Fix mmap resize to raise OSError instead of SystemError

* Fix CreateProcess with empty environment on Windows

Empty env dict produced a single null terminator, but
CreateProcessW requires a double null for a valid empty
environment block.

* Revert mmap resize error to SystemError and fix errno.rs formatting

mmap resize raises SystemError (not OSError) when mremap is unavailable,
matching CPython behavior. test_mmap catches SystemError to skip unsupported
resize operations.

* Fix named mmap resize to raise OSError and unmark test_sleep expectedFailure

Named mmap resize on Windows should raise OSError (not SystemError).
Remove expectedFailure mark from TimeEINTRTest.test_sleep as it now passes.

* Use expectedFailureIf for TimeEINTRTest.test_sleep on Linux

test_sleep passes on macOS but fails on Linux due to timing.

* Remove expectedFailure for TimeEINTRTest.test_sleep

test_sleep now passes on all platforms.
2026-03-21 22:49:09 +09:00
Shahar Naveh
4092346f95 Update subprocess.py to 3.14.3 (#7244) 2026-02-28 10:36:09 +09:00
Jeong, YunWon
6950baf687 more algorithm-independent GC infra (#7194)
* mark poluting tests

* GC-infra independent to EBR

* trashcan

* add overflow guard to inc(), #[must_use] on dec()/safe_inc(), trashcan debug_assert, weakref generic re-check
2026-02-22 21:31:42 +09:00
CPython Developers
79c428e465 Update subprocess from v3.14.2 2026-02-04 11:16:15 +09:00
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
cb2be65a8b fix timeout 2026-02-03 22:10:31 +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
Jeong, YunWon
7258a4ae92 generator is borrowed 2026-02-02 00:43:07 +09:00
Jeong, YunWon
9a9426ee73 mark test failures 2026-02-02 00:43:07 +09:00
Jeong, YunWon
714d1ce58b gc module internal structure and API (#6910)
* gc module internal structure and API

Add gc_state module with GcState, GcGeneration, GcDebugFlags, GcStats.
Replace gc module stubs with working API backed by gc_state.
Add gc_callbacks and gc_garbage to Context.
Add is_gc_tracked, gc_finalized, gc_get_referents to PyObject.
Collection is stubbed (returns 0) — actual algorithm to follow.

* fix dict/weakref/generators

* unmark test_asyncio

* apply review
2026-02-01 08:51:39 +09:00
Terry Tianlin Luan
ec564ac190 Updated tempfile libraries + associated tests - V3.13.11 (#6632)
* Updated subprocess library test

* Updated tempfile library + test

* Skipped the test_cleanup_with_symlink_modes test
2026-01-04 21:15:42 +09:00
Jeong, YunWon
489289f54a Fix subprocess and Update subprocess from Python 3.13.11 (#6583)
* fix test_subprocess

* fix posixsubprocess

* fix io warning

* Update subprocess from Python 3.13.11

* fix

* Auto-format: cargo fmt --all

* fix macos

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2025-12-30 12:28:47 +09:00
Jeong, YunWon
3600b6652d update _pyio, test_fileio from 3.13.11 and impl more io features (#6560)
* Update _pyio, test_fileio from 3.13.11

* impl more io

* unmark sucessful tests

* fix windows fileio
2025-12-28 18:06:47 +09:00
Jeong, YunWon
4f0b940b16 impl preexec_fn (#6479) 2025-12-24 17:02:21 +09:00
ShaharNaveh
f3916950bf Skip flakey test 2025-12-16 21:35:55 +01:00
Jeong, YunWon
30dd5bedc6 use posix error messages under 127 (#6420)
* use posix error messages under 127

* use posix error message for unix

* unmark successful tests
2025-12-13 09:24:17 +09:00
Jeong, YunWon
b9fa405fd4 Fix test_subprocess 2025-12-12 20:26:47 +09:00
Jeong, YunWon
04d55fa5c6 Faulthandler (#6400) 2025-12-12 00:08:55 +09:00
Jeong, YunWon
26b3445d14 windows pipe/getppid (#6378)
* pipe/pid

* libc first
2025-12-09 23:49:32 +09:00
Jeong, YunWon
cab41c807b windows codecs (#6337)
* mbcs_codec

* oem codec
2025-12-08 01:51:51 +09:00
Jeong, YunWon
f4b8b019ca winapi suppliment (#6338)
* winapi.ExitProcess

* Fix winapi Handle

* msvcrt.GetErrorMode

* windows stats

* unmark tests
2025-12-08 01:35:31 +09:00
Noa
7d05f881c4 Have rustpython_literal::escape support wtf8 2025-03-28 11:26:29 +09:00
Noa
0a07cd931f Fix more surrogate crashes 2025-03-26 23:12:21 -05:00
Noa
fbd0c7a99e Implement IncrementalNewlineDecoder in rust 2024-11-14 23:06:53 -06:00
Noa
7933edad43 Add missing functionality to posixsubprocess 2024-09-21 22:40:15 -05:00
Jeong YunWon
75a985e63e mark failng tests 2024-05-01 15:59:23 +09:00
CPython Developers
5714558785 Update subprocess from CPython 3.12.3 2024-05-01 04:23:14 +09:00
Jeong, YunWon
49cfcd817d remove some skipIf and enable shutil CI for windows (#5235)
* mark failing shtuil tests in windows

* unsetenv raise more informed error

* Remove a few skipIf for windows
2024-04-20 03:00:27 +09:00
Jeong, YunWon
6c4ee951e0 fix windows OSError 2024-04-18 10:23:12 +09:00
DimitrisJim
283a8046aa Mark failing tests. 2023-05-19 22:38:38 +03:00
DimitrisJim
7366a41b1c Update subprocess from CPython 3.11 2023-05-19 19:54:59 +03:00
Jeong YunWon
367a948ff0 Adapt unittest.expectedFailureIf 2023-03-02 04:41:15 +09:00
dvermd
a18bad2ca3 Fill OSError attributes 2022-10-04 13:34:09 +02:00
Moreal
6d017420c5 Unmark resolved tests 2022-08-13 08:39:58 +09:00
Sion Kang
bb52ed774e Feat: grp module (#3967) 2022-08-04 15:44:40 +09:00
Jeong Yunwon
7fdbf53822 update subprocess for windows 2022-07-25 07:11:18 +09:00
Jeong YunWon
e33a6a68ac Fix _posixsubprocess for updated subprocess 2022-07-25 04:10:59 +09:00
CPython developers
51b998d663 update subprocess from CPyhton 3.10.5 2022-07-25 04:10:59 +09:00
Dean Li
29c953d9a6 test: update test.support and test_io to 3.10
Initially this is only meant to be a small update for `test_io.py`.
But it turns out that `test.support` need a lot of cleanup especially
for `test.support.warnings_helper`.
2022-04-18 22:50:55 +08:00
Jeong Yunwon
b48cb1f50c hide test_subprocess.test_invalid_cmd 2022-04-18 21:38:32 +09:00
Dean Li
6f98288e84 test: use import_helper 2021-11-29 21:03:02 +08:00
Dean Li
5ee4fb899b test: use os_helper 2021-11-28 20:51:32 +08:00
Jeong YunWon
913b78ca44 Revert "Merge pull request #3433 from deantvv/test-update"
This reverts commit 9fa5c5ac66, reversing
changes made to e7fa32c687.
2021-11-17 17:06:51 +09:00
Dean Li
49a5805d11 test: use os_helper 2021-11-13 02:18:33 +00:00
Dean Li
a59556ad25 Refactor OSError
Implement `raw_os_error_to_exc_type` to reduce duplication of errno to
exception type.
2021-10-30 17:05:54 +08:00
Padraic Fanning
be46e58320 Clean up skips in test_subprocess 2021-10-17 21:28:18 -04:00
ChJR
296f18326e Make OSError subclass instead of itself 2021-10-08 02:33:44 +09:00
Padraic Fanning
2cb17cc61d Unmark unexpected successes on Windows 2021-05-23 17:29:08 -04:00
Padraic Fanning
1a4fb31cd2 Mark erroring/failing tests on Windows 2021-05-15 19:14:08 -04:00
Padraic Fanning
daeb787528 Mark erroring test(s) on non-Windows systems 2021-05-15 19:10:51 -04:00