Skip to content

Commit f6452bf

Browse files
committed
gc
1 parent faa173c commit f6452bf

21 files changed

Lines changed: 2371 additions & 134 deletions

File tree

‎.cspell.dict/cpython.txt‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,7 @@ uncollectable
195195
Unhandle
196196
unparse
197197
unparser
198+
untracking
198199
VARKEYWORDS
199200
varkwarg
200201
venvlauncher
@@ -209,5 +210,6 @@ webpki
209210
winconsoleio
210211
withitem
211212
withs
213+
worklist
212214
xstat
213215
XXPRIME

‎.cspell.json‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,7 @@
6666
"emscripten",
6767
"excs",
6868
"finalizer",
69+
"finalizers",
6970
"GetSet",
7071
"groupref",
7172
"internable",
@@ -122,12 +123,14 @@
122123
"tracebacks",
123124
"typealiases",
124125
"typevartuples",
126+
"uncollectable",
125127
"unhashable",
126128
"uninit",
127129
"unraisable",
128130
"unresizable",
129131
"varint",
130132
"wasi",
133+
"weaked",
131134
"zelf",
132135
// unix
133136
"posixshmem",

‎Cargo.lock‎

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

‎Cargo.toml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ winresource = "0.1"
3434
rustpython-compiler = { workspace = true }
3535
rustpython-pylib = { workspace = true, optional = true }
3636
rustpython-stdlib = { workspace = true, optional = true, features = ["compiler"] }
37-
rustpython-vm = { workspace = true, features = ["compiler"] }
37+
rustpython-vm = { workspace = true, features = ["compiler", "gc"] }
3838
ruff_python_parser = { workspace = true }
3939

4040
cfg-if = { workspace = true }

‎Lib/test/support/__init__.py‎

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -883,13 +883,6 @@ def disable_gc():
883883

884884
@contextlib.contextmanager
885885
def gc_threshold(*args):
886-
# TODO: RUSTPYTHON; GC is not supported yet
887-
try:
888-
yield
889-
finally:
890-
pass
891-
return
892-
893886
import gc
894887
old_threshold = gc.get_threshold()
895888
gc.set_threshold(*args)

‎Lib/test/test_asyncio/test_ssl.py‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1649,7 +1649,6 @@ async def test(ctx):
16491649
# SSLProtocol should be DECREF to 0
16501650
self.assertIsNone(ctx())
16511651

1652-
@unittest.expectedFailure # TODO: RUSTPYTHON; - gc.collect() doesn't release SSLContext properly
16531652
def test_shutdown_timeout_handler_leak(self):
16541653
loop = self.loop
16551654

0 commit comments

Comments
 (0)