:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
chore(demo): grant onboarding wizard scopes to demo oauth app (#62270)
Fernando Gomes6fe6e38334b0
diff --git a/posthog/demo/products/hedgebox/matrix.py b/posthog/demo/products/hedgebox/matrix.pyindex 51b2aa1703d6..87641376b5dd 100644--- a/posthog/demo/products/hedgebox/matrix.py+++ b/posthog/demo/products/hedgebox/matrix.py@@ -52,6 +52,7 @@ from posthog.demo.matrix.randomization import Industryfrom posthog.exceptions_capture import capture_exceptionfrom posthog.models.event.util import create_eventfrom posthog.models.oauth import OAuthApplication+from posthog.scopes import UNPRIVILEGED_SCOPESfrom posthog.storage import object_storagefrom products.actions.backend.models.action import Action@@ -1789,6 +1790,14 @@ class HedgeboxMatrix(Matrix):authorization_grant_type=OAuthApplication.GRANT_AUTHORIZATION_CODE,algorithm="RS256",is_first_party=True,+ # An empty ceiling resolves to UNPRIVILEGED_SCOPES at /authorize, which+ # excludes the privileged/hidden scopes the onboarding wizard requests+ # (llm_gateway:read, wizard_session:*) — so it failed with invalid_scope.+ # Reproduce the broad default and add those so the wizard works locally.+ scopes=sorted(+ UNPRIVILEGED_SCOPES+ | {"llm_gateway:read", "llm_gateway:write", "wizard_session:read", "wizard_session:write"}+ ),)except (IntegrityError, ValidationError):pass