getsentry / getsentry/self-hosted

Switching organization with a project filter from the previous org leaves the Issues page loading indefinitely

Open
#4,512 0 comments 0 reactions 0 assignees View on GitHub
Waiting for: Product Owner
Dominant language
Shell
Stars
9.6k
Forks
2k
Avg merge
1d 5h
Merged PRs (30d)
15

Description

### Self-Hosted Version

26.8.0 (sentry 26.8.0+9f26ea80281e2b0b250a2d9678a2c5cbd22b705c)

### CPU Architecture

aarch64

### Docker Version

25.0.16

### Docker Compose Version

2.32.4

### Machine Specification

- [x] My system meets the minimum system requirements of Sentry

8 vCPU, 30 GB RAM

### Installation Type

Existing install running 26.8.0

### Steps to Reproduce

1. Have one user who is a member of two organizations, `org-a` and `org-b`. Project ID 24 belongs to `org-a`. `org-b` has no project with ID 24 and no `staging` environment.
2. Open Issues in `org-a` and select project 24 and environment `staging`. The URL becomes `/organizations/org-a/issues/?environment=staging&project=24&statsPeriod=24h`.
3. Switch to `org-b` with the organization switcher in the navigation.

### Expected Result

The Issues page for `org-b` loads. The project and environment filters that don't exist in `org-b` are dropped or reset.

### Actual Result

The URL becomes `/organizations/org-b/issues/?environment=staging&project=24&statsPeriod=24h` and the page shows a loading state indefinitely.

Server access logs show that after the switch the frontend requests only:

```
GET /api/0/organizations/org-b/?detailed=0&include_feature_flags=1 200
GET /api/0/organizations/org-b/teams/ 200
GET /api/0/organizations/org-b/projects/?all_projects=1&... 200
```

It makes no further requests. `/api/0/organizations/org-b/issues/` is never called. All three responses return in under 60 ms, the web container logs no errors, and the browser console shows no JavaScript error.

A hard refresh does not help, because the URL still carries `project=24`. Removing `project=` and `environment=` from the URL, or clearing the project filter before switching, avoids the problem.

In the same session, switches made without a project selected (for example from `/issues/?statsPeriod=24h`) load normally and the issues request is made immediately. Three separate switches that carried a foreign project ID all stalled.

### Event ID

_No response_

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the switch from the Issues page in org-a to org-b with a foreign project and environment filter, using the organization switcher entry point described above. Trace why the Issues page remains loading and compare it with a switch without a project filter. Done means the destination organization loads and invalid project and environment filters are dropped or reset.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, docker-compose
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.