achillesrasquinha / pipupgrade

🗽 Like yarn outdated/upgrade, but for pip. Upgrade all your pip packages and automate your Python Dependency Management.
https://git.io/pipupgrade
MIT License
587 stars 28 forks source link

Python3.12 Not supported yet? #147

Open ghost opened 1 year ago

ghost commented 1 year ago

Description

Versions: root@kali-linux:~# python3.12 Python 3.12.0a2+ (heads/main:3a803bcaac, Nov 25 2022, 10:46:40) [GCC 12.2.0] on linux Type "help", "copyright", "credits" or "license" for more information.

root@kali-linux:~# uname -a Linux kali-linux 6.0.0-kali6-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.0.12-1kali1 (2022-12-19) x86_64 GNU/Linux

root@kali-linux:~# python3.12 -m pip install pipupgrade
Collecting pipupgrade
  Downloading pipupgrade-1.12.0-py3-none-any.whl (34 kB)
Requirement already satisfied: pip in /usr/local/lib/python3.12/site-packages (from pipupgrade) (22.3.1)
Collecting bpyutils
  Downloading bpyutils-0.5.8-py3-none-any.whl (51 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 51.8/51.8 kB 1.7 MB/s eta 0:00:00
Installing collected packages: bpyutils, pipupgrade
Successfully installed bpyutils-0.5.8 pipupgrade-1.12.0
WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
root@kali-linux:~# python3.12 -m pipupgrade
Traceback (most recent call last):
  File "<frozen runpy>", line 189, in _run_module_as_main
  File "<frozen runpy>", line 148, in _get_module_details
  File "<frozen runpy>", line 112, in _get_module_details
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/__init__.py", line 23, in <module>
    from pipupgrade.__main__    import main
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/__main__.py", line 5, in <module>
    from   pipupgrade.commands import command as main
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/commands/__init__.py", line 11, in <module>
    from pipupgrade.commands.helper import (
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/commands/helper.py", line 10, in <module>
    from pipupgrade.model               import Registry
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/model/__init__.py", line 3, in <module>
    from pipupgrade.model.package  import Package
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/model/package.py", line 11, in <module>
    from pipupgrade                     import _pip, semver
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/_pip.py", line 58, in <module>
    _PIP_EXECUTABLES = _get_pip_executable(multiple = True)
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/pipupgrade/_pip.py", line 43, in _get_pip_executable
    exec_ = which(pip_)
            ^^^^^^^^^^^
  File "/usr/local/lib/python3.12/site-packages/bpyutils/util/system.py", line 79, in which
    from distutils.spawn import find_executable
ModuleNotFoundError: No module named 'distutils'

Screenshot

No response

Console errors

No response

mrichman commented 1 year ago

+1

staticf0x commented 1 year ago

It's from bpyutils, that package needs to support 3.12 and then pipupgrade should work too.