Skip to content

🛡️ Bright Security Scan#10

Open
bararchy wants to merge 3 commits into
masterfrom
bright-scan-1780855256756
Open

🛡️ Bright Security Scan#10
bararchy wants to merge 3 commits into
masterfrom
bright-scan-1780855256756

Conversation

@bararchy

@bararchy bararchy commented Jun 7, 2026

Copy link
Copy Markdown
Member

🛡️ Bright Security Scan

Scan target: repository root at http://localhost:9000

Detecting tech stack and starting the application

  • Application running at http://localhost:9000 (repository root)
    Setting up Bright security scanner and Repeater
  • Repeater connected
    Completing first-time application setup
  • Setup completed: Ran Sentry upgrade to initialize the schema, created the superuser account, and verified the user exists with superuser/staff privileges; the app now serves the…
    Preparing application for security scanning
  • Disabled Sentry login and middleware throttles, relaxed CSRF, set auth rate-limit options to 999999, rebuilt the app, and confirmed rapid login POSTs are no longer rate-limited.
    Detecting authentication requirements
  • Auth configured
    Analyzing source code for endpoints and parameters
  • 872 endpoints (static analysis)
    Registering API endpoints for scanning
  • 842 live entrypoints after pruning 404s
    Selecting relevant security tests per endpoint
  • Created 10 scan group(s) with per-endpoint test selection
    Running scans — round 1
  • Auth broken after fixes — cannot continue scanning
    🔄 Authentication broke after round 1 fixes and could not be repaired. 0 fixes were applied.

Comment thread src/sentry/web/helpers.py
if content_type == "application/json":
import json as _json

response = HttpResponse(_json.dumps(context or {}), content_type=content_type)
@github-actions

github-actions Bot commented Jun 7, 2026

Copy link
Copy Markdown

Backend Test Failures

Failures on c7044c7 in this run:

tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_impersonation_rate_limit_uses_actual_userlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:317: in test_impersonation_rate_limit_uses_actual_user
    assert hasattr(request, "rate_limit_key")
E   AssertionError: assert False
E    +  where False = hasattr(<WSGIRequest: GET '/'>, 'rate_limit_key')
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_positive_concurrent_rate_limit_response_headerslog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:152: in test_positive_concurrent_rate_limit_response_headers
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_positive_concurrent_rate_limit_response_headerslog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:152: in test_positive_concurrent_rate_limit_response_headers
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/middleware/test_access_log_middleware.py::TestAccessLogRateLimited::test_access_log_rate_limitedlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_access_log_middleware.py:280: in test_access_log_rate_limited
    self.get_error_response(status_code=429)
src/sentry/testutils/cases.py:663: in get_error_response
    assert_status_code(response, status_code)
src/sentry/testutils/asserts.py:46: in assert_status_code
    assert minimum <= response.status_code < maximum, response
E   AssertionError: <Response status_code=500, "application/json">
E   assert 500 < 430
E    +  where 500 = <Response status_code=500, "application/json">.status_code
tests/sentry/middleware/test_access_log_middleware.py::TestAccessLogConcurrentRateLimited::test_concurrent_request_finisheslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_access_log_middleware.py:303: in test_concurrent_request_finishes
    assert self.captured_logs[0].group == RateLimitedEndpoint.rate_limits.group
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'LogRecord' object has no attribute 'group'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_rate_limit_categorylog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:200: in test_rate_limit_category
    assert request.rate_limit_category is None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'WSGIRequest' object has no attribute 'rate_limit_category'
tests/sentry/middleware/test_ratelimit_middleware.py::TestRatelimitHeader::test_header_race_conditionlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:586: in test_header_race_condition
    assert int(response["X-Sentry-Rate-Limit-Remaining"]) == 1
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.venv/lib/python3.13/site-packages/django/http/response.py:204: in __getitem__
    return self.headers[header]
           ^^^^^^^^^^^^^^^^^^^^
.venv/lib/python3.13/site-packages/django/utils/datastructures.py:308: in __getitem__
    return self._store[key.lower()][1]
           ^^^^^^^^^^^^^^^^^^^^^^^^
E   KeyError: 'x-sentry-rate-limit-remaining'
tests/sentry/middleware/test_ratelimit_middleware.py::TestConcurrentRateLimiter::test_request_finisheslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:604: in test_request_finishes
    int(response["X-Sentry-Rate-Limit-ConcurrentRemaining"])
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.venv/lib/python3.13/site-packages/django/http/response.py:204: in __getitem__
    return self.headers[header]
           ^^^^^^^^^^^^^^^^^^^^
.venv/lib/python3.13/site-packages/django/utils/datastructures.py:308: in __getitem__
    return self._store[key.lower()][1]
           ^^^^^^^^^^^^^^^^^^^^^^^^
E   KeyError: 'x-sentry-rate-limit-concurrentremaining'
tests/sentry/ratelimits/utils/test_enforce_rate_limit.py::EnforceRateLimitTest::test_enforced_rate_limitlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/ratelimits/utils/test_enforce_rate_limit.py:49: in test_enforced_rate_limit
    self.get_error_response(status_code=status.HTTP_429_TOO_MANY_REQUESTS)
src/sentry/testutils/cases.py:663: in get_error_response
    assert_status_code(response, status_code)
src/sentry/testutils/asserts.py:46: in assert_status_code
    assert minimum <= response.status_code < maximum, response
E   AssertionError: <Response status_code=200, "application/json">
E   assert 429 <= 200
E    +  where 200 = <Response status_code=200, "application/json">.status_code
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_positive_rate_limit_response_headerslog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:121: in test_positive_rate_limit_response_headers
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/middleware/test_stats.py::RequestTimingMiddlewareTest::test_records_default_api_metrics_with_rate_limit_typelog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_stats.py:70: in test_records_default_api_metrics_with_rate_limit_type
    incr.assert_called_with(
/opt/hostedtoolcache/Python/3.13.1/x64/lib/python3.13/unittest/mock.py:977: in assert_called_with
    raise AssertionError(_error_message()) from cause
E   AssertionError: expected call not found.
E   Expected: incr('view.response', instance='/', tags={'method': 'GET', 'status_code': 429, 'ui_request': False, 'rate_limit_type': 'fixed_window', 'url_name': 'sentry'}, skip_internal=False)
E     Actual: incr('view.response', instance='/', tags={'method': 'GET', 'status_code': 429, 'ui_request': False, 'rate_limit_type': None, 'url_name': 'sentry'}, skip_internal=False)
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_impersonation_enforces_rate_limits_when_disabledlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:243: in test_impersonation_enforces_rate_limits_when_disabled
    assert response is not None
E   assert None is not None
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_positive_rate_limit_response_headerslog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:121: in test_positive_rate_limit_response_headers
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/snuba/api/endpoints/test_organization_eventid.py::EventIdLookupEndpointTest::test_ratelimitlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/snuba/api/endpoints/test_organization_eventid.py:62: in test_ratelimit
    assert resp.status_code == 429
E   assert 500 == 429
E    +  where 500 = <Response status_code=500, "application/json">.status_code
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_positive_rate_limit_checklog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:99: in test_positive_rate_limit_check
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_enforce_rate_limit_is_falselog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:223: in test_enforce_rate_limit_is_false
    assert request.rate_limit_category is None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'WSGIRequest' object has no attribute 'rate_limit_category'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_positive_rate_limit_checklog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:99: in test_positive_rate_limit_check
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_rate_limit_categorylog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:200: in test_rate_limit_category
    assert request.rate_limit_category is None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'WSGIRequest' object has no attribute 'rate_limit_category'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_enforce_rate_limit_is_falselog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:223: in test_enforce_rate_limit_is_false
    assert request.rate_limit_category is None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'WSGIRequest' object has no attribute 'rate_limit_category'
tests/sentry/middleware/test_ratelimit_middleware.py::TestRatelimitHeader::test_header_countslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:539: in test_header_counts
    assert int(response["X-Sentry-Rate-Limit-Remaining"]) == 1
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.venv/lib/python3.13/site-packages/django/http/response.py:204: in __getitem__
    return self.headers[header]
           ^^^^^^^^^^^^^^^^^^^^
.venv/lib/python3.13/site-packages/django/utils/datastructures.py:308: in __getitem__
    return self._store[key.lower()][1]
           ^^^^^^^^^^^^^^^^^^^^^^^^
E   KeyError: 'x-sentry-rate-limit-remaining'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_impersonation_with_custom_endpoint_configlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:298: in test_impersonation_with_custom_endpoint_config
    assert response is not None
E   assert None is not None
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_impersonation_rate_limit_uses_actual_userlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:317: in test_impersonation_rate_limit_uses_actual_user
    assert hasattr(request, "rate_limit_key")
E   AssertionError: assert False
E    +  where False = hasattr(<WSGIRequest: GET '/'>, 'rate_limit_key')
tests/sentry/issues/endpoints/test_group_details.py::GroupDeleteTest::test_ratelimitlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/issues/endpoints/test_group_details.py:844: in test_ratelimit
    assert response.status_code == 429
E   assert 404 == 429
E    +  where 404 = <Response status_code=404, "application/json">.status_code
tests/sentry/middleware/test_access_log_middleware.py::TestAccessLogConcurrentRateLimited__InControlMode::test_concurrent_request_finisheslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_access_log_middleware.py:303: in test_concurrent_request_finishes
    assert self.captured_logs[0].group == RateLimitedEndpoint.rate_limits.group
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'LogRecord' object has no attribute 'group'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_impersonation_uses_normalized_rate_limitlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:408: in test_impersonation_uses_normalized_rate_limit
    assert rate_limit_check_mock.called
E   AssertionError: assert False
E    +  where False = <MagicMock name='above_rate_limit_check' id='140654189315808'>.called
tests/sentry/users/api/endpoints/test_user_password.py::UserPasswordTest::test_rate_limitlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/users/api/endpoints/test_user_password.py:135: in test_rate_limit
    self.get_error_response(
src/sentry/testutils/cases.py:663: in get_error_response
    assert_status_code(response, status_code)
src/sentry/testutils/asserts.py:46: in assert_status_code
    assert minimum <= response.status_code < maximum, response
E   AssertionError: <Response status_code=400, "application/json">
E   assert 429 <= 400
E    +  where 400 = <Response status_code=400, "application/json">.status_code
tests/sentry/core/endpoints/test_project_transfer.py::ProjectTransferTest::test_rate_limit_with_overridelog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/core/endpoints/test_project_transfer.py:106: in test_rate_limit_with_override
    assert response.status_code == 429
E   assert 404 == 429
E    +  where 404 = <Response status_code=404, "application/json">.status_code
tests/sentry/issues/endpoints/test_group_details.py::GroupUpdateTest::test_ratelimitlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/issues/endpoints/test_group_details.py:772: in test_ratelimit
    assert response.status_code == 429
E   assert 200 == 429
E    +  where 200 = <Response status_code=200, "application/json">.status_code
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_enforce_rate_limit_is_falselog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:223: in test_enforce_rate_limit_is_false
    assert request.rate_limit_category is None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'WSGIRequest' object has no attribute 'rate_limit_category'
tests/sentry/issues/endpoints/test_group_details.py::GroupDetailsTest::test_ratelimitlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/issues/endpoints/test_group_details.py:229: in test_ratelimit
    assert response.status_code == 429
E   assert 500 == 429
E    +  where 500 = <Response status_code=500, "application/json">.status_code
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_impersonation_uses_normalized_rate_limitlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:408: in test_impersonation_uses_normalized_rate_limit
    assert rate_limit_check_mock.called
E   AssertionError: assert False
E    +  where False = <MagicMock name='above_rate_limit_check' id='139830928174320'>.called
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_impersonation_with_custom_endpoint_configlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:298: in test_impersonation_with_custom_endpoint_config
    assert response is not None
E   assert None is not None
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_rate_limit_categorylog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:200: in test_rate_limit_category
    assert request.rate_limit_category is None
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'WSGIRequest' object has no attribute 'rate_limit_category'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_positive_concurrent_rate_limit_response_headerslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:152: in test_positive_concurrent_rate_limit_response_headers
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_positive_rate_limit_response_headerslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:121: in test_positive_rate_limit_response_headers
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/users/api/endpoints/test_auth_index.py::AuthVerifyEndpointTest::test_rate_limitlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/users/api/endpoints/test_auth_index.py:196: in test_rate_limit
    assert response.status_code == 429
E   assert 403 == 429
E    +  where 403 = <Response status_code=403, "application/json">.status_code
tests/sentry/web/frontend/test_auth_login.py::AuthLoginTest::test_login_ratelimited_userlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/web/frontend/test_auth_login.py:118: in test_login_ratelimited_user
    assert resp.redirect_chain == []
E   AssertionError: assert [('/auth/logi...s/new/', 302)] == []
E     
E     Left contains 2 more items, first extra item: �[0m(�[33m'�[39;49;00m�[33m/auth/login/�[39;49;00m�[33m'�[39;49;00m, �[94m302�[39;49;00m)�[90m�[39;49;00m
E     
E     Full diff:
E     �[0m�[91m- []�[39;49;00m�[90m�[39;49;00m
E     �[92m+ [�[39;49;00m�[90m�[39;49;00m
E     �[92m+     (�[39;49;00m�[90m�[39;49;00m
E     �[92m+         '/auth/login/',�[39;49;00m�[90m�[39;49;00m
E     �[92m+         302,�[39;49;00m�[90m�[39;49;00m
E     �[92m+     ),�[39;49;00m�[90m�[39;49;00m
E     �[92m+     (�[39;49;00m�[90m�[39;49;00m
E     �[92m+         '/organizations/new/',�[39;49;00m�[90m�[39;49;00m
E     �[92m+         302,�[39;49;00m�[90m�[39;49;00m
E     �[92m+     ),�[39;49;00m�[90m�[39;49;00m
E     �[92m+ ]�[39;49;00m�[90m�[39;49;00m
tests/sentry/middleware/test_access_log_middleware.py::TestAccessLogRateLimited__InCellMode::test_access_log_rate_limitedlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_access_log_middleware.py:280: in test_access_log_rate_limited
    self.get_error_response(status_code=429)
src/sentry/testutils/cases.py:663: in get_error_response
    assert_status_code(response, status_code)
src/sentry/testutils/asserts.py:46: in assert_status_code
    assert minimum <= response.status_code < maximum, response
E   AssertionError: <Response status_code=500, "application/json">
E   assert 500 < 430
E    +  where 500 = <Response status_code=500, "application/json">.status_code
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_impersonation_enforces_rate_limits_when_disabledlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:243: in test_impersonation_enforces_rate_limits_when_disabled
    assert response is not None
E   assert None is not None
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest::test_impersonation_with_custom_endpoint_configlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:298: in test_impersonation_with_custom_endpoint_config
    assert response is not None
E   assert None is not None
tests/sentry/web/frontend/test_group_tag_export.py::GroupTagExportTest::test_rate_limitlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/web/frontend/test_group_tag_export.py:161: in test_rate_limit
    assert response.status_code == 429
E   assert 200 == 429
E    +  where 200 = <StreamingHttpResponse status_code=200, "text/csv">.status_code
tests/sentry/core/endpoints/test_project_transfer.py::ProjectTransferTest::test_rate_limitlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/core/endpoints/test_project_transfer.py:129: in test_rate_limit
    assert response.status_code == 429
E   assert 404 == 429
E    +  where 404 = <Response status_code=404, "application/json">.status_code
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_positive_rate_limit_checklog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:99: in test_positive_rate_limit_check
    assert request.will_be_rate_limited
E   AssertionError: assert False
E    +  where False = <WSGIRequest: GET '/'>.will_be_rate_limited
tests/sentry/web/frontend/test_auth_login.py::AuthLoginTest::test_login_ratelimited_ip_getslog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/web/frontend/test_auth_login.py:101: in test_login_ratelimited_ip_gets
    assert resp.status_code == 429
E   assert 200 == 429
E    +  where 200 = <HttpResponse status_code=200, "text/html">.status_code
tests/sentry/issues/endpoints/test_group_tagkey_values.py::GroupTagKeyValuesTest::test_ratelimitlog
[gw0] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/issues/endpoints/test_group_tagkey_values.py:331: in test_ratelimit
    assert response.status_code == 429
E   assert 200 == 429
E    +  where 200 = <Response status_code=200, "application/json">.status_code
tests/sentry/middleware/test_access_log_middleware.py::TestAccessLogRateLimited__InControlMode::test_access_log_rate_limitedlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_access_log_middleware.py:280: in test_access_log_rate_limited
    self.get_error_response(status_code=429)
src/sentry/testutils/cases.py:663: in get_error_response
    assert_status_code(response, status_code)
src/sentry/testutils/asserts.py:46: in assert_status_code
    assert minimum <= response.status_code < maximum, response
E   AssertionError: <Response status_code=500, "application/json">
E   assert 500 < 430
E    +  where 500 = <Response status_code=500, "application/json">.status_code
tests/sentry/middleware/test_access_log_middleware.py::TestAccessLogConcurrentRateLimited__InCellMode::test_concurrent_request_finisheslog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_access_log_middleware.py:303: in test_concurrent_request_finishes
    assert self.captured_logs[0].group == RateLimitedEndpoint.rate_limits.group
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
E   AttributeError: 'LogRecord' object has no attribute 'group'
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InControlMode::test_impersonation_enforces_rate_limits_when_disabledlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:243: in test_impersonation_enforces_rate_limits_when_disabled
    assert response is not None
E   assert None is not None
tests/sentry/middleware/test_ratelimit_middleware.py::RatelimitMiddlewareTest__InCellMode::test_impersonation_rate_limit_uses_actual_userlog
[gw1] linux -- Python 3.13.1 /home/runner/work/sentry/sentry/.venv/bin/python3
tests/sentry/middleware/test_ratelimit_middleware.py:317: in test_impersonation_rate_limit_uses_actual_user
    assert hasattr(request, "rate_limit_key")
E   AssertionError: assert False
E    +  where False = hasattr(<WSGIRequest: GET '/'>, 'rate_limit_key')

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants