Skip to content

Commit

Permalink
Add LocationParseError exception to download images processor
Browse files Browse the repository at this point in the history
  • Loading branch information
sal-uva committed Sep 25, 2024
1 parent 7caafbe commit 579ff64
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions processors/visualisation/download_images.py
Original file line number Diff line number Diff line change
Expand Up @@ -574,6 +574,10 @@ def request_get_w_error_handling(self, url, retries=0, **kwargs):
else:
self.dataset.log("Error: ConnectionError while trying to download image %s: %s" % (url, e))
raise FileNotFoundError()
except requests.exceptions.LocationParseError as e:
# not an valid url, just skip
self.dataset.log("Error: LocationParseError while trying to download image %s: %s" % (url, e))
raise FileNotFoundError()
except requests.exceptions.InvalidSchema:
# not an http url, just skip
raise FileNotFoundError()
Expand Down

0 comments on commit 579ff64

Please sign in to comment.