File "/Users/aorumbayev/MakerX/projects/algokit/hello_pyteal_312/vote.py", line 3, in <module>
from pyteal import *
File "/Users/aorumbayev/Library/Caches/pypoetry/virtualenvs/hello-pyteal-312-qPNrebUk-py3.12/lib/python3.12/site-packages/pyteal/__init__.py", line 1, in <module>
from pyteal.ast import *
File "/Users/aorumbayev/Library/Caches/pypoetry/virtualenvs/hello-pyteal-312-qPNrebUk-py3.12/lib/python3.12/site-packages/pyteal/ast/__init__.py", line 54, in <module>
from pyteal.ast.pragma import Pragma
File "/Users/aorumbayev/Library/Caches/pypoetry/virtualenvs/hello-pyteal-312-qPNrebUk-py3.12/lib/python3.12/site-packages/pyteal/ast/pragma.py", line 4, in <module>
from pyteal.pragma import is_valid_compiler_version, pragma
File "/Users/aorumbayev/Library/Caches/pypoetry/virtualenvs/hello-pyteal-312-qPNrebUk-py3.12/lib/python3.12/site-packages/pyteal/pragma/__init__.py", line 1, in <module>
from pyteal.pragma.pragma import is_valid_compiler_version, pragma
File "/Users/aorumbayev/Library/Caches/pypoetry/virtualenvs/hello-pyteal-312-qPNrebUk-py3.12/lib/python3.12/site-packages/pyteal/pragma/pragma.py", line 2, in <module>
import pkg_resources
ModuleNotFoundError: No module named 'pkg_resources'
Subject of the issue
Python 3.12 no longer includes setuptools by default see -> https://github.com/python/cpython/issues/95299.
Pyteal relies on setuptools hence, compilation on any 3.12 environment seems to be failing at the moment.
Steps to reproduce
I have a bare minimum example repo with reproducible bug.
Expected behaviour
TEAL code is compiled
Actual behaviour