GeezerVisonThe World Wide Web, restored to 800 pixels of glory. |
| Home|About|Gaming cabinet|Archives|How it works|Starter sites |
GeezerVison is showing github.com — shutil.make_archive now fails with pathlib.Path object in Python 3.11.0b4 · Issue #94844 · python/cpython Closed Labels 3.10 (EOL)end of lifeend of life3.11only security fixesonly security fixes3.12only security fixesonly security fixestopic-pathlibtype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error DescriptionBug report This code works on Python 3.10 and Python 3.11.0a5 but raises a from pathlib import Path from shutil import make_archive path = Path.cwd().resolve() make_archive(path, 'zip', path.parent, path.name) Here's the output I see in Python 3.11.0b4: >>> from pathlib import Path >>> from shutil import make_archive >>> path = Path.cwd().resolve() >>> make_archive(path, 'zip', path.parent, path.name) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/trey/.pyenv/versions/3.11.0b4/lib/python3.11/shutil.py", line 1130, in make_archive filename = func(base_name, base_dir, **kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "/home/trey/.pyenv/versions/3.11.0b4/lib/python3.11/shutil.py", line 977, in _make_zipfile zip_filename = base_name + ".zip" ~~~~~~~~~~^~~~~~~~ TypeError: unsupported operand type(s) for +: 'PosixPath' and 'str' Your environment
Activity
MetadataMetadataAssigneesLabels3.10 (EOL)end of lifeend of life3.11only security fixesonly security fixes3.12only security fixesonly security fixestopic-pathlibtype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error ProjectsMilestoneRelationshipsDevelopmentIssue actions |
| You are visitor 01402503 — GeezerVison does not store the pages you look up. Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required. |