cdown / srt

A simple library and set of tools for parsing, modifying, and composing SRT files.
MIT License
465 stars 44 forks source link

Can't install using Python 3.12 #95

Closed greenozon closed 6 months ago

greenozon commented 10 months ago

Can't install using Python 3.12

image

cdown commented 10 months ago

It works just fine:

% python --version
Python 3.12.0
% pip --version    
pip 23.3.1 from /home/cdown/.pyenv/versions/3.12.0/lib/python3.12/site-packages/pip (python 3.12)
% pip install srt  
Collecting srt
  Using cached srt-3.5.3-py3-none-any.whl
Installing collected packages: srt
Successfully installed srt-3.5.3

Can you please show your steps?

greenozon commented 10 months ago

For the moment I"m having older python and it is fine, will install 3.12 again and report in a little while

Python 3.10.13 pip 23.3.1 srt==3.5.3

greenozon commented 10 months ago

so in my case it wanted to build the package:

c:\Dev\python>python -V
Python 3.12.0

c:\Dev\python>pip -V
pip 23.2.1 from C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\pip (python 3.12)

c:\Dev\python>pip install srt
Collecting srt
  Downloading srt-3.5.3.tar.gz (28 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: srt
  Building wheel for srt (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for srt (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [56 lines of output]
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build\lib
      copying srt.py -> build\lib
      creating build\lib\srt_tools
      copying srt_tools\__init__.py -> build\lib\srt_tools
      copying srt_tools\utils.py -> build\lib\srt_tools
      running build_scripts
      creating build\scripts-3.12
      copying and adjusting srt_tools\srt -> build\scripts-3.12
      copying and adjusting srt_tools\srt-deduplicate -> build\scripts-3.12
      copying and adjusting srt_tools\srt-normalise -> build\scripts-3.12
      copying and adjusting srt_tools\srt-fixed-timeshift -> build\scripts-3.12
      copying and adjusting srt_tools\srt-linear-timeshift -> build\scripts-3.12
      copying and adjusting srt_tools\srt-lines-matching -> build\scripts-3.12
      copying and adjusting srt_tools\srt-mux -> build\scripts-3.12
      copying and adjusting srt_tools\srt-play -> build\scripts-3.12
      copying and adjusting srt_tools\srt-process -> build\scripts-3.12
      installing to build\bdist.win-amd64\wheel
      running install
      running install_lib
      creating build\bdist.win-amd64
      creating build\bdist.win-amd64\wheel
      copying build\lib\srt.py -> build\bdist.win-amd64\wheel\.
      creating build\bdist.win-amd64\wheel\srt_tools
      copying build\lib\srt_tools\utils.py -> build\bdist.win-amd64\wheel\.\srt_tools
      copying build\lib\srt_tools\__init__.py -> build\bdist.win-amd64\wheel\.\srt_tools
      running install_egg_info
      running egg_info
      writing srt.egg-info\PKG-INFO
      writing dependency_links to srt.egg-info\dependency_links.txt
      writing top-level names to srt.egg-info\top_level.txt
      reading manifest file 'srt.egg-info\SOURCES.txt'
      reading manifest template 'MANIFEST.in'
......

      copying build\scripts-3.12\srt-play -> build\bdist.win-amd64\wheel\srt-3.5.3.data\scripts
      copying build\scripts-3.12\srt-process -> build\bdist.win-amd64\wheel\srt-3.5.3.data\scripts
      creating build\bdist.win-amd64\wheel\srt-3.5.3.dist-info\WHEEL
      creating 'C:\Users\user\AppData\Local\Temp\pip-wheel-1suf4br2\.tmp-6xlv8qqg\srt-3.5.3-py3-none-any.whl' and adding 'build\bdist.win-amd64\wheel' to it
      error: [WinError 87] The parameter is incorrect
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for srt
Failed to build srt
ERROR: Could not build wheels for srt, which is required to install pyproject.toml-based projects
WARNING: There was an error checking the latest version of pip.
cdown commented 10 months ago

[WinError 87] The parameter is incorrect

This is something to do with your local restrictions, antivirus, or otherwise. It's not a problem with srt.

greenozon commented 10 months ago

Thanks for feedback, I'll try to dig deeper and understand the error 87 meanwhile anybody else is experiencing similar error on Windows OS?

cdown commented 6 months ago

Closing, this is an environmental issue.

greenozon commented 6 months ago

forget to update, all is good, not sure what was the error above

just for history track:


c:\Users\user\Downloads>python --version
Python 3.12.1

c:\Users\user\Downloads>pip --version
pip 23.2.1 from C:\Users\user\AppData\Local\Programs\Python\Python312\Lib\site-packages\pip (python 3.12)

c:\Users\user\Downloads>pip freeze

c:\Users\user\Downloads>pip install srt
Collecting srt
  Using cached srt-3.5.3.tar.gz (28 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: srt
  Building wheel for srt (pyproject.toml) ... done
  Created wheel for srt: filename=srt-3.5.3-py3-none-any.whl size=22557 sha256=ee825b0084a9fcb24d6be58f621d450dd3a8cbeb1406bab54e5c294ce6f460a2
  Stored in directory: c:\users\user\appdata\local\pip\cache\wheels\7e\75\5b\e1d5c3756631e4bda806f6cc9640153b39484bb6f7b0b8def3
Successfully built srt
Installing collected packages: srt
Successfully installed srt-3.5.3
WARNING: There was an error checking the latest version of pip.

c:\Users\user\Downloads>pip freeze
srt==3.5.3