ATProto.create_report bug fix: include JWT

pull/1238/head
Ryan Barrett 2024-08-05 19:38:52 -07:00
rodzic 978f1f7019
commit 124718ecc7
Nie znaleziono w bazie danych klucza dla tego podpisu
ID klucza GPG: 6BE31FDF4776E9D4
2 zmienionych plików z 9 dodań i 3 usunięć

Wyświetl plik

@ -827,8 +827,10 @@ class ATProto(User, Protocol):
repo_did=repo_did,
privkey=repo.signing_key)
client = Client(f'https://{mod_host}', truncate=True,
headers={'User-Agent': USER_AGENT})
client = Client(f'https://{mod_host}', truncate=True, headers={
'User-Agent': USER_AGENT,
'Authorization': f'Bearer {token}',
})
output = client.com.atproto.moderation.createReport(input)
logger.info(f'Created report on {mod_host}: {json_dumps(output)}')
return True

Wyświetl plik

@ -1735,7 +1735,11 @@ Sed tortor neque, aliquet quis posuere aliquam […]
'uri': uri,
'cid': 'bafy...',
},
}, data=None, headers=ANY)
}, data=None, headers={
'Content-Type': 'application/json',
'User-Agent': common.USER_AGENT,
'Authorization': ANY,
})
def test_datastore_client_get_record_datastore_object(self):
self.make_user_and_repo()