Tweak/fix the lookup

This commit is contained in:
Thomas Sileo 2018-07-26 22:39:12 +02:00
parent 8402bfbed2
commit ffc2700c4f

View file

@ -15,6 +15,10 @@ def lookup(url: str) -> ap.BaseActivity:
return ap.fetch_remote_activity(actor_url) return ap.fetch_remote_activity(actor_url)
except NotAnActivityError: except NotAnActivityError:
pass pass
except requests.HTTPError:
# Some websites may returns 404, 503 or others when they don't support webfinger, and we're just taking a guess
# when performing the lookup.
pass
backend = ap.get_backend() backend = ap.get_backend()
resp = requests.get( resp = requests.get(