JustNao / Karrelage

MITM pour Dofus 2.XX
17 stars 8 forks source link

Error when installing requirements #4

Closed Magikh42 closed 8 months ago

Magikh42 commented 9 months ago

I get an error when I install the requirements

pip trace:

Collecting playsound (from -r requirements.txt (line 18))
  Using cached playsound-1.3.0.tar.gz (7.7 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
  error: subprocess-exited-with-error

  × Getting requirements to build wheel did not run successfully.
  │ exit code: 1
  ╰─> [28 lines of output]
      Traceback (most recent call last):
        File "C:\Users\Magi\AppData\Roaming\Python\Python311\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
          main()
        File "C:\Users\Magi\AppData\Roaming\Python\Python311\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\Magi\AppData\Roaming\Python\Python311\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 118, in get_requires_for_build_wheel
          return hook(config_settings)
                 ^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\Magi\AppData\Local\Temp\pip-build-env-pu2mwb7j\overlay\Lib\site-packages\setuptools\build_meta.py", line 355, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=['wheel'])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Users\Magi\AppData\Local\Temp\pip-build-env-pu2mwb7j\overlay\Lib\site-packages\setuptools\build_meta.py", line 325, in _get_build_requires
          self.run_setup()
        File "C:\Users\Magi\AppData\Local\Temp\pip-build-env-pu2mwb7j\overlay\Lib\site-packages\setuptools\build_meta.py", line 507, in run_setup
          super(_BuildMetaLegacyBackend, self).run_setup(setup_script=setup_script)
        File "C:\Users\Magi\AppData\Local\Temp\pip-build-env-pu2mwb7j\overlay\Lib\site-packages\setuptools\build_meta.py", line 341, in run_setup
          exec(code, locals())
        File "<string>", line 6, in <module>
        File "C:\Program Files\Python311\Lib\inspect.py", line 1262, in getsource
          lines, lnum = getsourcelines(object)
                        ^^^^^^^^^^^^^^^^^^^^^^
        File "C:\Program Files\Python311\Lib\inspect.py", line 1244, in getsourcelines
          lines, lnum = findsource(object)
                        ^^^^^^^^^^^^^^^^^^
        File "C:\Program Files\Python311\Lib\inspect.py", line 1081, in findsource
          raise OSError('could not get source code')
      OSError: could not get source code
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

Removing playsound from the requirements.txt file fix the problem and the app can start

Magikh42 commented 9 months ago

I tried to install the requirements of the lastest version and I still get this error

JustNao commented 9 months ago

Looks more like an environnement related issue. May come from the fact that it's using a cached download (file can be corrupted). You can try to force the reinstall with pip install --force-reinstall playsound. Otherwise downgrade the version of playsound until you find a working one for your specific environnement.