-
-
Notifications
You must be signed in to change notification settings - Fork 323
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
g.extension: catch missing modules.xml error #2058
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Print error message when is missing on server. So far this error appeared: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l /home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension:167: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.dir_util import copy_tree List of available extensions (modules): https://grass.osgeo.org/addons/grass8/modules.xml Fetching list of extensions from GRASS-Addons SVN repository (be patient)... https://grass.osgeo.org/addons/grass8/ Traceback (most recent call last): File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 682, in list_available_modules tree = etree_fromurl(file_url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 384, in etree_fromurl file_ = urlopen(url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 236, in urlopen return urlrequest.urlopen(request, *args, **kwargs) File "/usr/lib64/python3.10/urllib/request.py", line 216, in urlopen return opener.open(url, data, timeout) File "/usr/lib64/python3.10/urllib/request.py", line 525, in open response = meth(req, response) File "/usr/lib64/python3.10/urllib/request.py", line 634, in http_response response = self.parent.error( File "/usr/lib64/python3.10/urllib/request.py", line 563, in error return self._call_chain(*args) File "/usr/lib64/python3.10/urllib/request.py", line 496, in _call_chain result = func(*args) File "/usr/lib64/python3.10/urllib/request.py", line 643, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 404: Not Found During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 2571, in <module> sys.exit(main()) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 2518, in main list_available_extensions(xmlurl) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 557, in list_available_extensions list_available_modules(url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 694, in list_available_modules list_available_extensions_svn(url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 762, in list_available_extensions_svn sline = pattern.search(line) TypeError: cannot use a string pattern on a bytes-like object ``` With this PR: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l /home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension:167: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.dir_util import copy_tree List of available extensions (modules): ERROR: Download file from <https://grass.osgeo.org/addons/grass8/modules.xml>, failed. File not on server or check internet connection. ```
neteler
added
bug
Something isn't working
backport_needed
Python
Related code is in Python
labels
Jan 1, 2022
tmszi
requested changes
Jan 1, 2022
tmszi
approved these changes
Jan 1, 2022
neteler
added a commit
that referenced
this pull request
Jan 1, 2022
* g.extension: catch error missing modules.xml Print error message when https://grass.osgeo.org/addons/grass8/modules.xml is missing on server. So far this error appeared: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l ... Fetching list of extensions from GRASS-Addons SVN repository (be patient)... https://grass.osgeo.org/addons/grass8/ Traceback (most recent call last): File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 682, in list_available_modules tree = etree_fromurl(file_url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 384, in etree_fromurl file_ = urlopen(url) ... File "/usr/lib64/python3.10/urllib/request.py", line 643, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 404: Not Found ... ``` With this PR: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l /home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension:167: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.dir_util import copy_tree List of available extensions (modules): ERROR: Download file from <https://grass.osgeo.org/addons/grass8/modules.xml>, failed. File not on server or check internet connection. ```
ninsbl
pushed a commit
to ninsbl/grass
that referenced
this pull request
Oct 26, 2022
* g.extension: catch error missing modules.xml Print error message when https://grass.osgeo.org/addons/grass8/modules.xml is missing on server. So far this error appeared: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l ... Fetching list of extensions from GRASS-Addons SVN repository (be patient)... https://grass.osgeo.org/addons/grass8/ Traceback (most recent call last): File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 682, in list_available_modules tree = etree_fromurl(file_url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 384, in etree_fromurl file_ = urlopen(url) ... File "/usr/lib64/python3.10/urllib/request.py", line 643, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 404: Not Found ... ``` With this PR: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l /home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension:167: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.dir_util import copy_tree List of available extensions (modules): ERROR: Download file from <https://grass.osgeo.org/addons/grass8/modules.xml>, failed. File not on server or check internet connection. ```
ninsbl
pushed a commit
to ninsbl/grass
that referenced
this pull request
Feb 17, 2023
* g.extension: catch error missing modules.xml Print error message when https://grass.osgeo.org/addons/grass8/modules.xml is missing on server. So far this error appeared: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l ... Fetching list of extensions from GRASS-Addons SVN repository (be patient)... https://grass.osgeo.org/addons/grass8/ Traceback (most recent call last): File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 682, in list_available_modules tree = etree_fromurl(file_url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 384, in etree_fromurl file_ = urlopen(url) ... File "/usr/lib64/python3.10/urllib/request.py", line 643, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 404: Not Found ... ``` With this PR: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l /home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension:167: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.dir_util import copy_tree List of available extensions (modules): ERROR: Download file from <https://grass.osgeo.org/addons/grass8/modules.xml>, failed. File not on server or check internet connection. ```
neteler
added a commit
to nilason/grass
that referenced
this pull request
Nov 7, 2023
* g.extension: catch error missing modules.xml Print error message when https://grass.osgeo.org/addons/grass8/modules.xml is missing on server. So far this error appeared: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l ... Fetching list of extensions from GRASS-Addons SVN repository (be patient)... https://grass.osgeo.org/addons/grass8/ Traceback (most recent call last): File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 682, in list_available_modules tree = etree_fromurl(file_url) File "/home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension", line 384, in etree_fromurl file_ = urlopen(url) ... File "/usr/lib64/python3.10/urllib/request.py", line 643, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp) urllib.error.HTTPError: HTTP Error 404: Not Found ... ``` With this PR: ``` GRASS nc_spm_08_grass7/user1:grass_main > g.extension -l /home/mneteler/software/grass80/dist.x86_64-pc-linux-gnu/scripts/g.extension:167: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives from distutils.dir_util import copy_tree List of available extensions (modules): ERROR: Download file from <https://grass.osgeo.org/addons/grass8/modules.xml>, failed. File not on server or check internet connection. ```
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Print error message when
https://grass.osgeo.org/addons/grass8/modules.xml
is missing on server (generated here: https://github.com/OSGeo/grass-addons/tree/grass8/utils/cronjobs_osgeo_lxd).
So far this error appears:
With this PR: