This is an automated email from the ASF dual-hosted git repository. tvb pushed a commit to branch coldtom/url-error in repository https://gitbox.apache.org/repos/asf/buildstream.git
commit 86bdd030085e356a768d4e7136e8bc8c2c924899 Author: Thomas Coldrick <[email protected]> AuthorDate: Mon Jul 2 15:14:16 2018 +0100 Catch ValueError to prevent stack trace --- buildstream/plugins/sources/_downloadablefilesource.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/buildstream/plugins/sources/_downloadablefilesource.py b/buildstream/plugins/sources/_downloadablefilesource.py index ec9c0fb..4df4034 100644 --- a/buildstream/plugins/sources/_downloadablefilesource.py +++ b/buildstream/plugins/sources/_downloadablefilesource.py @@ -155,6 +155,9 @@ class DownloadableFileSource(Source): except (urllib.error.URLError, urllib.error.ContentTooShortError, OSError) as e: raise SourceError("{}: Error mirroring {}: {}" .format(self, self.url, e)) from e + except ValueError as e: + raise SourceError("{}: Error mirroring {}: {}" + .format(self, self.url, e)) from e def _get_mirror_dir(self): return os.path.join(self.get_mirror_directory(),
