mirror of
https://git.sr.ht/~tsileo/microblog.pub
synced 2025-06-05 21:59:23 +02:00
Improve fetch
This commit is contained in:
@ -85,6 +85,8 @@ async def get_lookup(
|
||||
error = ap.FetchErrorTypeEnum.TIMEOUT
|
||||
except (ap.ObjectNotFoundError, ap.ObjectIsGoneError):
|
||||
error = ap.FetchErrorTypeEnum.NOT_FOUND
|
||||
except (ap.ObjectUnavailableError):
|
||||
error = ap.FetchErrorTypeEnum.UNAUHTORIZED
|
||||
except Exception:
|
||||
logger.exception(f"Failed to lookup {query}")
|
||||
error = ap.FetchErrorTypeEnum.INTERNAL_ERROR
|
||||
|
Reference in New Issue
Block a user