Skip to content

Commit

Permalink
Add .pth encoding to compat.py312
Browse files Browse the repository at this point in the history
  • Loading branch information
abravalheri committed May 22, 2024
1 parent 131b6e9 commit 36324d6
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions setuptools/compat/py312.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import sys

if sys.version_info >= (3, 13):
# Python 3.13 should support `.pth` files encoded in UTF-8
# See discussion in https://github.com/python/cpython/issues/77102
PTH_ENCODING = "utf-8"
else:
from .py39 import LOCALE_ENCODING

# PTH_ENCODING = "locale"
PTH_ENCODING = LOCALE_ENCODING

0 comments on commit 36324d6

Please sign in to comment.