getsentry / getsentry/sentry

Flaky test: tests/sentry/api/bases/test_organization.py::GetProjectIdsTest::test_get_projects_by_slugs_all

Open
#108,954 1 comment 0 reactions 0 assignees View on GitHub
flaky-test Tests
Dominant language
Python
Stars
44.8k
Forks
4.9k
Avg merge
21h 10m
Merged PRs (30d)
635

Description

Failing test: `tests/sentry/api/bases/test_organization.py::GetProjectIdsTest::test_get_projects_by_slugs_all`
Sentry sha: 79bb9f2a1cdd9bbed8a76ffa261ee7328244e04b
Run: https://github.com/getsentry/sentry/actions/runs/22289152642

```
tests/sentry/api/bases/test_organization.py:588: in test_get_projects_by_slugs_all
mock__filter_projects_by_permissions.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: _filter_projects_by_permissions(projects=[, ], request=, filter_by_membership=False, force_global_perms=False, include_all_accessible=True)
E Actual: _filter_projects_by_permissions(projects=[, ], request=, filter_by_membership=False, force_global_perms=False, include_all_accessible=True)
```

Contributor guide

Open the contributing guide

Research direction

Start by running tests/sentry/api/bases/test_organization.py::GetProjectIdsTest::test_get_projects_by_slugs_all and compare the expected and actual _filter_projects_by_permissions calls. Inspect the surrounding test and the implementation it exercises to determine why project ordering differs. Done means the test passes consistently without relying on unstable ordering.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, testing-qa
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.