diff --git a/run.py b/run.py index b6685cb..b84acf8 100755 --- a/run.py +++ b/run.py @@ -139,19 +139,23 @@ def upload_logs_to_ftest(success: bool, logs: str): ( parsed_ftest_host.scheme, parsed_ftest_host.netloc, - "/api/v1/results", + f"/api/v1/{FTEST_AUTH}/results", + "", + "", "", - "" "", ) ) - logger.info("Uploading logs to ftest server {ftest}") + logger.info(f"Uploading logs to ftest server {ftest}") - payload = {"success": success, "logs": logs, "auth": FTEST_AUTH} + payload = {"success": success, "logs": logs} res = requests.post( FTEST_HOST, json=payload, headers={"Origin": "http://example.org"} ) - logger.info("Upload successful") + if res.status_code == 200: + logger.info("Upload successful") + else: + print(res) if __name__ == "__main__":