getsentry / self-hosted

Sentry, feature-complete and packaged up for low-volume deployments and proofs-of-concept
https://develop.sentry.dev/self-hosted/
Other
7.74k stars 1.75k forks source link

INP (still) not showing on self hosted #3322

Open amenk opened 5 days ago

amenk commented 5 days ago

Self-Hosted Version

24.8.0

CPU Architecture

x64_64

Docker Version

27.1.2, build d01f264

Docker Compose Version

2.29.1

Steps to Reproduce

Follow up of

https://github.com/getsentry/sentry-javascript/issues/13666 & https://github.com/getsentry/self-hosted/issues/2970

I am hosting the test file from https://github.com/getsentry/sentry-javascript/issues/13666#issuecomment-2345160320 locally via Apache with a DSN set to my self hosted instance.

Request with INP data are showing in the network panel and get a "200 ok", but nothing shows up in sentry

{"sent_at":"2024-09-12T06:41:00.797Z","trace":{"environment":"test x","release":"1726060779","public_key":"edd109a74b1c47129cf2ebe10879e6cb","trace_id":"f60691e4e5114225af15b181b9f1a77d","sample_rate":"1","sampled":"true"}}
{"type":"span"}
{"data":{"sentry.origin":"auto.http.browser.inp","sentry.op":"ui.interaction.click","sentry.source":"custom","release":"1726060779","environment":"test amk","transaction":"/inp.html","user_agent.original":"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/128.0.0.0 Safari/537.36","sentry.exclusive_time":7560,"sentry.sample_rate":1},"description":"body > button#testButton","op":"ui.interaction.click","span_id":"89f2e465eadd8189","start_timestamp":1726123250.505,"timestamp":1726123258.065,"trace_id":"f60691e4e5114225af15b181b9f1a77d","origin":"auto.http.browser.inp","exclusive_time":7560,"measurements":{"inp":{"value":7560,"unit":"millisecond"}},"is_segment":true,"segment_id":"89f2e465eadd8189"}```

sentry.conf.py feature flags:

``` SENTRY_FEATURES["projects:sample-events"] = False SENTRY_FEATURES.update( { feature: True for feature in ( "organizations:discover", "organizations:events", "organizations:global-views", "organizations:incidents", "organizations:integrations-issue-basic", "organizations:integrations-issue-sync", "organizations:invite-members", "organizations:metric-alert-builder-aggregate", "organizations:sso-basic", "organizations:sso-rippling", "organizations:sso-saml2", "organizations:performance-view", "organizations:advanced-search", "organizations:session-replay", "organizations:issue-platform", "organizations:profiling", "organizations:monitors", "organizations:dashboards-mep", "organizations:mep-rollout-flag", "organizations:dashboards-rh-widget", "organizations:metrics-extraction", "organizations:transaction-metrics-extraction", "organizations:performance-vitals-inp", "organizations:insights-entry-points", "organizations:insights-initial-modules", "organizations:insights-addon-modules", "projects:custom-inbound-filters", "projects:data-forwarding", "projects:discard-groups", "projects:plugins", "projects:rate-limits", "projects:servicehooks", ) + ( "projects:span-metrics-extraction", "organizations:starfish-browser-resource-module-image-view", "organizations:starfish-browser-resource-module-ui", "organizations:starfish-browser-webvitals", "organizations:starfish-browser-webvitals-pageoverview-v2", "organizations:starfish-browser-webvitals-use-backend-scores", "organizations:performance-calculate-score-relay", "organizations:starfish-browser-webvitals-replace-fid-with-inp", "organizations:deprecate-fid-from-performance-score", "organizations:performance-database-view", "organizations:starfish-browser-webvitals", "organizations:performance-screens-view", "organizations:starfish-browser-resource-module-ui", "organizations:starfish-browser-webvitals-pageoverview-v2", "organizations:starfish-browser-webvitals-use-backend-scores", "organizations:mobile-ttid-ttfd-contribution", "organizations:starfish-mobile-appstart", ) # starfish related flags } ) ```

Expected Result

INP data is showing.

Actual Result

Image

Event ID

fafed2c4858f46ea8114f133bafa79cb

amenk commented 5 days ago

🤔 Remark: after adding the insights feature flags I just did a docker compose down && docker composer up -d. I had the idea now, that I might need to rerun something else? Maybe some data migrations are missing due to the feature flags being disabled before?

amenk commented 4 days ago

I also added debug: true to my test script as suggested here by @AbhiPrasad

  <script src="https://browser.sentry-cdn.com/8.30.0/bundle.tracing.debug.min.js" crossorigin="anonymous"></script>
...
      Sentry.init({
          dsn: '......',
          release: '1726060779',
          debug: true,

console output is (after clicking the button and switching the tab)

Sentry Logger [log]: [Tracing] Starting sampled root span
  op: ui.interaction.click
  name: body
  ID: a4b35c298293e5c2
logger.js:75 Sentry Logger [log]: [Tracing] Adding an event to span: inp
logger.js:75 Sentry Logger [log]: [Tracing] Finishing "ui.interaction.click" root span "body" with ID a4b35c298293e5c2
logger.js:75 Sentry Logger [log]: Flushing outcomes...
logger.js:75 Sentry Logger [log]: No outcomes to send