Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .github/workflows/backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -195,8 +195,12 @@ jobs:
mode: migrations

- name: Run test
run: |
make test-cli
env:
# This short circuits the create_default_projects post_upgrade hook
# which spawns taskworkers which will spin for 5 minutes on kafka
# not being up. We don't need the default project here as this is not local dev.
SENTRY_NO_CREATE_DEFAULT_PROJECT: 1
run: make test-cli

- name: Inspect failure
if: failure()
Expand Down
10 changes: 10 additions & 0 deletions src/sentry/receivers/core.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import os

from click import echo
from django.conf import settings
from django.contrib.auth.models import AnonymousUser
Expand Down Expand Up @@ -32,6 +34,14 @@ def create_default_projects(**kwds):
# No op in production SaaS environments.
return

# Temporary patch to stop getsentry migrations-drift ci from timing out
# because something in create_default_project triggers taskworkers which
# spin for 5m waiting for kafka which isn't up.
# (Only postgres+redis is needed for running migrations.)
# We still want post_save hooks to run, just not in this specific case.
if os.environ.get("SENTRY_NO_CREATE_DEFAULT_PROJECT") == "1":
return

create_default_project(
# This guards against sentry installs that have SENTRY_PROJECT set to None, so
# that they don't error after every migration. Specifically for single tenant.
Expand Down
Loading