cedadev / CFA-Python

Climate Forecast Aggregation conventions reference implementation
Other
1 stars 1 forks source link

Installation fails (no requirements?) #9

Open bnlawrence opened 1 month ago

bnlawrence commented 1 month ago
git clone https://github.com/cedadev/CFA-Python.git
...
cd CFA-Python/
pip install ./
Processing /home/users/lawrence/GitRepos/CFA-Python
  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
  ╰─> [23 lines of output]
      Traceback (most recent call last):
        File "/home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
          return hook(config_settings)
                 ^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-yao01a75/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 325, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=['wheel'])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-yao01a75/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 295, in _get_build_requires
          self.run_setup()
        File "/tmp/pip-build-env-yao01a75/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 487, in run_setup
          super().run_setup(setup_script=setup_script)
        File "/tmp/pip-build-env-yao01a75/overlay/lib/python3.11/site-packages/setuptools/build_meta.py", line 311, in run_setup
          exec(code, locals())
        File "<string>", line 10, in <module>
        File "/home/users/lawrence/GitRepos/CFA-Python/CFAPython/__init__.py", line 4, in <module>
          import netCDF4      # this import has to remain to get the dynamic libraries loaded
          ^^^^^^^^^^^^^^
      ModuleNotFoundError: No module named 'netCDF4'
      [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.
bnlawrence commented 1 month ago

Clearly I can deal with this, but it would be better if the setup got requirements first.

bnlawrence commented 1 month ago

Oh, no I can't:

pip install netCDF4
Requirement already satisfied: netCDF4 in /home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages (1.6.5)
Requirement already satisfied: cftime in /home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages (from netCDF4) (1.6.3)
Requirement already satisfied: certifi in /home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages (from netCDF4) (2024.2.2)
Requirement already satisfied: numpy in /home/users/lawrence/.conda/envs/mampy24a/lib/python3.11/site-packages (from netCDF4) (1.26.4)

and still the install fails.

nmassey001 commented 2 weeks ago

This appears to happen in a conda environment.