Hello
I am a real newbie in this… and I get this error after trying many things. Is there anything I could do about this? I am using visual studio code to run the terminal for django project. I am trying to install the requirements for django project. Thank you
Here the error:
Collecting backports.zoneinfo
Using cached backports.zoneinfo-0.2.1.tar.gz (74 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: backports.zoneinfo
Building wheel for backports.zoneinfo (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for backports.zoneinfo (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [38 lines of output]
running bdist_wheel
running build
running build_py
creating build
creating build\lib.win-amd64-cpython-312
creating build\lib.win-amd64-cpython-312\backports
copying src\backports\__init__.py -> build\lib.win-amd64-cpython-312\backports
creating build\lib.win-amd64-cpython-312\backports\zoneinfo
copying src\backports\zoneinfo\_common.py -> build\lib.win-amd64-cpython-312\backports\zoneinfo
copying src\backports\zoneinfo\_tzpath.py -> build\lib.win-amd64-cpython-312\backports\zoneinfo
copying src\backports\zoneinfo\_version.py -> build\lib.win-amd64-cpython-312\backports\zoneinfo
copying src\backports\zoneinfo\_zoneinfo.py -> build\lib.win-amd64-cpython-312\backports\zoneinfo
copying src\backports\zoneinfo\__init__.py -> build\lib.win-amd64-cpython-312\backports\zoneinfo
running egg_info
writing src\backports.zoneinfo.egg-info\PKG-INFO
writing dependency_links to src\backports.zoneinfo.egg-info\dependency_links.txt
writing requirements to src\backports.zoneinfo.egg-info\requires.txt
writing top-level names to src\backports.zoneinfo.egg-info\top_level.txt
reading manifest file 'src\backports.zoneinfo.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no files found matching '*.png' under directory 'docs'
warning: no files found matching '*.svg' under directory 'docs'
no previously-included directories found matching 'docs\_build'
no previously-included directories found matching 'docs\_output'
adding license file 'LICENSE'
adding license file 'licenses/LICENSE_APACHE'
writing manifest file 'src\backports.zoneinfo.egg-info\SOURCES.txt'
copying src\backports\zoneinfo\__init__.pyi -> build\lib.win-amd64-cpython-312\backports\zoneinfo
copying src\backports\zoneinfo\py.typed -> build\lib.win-amd64-cpython-312\backports\zoneinfo
running build_ext
building 'backports.zoneinfo._czoneinfo' extension
creating build\temp.win-amd64-cpython-312
creating build\temp.win-amd64-cpython-312\Release
creating build\temp.win-amd64-cpython-312\Release\lib
"C:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.39.33519\bin\HostX86\x64\cl.exe" /c /nologo /O2 /W3 /GL /DNDEBUG /MD "-IE:\pasca-fatimah\pelatihan python\try again\my_ecommerce\env\include" -IC:\Users\fina\AppData\Local\Programs\Python\Python312\include -IC:\Users\fina\AppData\Local\Programs\Python\Python312\Include "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC\14.39.33519\include" "-IC:\Program Files (x86)\Microsoft Visual Studio\2022\BuildTools\VC\Auxiliary\VS\include" /Tclib/zoneinfo_module.c /Fobuild\temp.win-amd64-cpython-312\Release\lib/zoneinfo_module.obj
zoneinfo_module.c
C:\Users\fina\AppData\Local\Programs\Python\Python312\include\pyconfig.h(59): fatal error C1083: Cannot open include file: 'io.h': No such file or directory
error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2022\\BuildTools\\VC\\Tools\\MSVC\\14.39.33519\\bin\\HostX86\\x64\\cl.exe' failed with exit code 2
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for backports.zoneinfo
Failed to build backports.zoneinfo
ERROR: Could not build wheels for backports.zoneinfo, which is required to install pyproject.toml-based projects
python_version<3.9 : The term 'python_version<3.9' is not recognized as the name of a cmdlet, function, script file, or operable
program. Check the spelling of the name, or if a path was included, verify that the path is correct and try again.
At line:1 char:32
+ pip install backports.zoneinfo;python_version<"3.9"
+ ~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (python_version<3.9:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
Thank you very much if there’s any information or solution for this
Quoting directly from the docs at backports.zoneinfo · PyPI
Support for backports.zoneinfo
in Python 3.9+ is currently minimal, since it is expected that you would use the standard library zoneinfo
module instead.
If you do not support anything earlier than Python 3.9, you do not need this library ;
You probably shouldn’t even be trying to use this with Python 3.12.
Thank you very much… i’d changed it to 3.8 but i faced another problem afterwards so I was getting back to 3.12 and I installed it manually. Luckily it works… and I’ve done it.
Thank you very much for your kind response