kopia lustrzana https://github.com/bellingcat/auto-archiver
rodzic
98fb574d89
commit
128d4136e3
|
@ -40,11 +40,12 @@ class AAApiDb(Database):
|
||||||
response = requests.get(os.path.join(self.api_endpoint, "tasks/search-url"), params=params, headers=headers)
|
response = requests.get(os.path.join(self.api_endpoint, "tasks/search-url"), params=params, headers=headers)
|
||||||
|
|
||||||
if response.status_code == 200:
|
if response.status_code == 200:
|
||||||
logger.success(f"API returned a previously archived instance: {response.json()}")
|
if len(response.json()):
|
||||||
# TODO: can we do better than just returning the most recent result?
|
logger.success(f"API returned a previously archived instance: {response.json()}")
|
||||||
return Metadata.from_dict(response.json()[0]["result"])
|
# TODO: can we do better than just returning the most recent result?
|
||||||
|
return Metadata.from_dict(response.json()[0]["result"])
|
||||||
logger.error(f"AA API FAIL ({response.status_code}): {response.json()}")
|
else:
|
||||||
|
logger.error(f"AA API FAIL ({response.status_code}): {response.json()}")
|
||||||
return False
|
return False
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@ _MAJOR = "0"
|
||||||
_MINOR = "7"
|
_MINOR = "7"
|
||||||
# On main and in a nightly release the patch should be one ahead of the last
|
# On main and in a nightly release the patch should be one ahead of the last
|
||||||
# released build.
|
# released build.
|
||||||
_PATCH = "3"
|
_PATCH = "4"
|
||||||
# This is mainly for nightly builds which have the suffix ".dev$DATE". See
|
# This is mainly for nightly builds which have the suffix ".dev$DATE". See
|
||||||
# https://semver.org/#is-v123-a-semantic-version for the semantics.
|
# https://semver.org/#is-v123-a-semantic-version for the semantics.
|
||||||
_SUFFIX = ""
|
_SUFFIX = ""
|
||||||
|
|
Ładowanie…
Reference in New Issue