tests/test.sh exit code (0 → resolved); the classification below is post-hoc and cannot change it.No file changes, the agent left the workspace untouched.
downloading uv 0.9.7 aarch64-unknown-linux-gnu
Downloading pygments (1.2MiB)
Downloading botocore (12.7MiB)
Downloading pygments
Downloading botocore
Installed 13 packages in 42ms
============================= test session starts ==============================
platform linux -- Python 3.12.3, pytest-8.4.1, pluggy-1.6.0 -- /root/.cache/uv/archive-v0/Qz9caJbW1DnA7Ip_aL2i4/bin/python
cachedir: .pytest_cache
rootdir: /tests
plugins: json-ctrf-0.3.5
collecting ... collected 60 items
../tests/test_outputs.py::test_01_token_endpoint_returns_access_token FAILED [ 1%]
../tests/test_outputs.py::test_02_token_endpoint_rejects_bad_secret PASSED [ 3%]
../tests/test_outputs.py::test_03_token_endpoint_no_token_when_grant_type_missing PASSED [ 5%]
../tests/test_outputs.py::test_04_get_reports_with_valid_token_is_200 FAILED [ 6%]
../tests/test_outputs.py::test_05_post_reports_with_valid_token_is_200 FAILED [ 8%]
../tests/test_outputs.py::test_06_get_reports_returns_ok_true_in_body FAILED [ 10%]
../tests/test_outputs.py::test_07_post_reports_returns_ok_true_in_body FAILED [ 11%]
../tests/test_outputs.py::test_08_get_reports_without_authorization_is_401 PASSED [ 13%]
../tests/test_outputs.py::test_09_post_reports_without_authorization_is_401 PASSED [ 15%]
../tests/test_outputs.py::test_10_get_reports_with_malformed_bearer_is_401 PASSED [ 16%]
../tests/test_outputs.py::test_11_get_reports_with_wrong_scope_only_is_403 FAILED [ 18%]
../tests/test_outputs.py::test_12_post_reports_with_wrong_scope_only_is_403 FAILED [ 20%]
../tests/test_outputs.py::test_13_get_reports_body_reflects_method_and_route FAILED [ 21%]
../tests/test_outputs.py::test_14_post_reports_body_reflects_method_and_route FAILED [ 23%]
../tests/test_outputs.py::test_15_access_token_is_a_three_segment_jwt FAILED [ 25%]
../tests/test_outputs.py::test_16_token_payload_has_client_id_claim FAILED [ 26%]
../tests/test_outputs.py::test_17_token_payload_has_scope_claim_with_both_scopes FAILED [ 28%]
../tests/test_outputs.py::test_18_token_payload_issuer_matches_user_pool FAILED [ 30%]
../tests/test_outputs.py::test_19_token_payload_token_use_is_access FAILED [ 31%]
../tests/test_outputs.py::test_20_read_only_token_scope_excludes_write FAILED [ 33%]
../tests/test_outputs.py::test_21_write_only_token_scope_excludes_read FAILED [ 35%]
../tests/test_outputs.py::test_22_token_expiry_is_in_the_future FAILED [ 36%]
../tests/test_outputs.py::test_23_http_api_protocol_type_is_http PASSED [ 38%]
../tests/test_outputs.py::test_24_jwt_authorizer_type_is_jwt PASSED [ 40%]
../tests/test_outputs.py::test_25_jwt_authorizer_audience_contains_app_client_id FAILED [ 41%]
../tests/test_outputs.py::test_26_jwt_authorizer_issuer_matches_user_pool PASSED [ 43%]
../tests/test_outputs.py::test_27_jwt_authorizer_identity_source_is_authorization_header FAILED [ 45%]
../tests/test_outputs.py::test_28_route_get_reports_authorization_type_is_jwt PASSED [ 46%]
../tests/test_outputs.py::test_29_route_post_reports_authorization_type_is_jwt PASSED [ 48%]
../tests/test_outputs.py::test_30_route_get_reports_scopes_are_namespaced_read FAILED [ 50%]
../tests/test_outputs.py::test_31_route_post_reports_scopes_are_namespaced_write FAILED [ 51%]
../tests/test_outputs.py::test_32_route_get_reports_uses_the_authorizer PASSED [ 53%]
../tests/test_outputs.py::test_33_route_post_reports_uses_the_authorizer PASSED [ 55%]
../tests/test_outputs.py::test_34_lambda_integration_payload_format_is_two_dot_zero FAILED [ 56%]
../tests/test_outputs.py::test_35_lambda_integration_type_is_aws_proxy PASSED [ 58%]
../tests/test_outputs.py::test_36_lambda_integration_uri_targets_backend_function PASSED [ 60%]
../tests/test_outputs.py::test_37_stage_auto_deploy_is_true FAILED [ 61%]
../tests/test_outputs.py::test_38_stage_has_a_deployment PASSED [ 63%]
../tests/test_outputs.py::test_39_stage_name_is_prod PASSED [ 65%]
../tests/test_outputs.py::test_40_user_pool_exists_with_expected_name PASSED [ 66%]
../tests/test_outputs.py::test_41_resource_server_exists_with_two_scopes PASSED [ 68%]
../tests/test_outputs.py::test_42_app_client_allowed_oauth_flow_is_client_credentials FAILED [ 70%]
../tests/test_outputs.py::test_43_app_client_oauth_flows_user_pool_client_is_true PASSED [ 71%]
../tests/test_outputs.py::test_44_app_client_has_a_client_secret FAILED [ 73%]
../tests/test_outputs.py::test_45_app_client_allowed_oauth_scopes_includes_both_namespaced FAILED [ 75%]
../tests/test_outputs.py::test_46_app_client_supports_cognito_identity_provider PASSED [ 76%]
../tests/test_outputs.py::test_47_app_client_does_not_use_implicit_flow_alone FAILED [ 78%]
../tests/test_outputs.py::test_48_backend_lambda_exists_and_active PASSED [ 80%]
../tests/test_outputs.py::test_49_backend_lambda_runtime_is_python3 PASSED [ 81%]
../tests/test_outputs.py::test_50_backend_lambda_role_can_write_logs FAILED [ 83%]
../tests/test_outputs.py::test_51_apigateway_can_invoke_backend_lambda PASSED [ 85%]
../tests/test_outputs.py::test_52_log_group_exists PASSED [ 86%]
../tests/test_outputs.py::test_53_ssm_manifest_keys_present PASSED [ 88%]
../tests/test_outputs.py::test_54_ssm_api_id_resolves_to_real_api PASSED [ 90%]
../tests/test_outputs.py::test_55_ssm_user_pool_id_resolves_to_real_pool PASSED [ 91%]
../tests/test_outputs.py::test_56_ssm_authorizer_id_resolves_to_real_authorizer PASSED [ 93%]
../tests/test_outputs.py::test_57_ssm_oauth_token_endpoint_is_well_formed PASSED [ 95%]
../tests/test_outputs.py::test_58_backend_lambda_reserved_concurrency_does_not_block_invocations FAILED [ 96%]
../tests/test_outputs.py::test_59_backend_lambda_direct_invoke_returns_a_successful_response FAILED [ 98%]
../tests/test_outputs.py::test_60_backend_lambda_role_grants_log_stream_writes FAILED [100%]
=================================== FAILURES ===================================
_________________ test_01_token_endpoint_returns_access_token __________________
def test_01_token_endpoint_returns_access_token():
code, body = _post_token(scope="harbor-api/read harbor-api/write")
if code != 200:
code, body = _post_token(scope="harbor-api/read harbor-api/write", basic=False, body_creds=True)
> assert code == 200, f"POST /oauth2/token -> HTTP {code}, body={body!r} (expected 200)"
E AssertionError: POST /oauth2/token -> HTTP 403, body='error' (expected 200)
E assert 403 == 200
/tests/test_outputs.py:222: AssertionError
_________________ test_04_get_reports_with_valid_token_is_200 __________________
def test_04_get_reports_with_valid_token_is_200():
> tok = _get_token()
^^^^^^^^^^^^
/tests/test_outputs.py:256:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
scope = 'harbor-api/read harbor-api/write'
def _get_token(scope="harbor-api/read harbor-api/write"):
code, body = _post_token(scope=scope, basic=True)
if code == 200 and isinstance(body, dict) and body.get("access_token"):
return body["access_token"]
code2, body2 = _post_token(scope=scope, basic=False, body_creds=True)
if code2 == 200 and isinstance(body2, dict) and body2.get("access_token"):
return body2["access_token"]
> raise AssertionError(f"could not fetch token: basic->{code} {body!r}, body->{code2} {body2!r}")
E AssertionError: could not fetch token: basic->403 'error', body->403 'error'
/tests/test_outputs.py:133: AssertionError
_________________ test_05_post_reports_with_valid_token_is_200 _________________
def test_05_post_reports_with_valid_token_is_200():
> tok = _get_token()
^^^^^^^^^^^^
/tests/test_outputs.py:262:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
scope = 'harbor-api/read harbor-api/write'
def _get_token(scope="harbor-api/read harbor-api/write"):
code, body = _post_token(scope=scope, basic=True)
if code == 200 and isinstance(body, dict) and body.get("access_token"):
return body["access_token"]
code2, body2 = _post_token(scope=scope, basic=False, body_creds=True)
if code2 == 200 and isinstance(body2, dict) and body2.get("access_token"):
return body2["access_token"]
> raise AssertionError(f"could not fetch token: basic->{code} {body!r}, body->{code2} {body2!r}")
E AssertionError: could not fetch token: basic->403 'error', body->403 'error'
/tests/test_outputs.py:133: AssertionError
_________________ test_06_get_reports_returns_ok_true_in_body __________________
def test_06_get_reports_returns_ok_true_in_body():
> tok = _get_token()
^^^^^^^^^^^^
/tests/test_outputs.py:268:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
scope = 'harbor-api/read harbor-api/write'
def _get_token(scope="harbor-api/read harbor-api/write"):
code, body = _post_token(scope=scope, basic=True)
if code == 200 and isinstance(body, dict) and body.get("access_token"):
return body["access_token"]
code2, body2 = _post_token(scope=scope, basic=False, body_creds=True)
if code2 == 200 and isinstance(body2, dict) and body2.get("access_token"):
return body2["access_token"]
> raise AssertionError(f"could not fetch token: basic->{code} {body!r}, body->{code2} {body2!r}")
E AssertionError: could not fetch token: basic->403 'error', body->403 'error'
/tests/test_outputs.py:133: AssertionError
_________________ test_07_post_reports_returns_ok_true_in_body _________________
def test_07_post_reports_returns_ok_true_in_body():
> tok = _get_token()
^^^^^^^^^^^^
/tests/test_outputs.py:279:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
scope = 'harbor-api/read harbor-api/write'
def _get_token(scope="harbor-api/read harbor-api/write"):
code, body = _post_token(scope=scope, basic=True)
if code == 200 and isinstance(body, dict) and body.get("access_token"):
return body["access_token"]
code2, body2 = _post_token(scope=scope, basic=False, body_creds=True)
if code2 == 200 and isinstance(body2, dict) and body2.get("access_token"):
return body2["access_token"]
> raise AssertionError(f"could not fetch token: basic->{code} {body!r}, body->{code2} {body2!r}")
E AssertionError: could not fetch token: basic->403 'error', body->403 'error'
/tests/test_outputs.py:133: AssertionError
_______________ test_11_get_reports_with_wrong_scope_only_is_403 _______________
def test_11_get_reports_with_wrong_scope_only_is_403():
> tok = _get_token(scope="harbor-api/write")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/tests/test_outputs.py:301:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
scope = 'harbor-api/write'
def _get_token(scope="harbor-api/read harbor-api/write"):
code, body = _post_token(scope=scope, basic=True)
if code == 200 and isinstance(body, dict) and body.get("access_token"):
return body["access_token"]
code2, body2 = _post_token(scope=scope, basic=False, body_creds=True)
if code2 == 200 and isinstance(body2, dict) and body2.get("access_token"):
return body2["access_token"]
> raise AssertionError(f"could not fetch token: basic->{code} {body!r}, body->{code2} {body2!r}")
E AssertionError: could not fetch token: basic->403 'error', body->403 'error'
/tests/test_outputs.py:133: AssertionError
______________ test_12_post_reports_with_wrong_scope_only_is_403 _______________
def test_12_post_reports_with_wrong_scope_only_is_403():
> tok = _get_token(scope="harbor-api/read")
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/tests/test_outputs.py:310:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
scope = 'harbor-api/read
… (truncated at 12,000 chars, full verifier log is in the trial artifacts)Reproduce this trial: git checkout 2f94510 && PYTHONPATH=src python3 scripts/build_site.py , then open trial/trial_2f134ffcfd434d52. Re-running the agent live requires EVAL_PLATFORM_ENABLE_OAUTH_SMOKE=1 and is non-deterministic.
Trial trial_2f134ffcfd434d52 · verifier authoritative; classifier explanatory.