Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UMEP Python Packages installing error #83

Closed
uta1998 opened this issue Jul 15, 2024 · 12 comments
Closed

UMEP Python Packages installing error #83

uta1998 opened this issue Jul 15, 2024 · 12 comments
Assignees

Comments

@uta1998
Copy link

uta1998 commented Jul 15, 2024

Hi,

I just installed Qgis latest stable version 3.34.8 and i get the error attached: " UMEP couldn't install Python packages"

UMEP processing

Would you know how to install them? thanks in advance

@uta1998
Copy link
Author

uta1998 commented Jul 15, 2024

then, when i try launching an UMEP study i get this error message:
Traceback (most recent call last):
File "C:\Users/FR0088/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ICEtool\Scripts\ShadowGenerator\shadow_generator.py", line 419, in start_progress
shadowresult = dsh.dailyshading(dsm, vegdsm, vegdsm2, scale, lon, lat, sizex, sizey, tv, UTC, usevegdem,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/FR0088/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ICEtool\Scripts\ShadowGenerator\dailyshading.py", line 133, in dailyshading
shadowresult = shadow.shadowingfunction_20(dsm, vegdem, vegdem2, azi[i], alt[i], scale, amaxvalue,
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users/FR0088/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ICEtool\Scripts\Utilities\shadowingfunctions.py", line 155, in shadowingfunction_20
dlg.progressBar.setValue(index)
TypeError: setValue(self, value: int): argument 1 has unexpected type 'float'

@uta1998
Copy link
Author

uta1998 commented Jul 18, 2024

@biglimp would you know how to solve this?

@wicand00
Copy link

wicand00 commented Aug 6, 2024

I had the same issue with QGIS version 3.34.9 after the update. I re-installed the UMEP-Plugins, it asked to install the python packages again and it finally worked. Did not test the plugins but the installation of the packages seems to work like that.

@biglimp
Copy link
Contributor

biglimp commented Aug 12, 2024

Sorry for late reply. Were you able to install?

@nissepistol
Copy link

I'm also getting the same error, trying to reinstall the plugin has not resolved the issue for me.

@biglimp
Copy link
Contributor

biglimp commented Oct 16, 2024

I'm also getting the same error, trying to reinstall the plugin has not resolved the issue for me.

Please report version of QGIS, OS and UMEP version you are trying to install.

@nissepistol
Copy link

nissepistol commented Oct 16, 2024

Thank you for your swift reply!

In April and May I tried with QGIS 3.34.4, today I tried it with both 3.34.10 and 3.34.11, getting the same error in all tries.
All tries have been with UMEP 4.0.4, using Windows 11 Enterprise now with the 23H2 version.

Just now I upgraded to yesterdays latest UMEP release 4.1.1 but the error persists.

@biglimp
Copy link
Contributor

biglimp commented Oct 16, 2024

Thank you for your swift reply!

In April and May I tried with QGIS 3.34.4, today I tried it with both 3.34.10 and 3.34.11, getting the same error in all tries. All tries have been with UMEP 4.0.4, using Windows 11 Enterprise now with the 23H2 version.

Just now I upgraded to yesterdays latest UMEP release 4.1.1 but the error persists.

You should update your QGIS and try again. Also, what does the log-message say?

@nissepistol
Copy link

nissepistol commented Oct 16, 2024

I just updated today to the latest LTR though, wouldn't that be sufficient though?

There are 3 separate groups of warnings in the log:

1

2024-10-16T11:29:30     WARNING    Error running (1, ['C:\\PROGRA~1\\QGIS33~1.11\\apps\\Python312\\..\\..\\bin\\pythonw.exe', '-m', 'pip', 'install', 'umep-reqs', '-U', '--user', '--prefer-binary']):
             Requirement already satisfied: umep-reqs in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (2.2)
             WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/umep-reqs/
             WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/umep-reqs/
             WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/umep-reqs/
             WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/umep-reqs/
             WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/umep-reqs/
             Could not fetch URL https://pypi.org/simple/umep-reqs/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/umep-reqs/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))) - skipping
             Requirement already satisfied: supy==2024.5.24.dev in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from umep-reqs) (2024.5.24.dev0)
             Requirement already satisfied: numba==0.59.0 in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from umep-reqs) (0.59.0)
             Requirement already satisfied: jaydebeapi==1.2.3 in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from umep-reqs) (1.2.3)
             Requirement already satisfied: netCDF4 in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from umep-reqs) (1.7.1.post2)
             Requirement already satisfied: JPype1 in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from jaydebeapi==1.2.3->umep-reqs) (1.5.0)
             Requirement already satisfied: llvmlite=0.42.0dev0 in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from numba==0.59.0->umep-reqs) (0.42.0)
             Requirement already satisfied: numpy=1.22 in c:\progra~1\qgis33~1.11\apps\python312\lib\site-packages (from numba==0.59.0->umep-reqs) (1.26.4)
             Requirement already satisfied: pandas in c:\progra~1\qgis33~1.11\apps\python312\lib\site-packages (from supy==2024.5.24.dev->umep-reqs) (2.2.2)
             Requirement already satisfied: matplotlib in c:\progra~1\qgis33~1.11\apps\python312\lib\site-packages (from supy==2024.5.24.dev->umep-reqs) (3.8.4)
             Requirement already satisfied: chardet in c:\progra~1\qgis33~1.11\apps\python312\lib\site-packages (from supy==2024.5.24.dev->umep-reqs) (5.2.0)
             Requirement already satisfied: scipy in c:\progra~1\qgis33~1.11\apps\python312\lib\site-packages (from supy==2024.5.24.dev->umep-reqs) (1.13.0)
             Requirement already satisfied: f90wrap==0.2.14 in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (0.2.14)
             Requirement already satisfied: dask in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (2024.9.1)
             Requirement already satisfied: f90nml in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (1.4.4)
             Requirement already satisfied: seaborn in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (0.13.2)
             Requirement already satisfied: atmosp in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (0.2.9)
             Requirement already satisfied: cdsapi in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (0.7.3)
             Requirement already satisfied: xarray in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (2024.9.0)
             Requirement already satisfied: multiprocess in c:\users\USERNAME\appdata\roaming\python\python312\site-packages (from supy==2024.5.24.dev->umep-reqs) (0.70.17)
             WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/click/
             WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/click/
             WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/click/
             WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/click/
             WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/click/
             Could not fetch URL https://pypi.org/simple/click/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/click/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))) - skipping
             INFO: pip is looking at multiple versions of supy to determine which version is compatible with other requirements. This could take a while.
             WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/supy/
             WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/supy/
             WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/supy/
             WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/supy/
             WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))': /simple/supy/
             Could not fetch URL https://pypi.org/simple/supy/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/supy/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))) - skipping
             ERROR: Could not find a version that satisfies the requirement click (from supy) (from versions: none)
             ERROR: No matching distribution found for click
             Could not fetch URL https://pypi.org/simple/pip/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/pip/ (Caused by SSLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:1000)'))) - skipping

2:

2024-10-16T11:29:30     WARNING    Traceback (most recent call last):
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\util\__init__.py", line 18, in 
              import supy as sp
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\Users\USERNAME\AppData\Roaming\Python\Python312\site-packages\supy\__init__.py", line 47, in 
              from .cmd import SUEWS
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\Users\USERNAME\AppData\Roaming\Python\Python312\site-packages\supy\cmd\__init__.py", line 1, in 
              from .SUEWS import SUEWS
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\Users\USERNAME\AppData\Roaming\Python\Python312\site-packages\supy\cmd\SUEWS.py", line 4, in 
              import click
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
             ModuleNotFoundError: No module named 'click'
             
             During handling of the above exception, another exception occurred:
             
             Traceback (most recent call last):
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\util\umep_installer.py", line 129, in setup_umep_python
              import supy as sp
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\Users\USERNAME\AppData\Roaming\Python\Python312\site-packages\supy\__init__.py", line 47, in 
              from .cmd import SUEWS
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\Users\USERNAME\AppData\Roaming\Python\Python312\site-packages\supy\cmd\__init__.py", line 1, in 
              from .SUEWS import SUEWS
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\Users\USERNAME\AppData\Roaming\Python\Python312\site-packages\supy\cmd\SUEWS.py", line 4, in 
              import click
              File "C:\PROGRA~1/QGIS33~1.11/apps/qgis-ltr/./python\qgis\utils.py", line 892, in _import
              mod = _builtin_import(name, globals, locals, fromlist, level)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
             ModuleNotFoundError: No module named 'click'
             
             During handling of the above exception, another exception occurred:
             
             Traceback (most recent call last):
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\util\__init__.py", line 38, in 
              setup_umep_python(ver=None)
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\util\umep_installer.py", line 136, in setup_umep_python
              install_umep_python(ver)
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\processing_umep\util\umep_installer.py", line 90, in install_umep_python
              str_info = subprocess.check_output(
              ^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\PROGRA~1\QGIS33~1.11\apps\Python312\Lib\subprocess.py", line 466, in check_output
              return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
              File "C:\PROGRA~1\QGIS33~1.11\apps\Python312\Lib\subprocess.py", line 571, in run
              raise CalledProcessError(retcode, process.args,
             subprocess.CalledProcessError: Command '['C:\\PROGRA~1\\QGIS33~1.11\\apps\\Python312\\..\\..\\bin\\pythonw.exe', '-m', 'pip', 'install', 'umep-reqs', '-U', '--user', '--prefer-binary']' returned non-zero exit status 1.

3:

2024-10-16T11:30:34     WARNING    Exception
             
             The above exception was the direct cause of the following exception:
             
             Traceback (most recent call last):
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\UMEP\suewsmodel\__init__.py", line 36, in 
              setup_supy(ver='2024.5.24.dev')
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\UMEP\suewsmodel\supy_installer.py", line 134, in setup_supy
              install_supy(ver)
              File "C:\Users/USERNAME/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\UMEP\suewsmodel\supy_installer.py", line 103, in install_supy
              raise RuntimeError(f"UMEP couldn't install supy {str_ver}!") from Exception
             RuntimeError: UMEP couldn't install supy ==2024.5.24.dev!

@biglimp
Copy link
Contributor

biglimp commented Oct 16, 2024

@sunt05 this used seem to have issues with supy and click.
@nissepistol , yes LTR should be enough. Sometimes thing heals itself when updating QGIS.

@sunt05
Copy link
Contributor

sunt05 commented Oct 16, 2024

Hi @nissepistol - did you try installing click using pip install click in the pure Python command line environment? Any success?

@nissepistol
Copy link

nissepistol commented Oct 16, 2024

Thank you @biglimp and @sunt05 for your help, you guided me directly to the solution.
It was a certificate problem and my company didn't trust supy and click.

After trying to install the packages with pip in the OSGeo4W Shell, I got the problem code indicating it was a certificate issue.

Solution:

  1. Start OSGeo4W Shell.
  2. Run this line to update the list of trusted packages:
python -m pip install pip-system-certs --trusted-host pypi.org --trusted-host files.pythonhosted.org --trusted-host pypi.python.org
  1. Start QGIS. Then QGIS could automatically update the missing packages (or you can install them yourself in the shell typing "pip install supy click").

Thanks again!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants