lingo: comment is_notifiable() and do not log non-errors (#64460)

This commit is contained in:
Frédéric Péters 2022-04-22 08:44:07 +02:00
parent 48b09b4105
commit 9dba7d1245
1 changed files with 4 additions and 1 deletions

View File

@ -641,7 +641,10 @@ class BasketItem(models.Model):
if not self.source_url:
return True
url = self.source_url + 'jump/trigger/%s' % status
req = requests.get(url, remote_service='auto', timeout=5)
# make a GET request to trigger, it will not actually trigger it (it requires a GET)
# but it will tell us if the trigger doesn't exist (by returning a 404, vs 403 access
# denied).
req = requests.get(url, remote_service='auto', timeout=5, log_errors=False)
if req.status_code == 404:
return False
return True