Closed pskunjeer closed 5 years ago
The issue is clear from the log:
> python3 -m pip install --prefix /home/emsuser/.local/share/gis4wrf/python36 netCDF4==1.2.9
ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations
What OS are you using? Next time please use the template.
Sorry for not mentioning the OS. The OS is Ubuntu 18.04
On Fri, Mar 8, 2019, 6:05 PM dmey <notifications@github.com wrote:
The issue is clear from the log:
python3 -m pip install --prefix /home/emsuser/.local/share/gis4wrf/python36 netCDF4==1.2.9
ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations
What OS are you using? Next time please use the template.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/GIS4WRF/gis4wrf/issues/115#issuecomment-470913687, or mute the thread https://github.com/notifications/unsubscribe-auth/AMuClI5yMY_eSRakxXCTCbzP7g7lIoEuks5vUlkDgaJpZM4blQFF .
Did you follow the instructuons at https://gis4wrf.github.io/installation/#18x-bionic exactly as they are? Specifically, have you done:
pip3 install --user f90nml pyyaml netCDF4 wrf-python
(base) emsuser@psk:~$ pip3 install --user f90nml pyyaml netCDF4 wrf-python Requirement already satisfied: f90nml in ./.local/lib/python3.7/site-packages (1.0.2) Requirement already satisfied: pyyaml in ./anaconda3/lib/python3.7/site-packages (3.13) Requirement already satisfied: netCDF4 in ./.local/lib/python3.7/site-packages (1.4.3.1) Requirement already satisfied: wrf-python in ./anaconda3/lib/python3.7/site-packages (1.3.2) Requirement already satisfied: cftime in ./.local/lib/python3.7/site-packages (from netCDF4) (1.0.3.4) Requirement already satisfied: numpy>=1.7 in ./anaconda3/lib/python3.7/site-packages (from netCDF4) (1.16.2) Requirement already satisfied: wrapt in ./anaconda3/lib/python3.7/site-packages (from wrf-python) (1.10.11) Requirement already satisfied: setuptools in ./anaconda3/lib/python3.7/site-packages (from wrf-python) (40.2.0)
All requirements are satisfied but still not able to install the GIS4WRF
Ah, there's a confusion with Python versions here. Your pip3 from the command line refers to the Anaconda Python 3.7 installation (./anaconda3/lib/python3.7), whereas QGIS uses the system Python 3 from /usr/lib which is Python 3.6. QGIS/gis4wrf would only find packages that are installed for the system Python, not the Anaconda one.
I recommend that you figure out how to get out of your Anaconda setup from the shell and then do a pip3 install again, this time for the system Python. You can figure out which Python you're dealing with by doing which pip3
.
Good luck! And yes, it should all be nicer and work automatically, but unfortunately QGIS doesn't provide the necessary infrastructure to make it happen.
I have removed the anaconda and reinstall the qgis
Now I can install the GIS4WRF, but while running the geogrid I get the following error
2019-03-18T22:40:55 WARNING warning:/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/plugin/ui/thread.py:85: ResourceWarning:
unclosed file
traceback: File "/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/plugin/ui/thread.py", line 85, in run
self.use_mpi, self.mpi_processes):
The error message is incomplete, can you please copy everything?
Also, closing this as your original issue is resolved. But feel free to keep commenting, or if you think it deserves a separate issue, then please open a new one.
Couldn't load plugin 'gis4wrf' due to an error when calling its classFactory() method
RuntimeError: GIS4WRF: Error installing Python packages Log: Added /home/emsuser/.local/share/gis4wrf/python36/local/lib/python3.6/dist-packages as module search pathAdded /home/emsuser/.local/share/gis4wrf/python36/lib/python3/dist-packages as module search pathAdded /home/emsuser/.local/share/gis4wrf/python36/lib/python3.6/dist-packages as module search pathPackage directory: /home/emsuser/.local/share/gis4wrf/python36/usr/bin/python3 -m pip install --prefix /home/emsuser/.local/share/gis4wrf/python36 netCDF4==1.2.9ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations Traceback (most recent call last): File "/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/init.py", line 39, in bootstrap_with_ui for msg_type, msg_val in bootstrap(): File "/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/bootstrap.py", line 215, in bootstrap for line in run_subprocess(args, LOG_PATH): File "/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/bootstrap.py", line 244, in run_subprocess raise subprocess.CalledProcessError(process.returncode, args) subprocess.CalledProcessError: Command '['/usr/bin/python3', '-m', 'pip', 'install', '--prefix', '/home/emsuser/.local/share/gis4wrf/python36', 'netCDF4==1.2.9']' returned non-zero exit status 1.
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "/usr/lib/python3/dist-packages/qgis/utils.py", line 335, in startPlugin plugins[packageName] = package.classFactory(iface) File "/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/init.py", line 22, in classFactory bootstrap_with_ui(iface) File "/home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/gis4wrf/init.py", line 62, in bootstrap_with_ui raise RuntimeError(PLUGIN_NAME + ': Error installing Python packages\nLog:\n' + log) from e RuntimeError: GIS4WRF: Error installing Python packages Log: Added /home/emsuser/.local/share/gis4wrf/python36/local/lib/python3.6/dist-packages as module search pathAdded /home/emsuser/.local/share/gis4wrf/python36/lib/python3/dist-packages as module search pathAdded /home/emsuser/.local/share/gis4wrf/python36/lib/python3.6/dist-packages as module search pathPackage directory: /home/emsuser/.local/share/gis4wrf/python36/usr/bin/python3 -m pip install --prefix /home/emsuser/.local/share/gis4wrf/python36 netCDF4==1.2.9ERROR: Can not combine '--user' and '--prefix' as they imply different installation locations
Python version: 3.6.7 (default, Oct 22 2018, 11:32:17) [GCC 8.2.0] QGIS version: 3.6.0-Noosa Noosa, 5873452
Python Path: /usr/share/qgis/python /home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python /home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins /usr/share/qgis/python/plugins /usr/lib/python36.zip /usr/lib/python3.6 /usr/lib/python3.6/lib-dynload /home/emsuser/.local/lib/python3.6/site-packages /usr/local/lib/python3.6/dist-packages /usr/lib/python3/dist-packages /home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python /home/emsuser/.local/share/QGIS/QGIS3/profiles/default/python/plugins/SwapVectorDirection /home/emsuser/.local/share/gis4wrf/python36/local/lib/python3.6/dist-packages /home/emsuser/.local/share/gis4wrf/python36/lib/python3/dist-packages /home/emsuser/.local/share/gis4wrf/python36/lib/python3.6/dist-packages /usr/lib/python3/dist-packages/IPython/extensions