From 98351114dee53f0cb67c197dc524e9fa19067832 Mon Sep 17 00:00:00 2001 From: Paul D'Ambra Date: Fri, 20 Dec 2024 12:51:50 +0000 Subject: [PATCH 1/2] fix: no django proxy to rust capture --- posthog/settings/web.py | 2 -- posthog/urls.py | 5 +---- requirements-dev.txt | 4 ---- requirements.in | 1 - requirements.txt | 4 ---- 5 files changed, 1 insertion(+), 15 deletions(-) diff --git a/posthog/settings/web.py b/posthog/settings/web.py index 05dd38af055a9..7119ca67f51b5 100644 --- a/posthog/settings/web.py +++ b/posthog/settings/web.py @@ -123,8 +123,6 @@ ] if DEBUG: - # Used on local devenv to reverse-proxy all of /i/* to capture-rs on port 3000 - INSTALLED_APPS.append("revproxy") # rebase_migration command INSTALLED_APPS.append("django_linear_migrations") diff --git a/posthog/urls.py b/posthog/urls.py index 9a1f46757e892..d73c2271ef73f 100644 --- a/posthog/urls.py +++ b/posthog/urls.py @@ -19,7 +19,7 @@ SpectacularRedocView, SpectacularSwaggerView, ) -from revproxy.views import ProxyView + from sentry_sdk import last_event_id from two_factor.urls import urlpatterns as tf_urls @@ -248,9 +248,6 @@ def opt_slash_path(route: str, view: Callable, name: Optional[str] = None) -> UR # what we do. urlpatterns.append(path("_metrics", ExportToDjangoView)) - # Reverse-proxy all of /i/* to capture-rs on port 3000 when running the local devenv - urlpatterns.append(re_path(r"(?P^i/.*)", ProxyView.as_view(upstream="http://localhost:3000"))) - if settings.TEST: # Used in posthog-js e2e tests diff --git a/requirements-dev.txt b/requirements-dev.txt index cc0e410715cd7..d005fd81fb9f7 100644 --- a/requirements-dev.txt +++ b/requirements-dev.txt @@ -167,10 +167,6 @@ googleapis-common-protos==1.60.0 # via # -c requirements.txt # opentelemetry-exporter-otlp-proto-grpc -greenlet==3.1.1 - # via - # -c requirements.txt - # sqlalchemy grpcio==1.63.2 # via # -c requirements.txt diff --git a/requirements.in b/requirements.in index 1c1a0d4db454c..c4564b0f1ecaf 100644 --- a/requirements.in +++ b/requirements.in @@ -30,7 +30,6 @@ django-prometheus==2.2.0 django-redis==5.2.0 django-statsd==2.5.2 django-structlog==2.1.3 -django-revproxy==0.12.0 djangorestframework==3.15.1 djangorestframework-csv==2.1.1 djangorestframework-dataclasses==1.2.0 diff --git a/requirements.txt b/requirements.txt index 02687dd067071..ec758cf47f4ca 100644 --- a/requirements.txt +++ b/requirements.txt @@ -157,7 +157,6 @@ django==4.2.15 # django-phonenumber-field # django-picklefield # django-redis - # django-revproxy # django-structlog # django-two-factor-auth # djangorestframework @@ -192,8 +191,6 @@ django-prometheus==2.2.0 # via -r requirements.in django-redis==5.2.0 # via -r requirements.in -django-revproxy==0.12.0 - # via -r requirements.in django-statsd==2.5.2 # via -r requirements.in django-structlog==2.1.3 @@ -779,7 +776,6 @@ uritemplate==4.1.1 urllib3==1.26.18 # via # botocore - # django-revproxy # geoip2 # google-auth # pdpyras From 1055b956555fcee1ff4f1c03d59bec4340246232 Mon Sep 17 00:00:00 2001 From: Paul D'Ambra Date: Fri, 20 Dec 2024 14:56:12 +0000 Subject: [PATCH 2/2] lazy flyby --- frontend/src/scenes/settings/environment/ReplayTriggers.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/frontend/src/scenes/settings/environment/ReplayTriggers.tsx b/frontend/src/scenes/settings/environment/ReplayTriggers.tsx index 48e79bea18cec..495387c5146ec 100644 --- a/frontend/src/scenes/settings/environment/ReplayTriggers.tsx +++ b/frontend/src/scenes/settings/environment/ReplayTriggers.tsx @@ -202,8 +202,8 @@ function UrlBlocklistOptions(): JSX.Element | null { return (