mirror of
https://github.com/python/cpython.git
synced 2025-08-27 20:25:18 +00:00
gh-100585: Fixed a bug where importlib.resources.as_file was leaving file pointers open (GH-100586)
* gh-100585: Fixed open fp bug in the imporlib module * Added news for gh-100585
This commit is contained in:
parent
cf1c098180
commit
f10f503b24
2 changed files with 2 additions and 1 deletions
|
@ -155,5 +155,5 @@ def _write_contents(target, source):
|
|||
for item in source.iterdir():
|
||||
_write_contents(child, item)
|
||||
else:
|
||||
child.open('wb').write(source.read_bytes())
|
||||
child.write_bytes(source.read_bytes())
|
||||
return child
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
Fixed a bug where importlib.resources.as_file was leaving file pointers open
|
Loading…
Add table
Add a link
Reference in a new issue