omkarcloud / botasaurus

The All in One Framework to build Awesome Scrapers.
https://www.omkar.cloud/botasaurus/
MIT License
1.36k stars 124 forks source link

python -m pip install botasaurus returning error #46

Closed CafePromenade closed 8 months ago

CafePromenade commented 8 months ago

Defaulting to user installation because normal site-packages is not writeable Obtaining file:///C:/Users/cntow/Downloads/Compressed/botasaurus-master/botasaurus-master Installing build dependencies ... done Checking if build backend supports build_editable ... done Getting requirements to build editable ... error error: subprocess-exited-with-error

× Getting requirements to build editable did not run successfully. │ exit code: 1 ╰─> [47 lines of output] C:\Users\cntow\AppData\Local\Microsoft\WindowsApps\PythonSoftwareFoundation.Python.3.12_qbz5n2kfra8p0\python.exe: No module named pip Traceback (most recent call last): File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.12_3.12.496.0_x64qbz5n2kfra8p0\Lib\importlib\metadata\init__.py", line 397, in from_name return next(cls.discover(name=name)) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ StopIteration

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "<string>", line 77, in install_javascript_package
    File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.12_3.12.496.0_x64__qbz5n2kfra8p0\Lib\importlib\metadata\__init__.py", line 861, in distribution
      return Distribution.from_name(distribution_name)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.12_3.12.496.0_x64__qbz5n2kfra8p0\Lib\importlib\metadata\__init__.py", line 399, in from_name
      raise PackageNotFoundError(name)
  importlib.metadata.PackageNotFoundError: No package metadata was found for javascript

  During handling of the above exception, another exception occurred:

  Traceback (most recent call last):
    File "C:\Users\cntow\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.12_qbz5n2kfra8p0\LocalCache\local-packages\Python312\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 353, in <module>
      main()
    File "C:\Users\cntow\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.12_qbz5n2kfra8p0\LocalCache\local-packages\Python312\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\cntow\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.12_qbz5n2kfra8p0\LocalCache\local-packages\Python312\site-packages\pip\_vendor\pyproject_hooks\_in_process\_in_process.py", line 132, in get_requires_for_build_editable
      return hook(config_settings)
             ^^^^^^^^^^^^^^^^^^^^^
    File "C:\Users\cntow\AppData\Local\Temp\pip-build-env-p_t7bham\overlay\Lib\site-packages\setuptools\build_meta.py", line 441, in get_requires_for_build_editable
      return self.get_requires_for_build_wheel(config_settings)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "C:\Users\cntow\AppData\Local\Temp\pip-build-env-p_t7bham\overlay\Lib\site-packages\setuptools\build_meta.py", line 325, in get_requires_for_build_wheel
      return self._get_build_requires(config_settings, requirements=['wheel'])
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "C:\Users\cntow\AppData\Local\Temp\pip-build-env-p_t7bham\overlay\Lib\site-packages\setuptools\build_meta.py", line 295, in _get_build_requires
      self.run_setup()
    File "C:\Users\cntow\AppData\Local\Temp\pip-build-env-p_t7bham\overlay\Lib\site-packages\setuptools\build_meta.py", line 480, in run_setup
      super(_BuildMetaLegacyBackend, self).run_setup(setup_script=setup_script)
    File "C:\Users\cntow\AppData\Local\Temp\pip-build-env-p_t7bham\overlay\Lib\site-packages\setuptools\build_meta.py", line 311, in run_setup
      exec(code, locals())
    File "<string>", line 87, in <module>
    File "<string>", line 83, in pre_install
    File "<string>", line 79, in install_javascript_package
    File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.12_3.12.496.0_x64__qbz5n2kfra8p0\Lib\subprocess.py", line 413, in check_call
      raise CalledProcessError(retcode, cmd)
  subprocess.CalledProcessError: Command '['C:\\Users\\cntow\\AppData\\Local\\Microsoft\\WindowsApps\\PythonSoftwareFoundation.Python.3.12_qbz5n2kfra8p0\\python.exe', '-m', 'pip', 'install', 'javascript']' returned non-zero exit status 1.
  [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 editable did not run successfully. │ exit code: 1 ╰─> See above for output.

Chetan11-dev commented 8 months ago

Fixed, run python -m pip install botasaurus --upgrade

AlexSnoow commented 8 months ago

hi I have the same problem too. Python 3.12.1. python -m pip install botasaurus --upgrade did not help :(

Chetan11-dev commented 8 months ago

Kindly run it again

alexandered22 commented 8 months ago

Same issue here

Chetan11-dev commented 8 months ago

I have released a fix. Please run, it again.

python -m pip install botasaurus --upgrade