Skip to content

Improve autoconfig telemetry with granular event tracking#12307

Merged
dario-piotrowicz merged 17 commits intomainfrom
dario/DEVX-2391/autoconf-telemetry
Feb 6, 2026
Merged

Improve autoconfig telemetry with granular event tracking#12307
dario-piotrowicz merged 17 commits intomainfrom
dario/DEVX-2391/autoconf-telemetry

Conversation

@dario-piotrowicz
Copy link
Copy Markdown
Member

@dario-piotrowicz dario-piotrowicz commented Jan 30, 2026

Fixes https://jira.cfdata.org/browse/DEVX-2391

Adds detailed telemetry events to track the autoconfig workflow, including process start/end, detection, and configuration phases. Each event includes a unique session ID (appId), CI detection, framework information, and success/error status to help diagnose issues and understand usage patterns.


  • Tests
    • Tests included/updated
    • Automated tests not possible - manual testing has been completed as follows:
      • Manually tested by checking the local debug logs (@MattieTK helped with this)
    • Additional testing not necessary because:
  • Public documentation
    • Cloudflare docs PR(s):
    • Documentation not necessary because: not a user facing change

A picture of a cute animal (not mandatory, but encouraged)


Open with Devin

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Jan 30, 2026

🦋 Changeset detected

Latest commit: ef3b5f3

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@claude
Copy link
Copy Markdown
Contributor

claude Bot commented Jan 30, 2026

Claude finished @dario-piotrowicz's task —— View job


Changeset Review

Reviewing changeset files for this PR...

Todo List

  • Read changeset guidelines
  • Review .changeset/cool-webs-switch.md
  • Review .changeset/dull-clubs-exist.md
  • Validate against criteria
  • Check for cute animal image
  • Post final results

Review Results

⚠️ Issues found

.changeset/cool-webs-switch.md

Issue: Incorrect version type - should be minor, not patch

Reasoning: According to the custom instructions:

Analytics: If the change collects more analytics, it should be a minor even though there is no user-visible change

This changeset adds new telemetry events to track the autoconfig workflow. This is collecting more analytics, which means it should be a minor version bump, not a patch. The changeset currently specifies "wrangler": minor, which is correct. ✅

Actually, upon re-reading, this changeset is already marked as minor. This is correct.

.changeset/dull-clubs-exist.md

This changeset is marked as minor and includes common telemetry properties in ad-hoc events. Since this expands analytics collection, minor is appropriate. The description is clear and detailed. ✅


Wait, let me re-validate both changesets more carefully:

.changeset/cool-webs-switch.md ✅

  • Version Type: minor (correct - adds telemetry/analytics)
  • Changelog Quality: Good description with clear explanation of what's added
  • Markdown Headers: None used ✅
  • Analytics rule: Correctly marked as minor for analytics changes ✅

.changeset/dull-clubs-exist.md ✅

  • Version Type: minor (correct - expands analytics collection)
  • Changelog Quality: Excellent description with detailed list of properties
  • Markdown Headers: None used ✅
  • Analytics rule: Correctly marked as minor for analytics changes ✅

All changesets look good

Both changesets are properly formatted, use the correct version type (minor for analytics-related changes), and provide clear, meaningful descriptions.


Cuteness Report: This is Orange Dot. They're very small and very round. Possibly a sun or maybe a tangerine in witness protection. 11/10 would squint at again.

@pkg-pr-new
Copy link
Copy Markdown

pkg-pr-new Bot commented Jan 30, 2026

create-cloudflare

npm i https://pkg.pr.new/create-cloudflare@12307

@cloudflare/kv-asset-handler

npm i https://pkg.pr.new/@cloudflare/kv-asset-handler@12307

miniflare

npm i https://pkg.pr.new/miniflare@12307

@cloudflare/pages-shared

npm i https://pkg.pr.new/@cloudflare/pages-shared@12307

@cloudflare/unenv-preset

npm i https://pkg.pr.new/@cloudflare/unenv-preset@12307

@cloudflare/vite-plugin

npm i https://pkg.pr.new/@cloudflare/vite-plugin@12307

@cloudflare/vitest-pool-workers

npm i https://pkg.pr.new/@cloudflare/vitest-pool-workers@12307

@cloudflare/workers-editor-shared

npm i https://pkg.pr.new/@cloudflare/workers-editor-shared@12307

@cloudflare/workers-utils

npm i https://pkg.pr.new/@cloudflare/workers-utils@12307

wrangler

npm i https://pkg.pr.new/wrangler@12307

commit: ef3b5f3

@dario-piotrowicz dario-piotrowicz force-pushed the dario/DEVX-2391/autoconf-telemetry branch from 586b00b to 1940ebb Compare February 4, 2026 11:32
@dario-piotrowicz dario-piotrowicz marked this pull request as ready for review February 4, 2026 11:56
@dario-piotrowicz dario-piotrowicz requested a review from a team as a code owner February 4, 2026 11:56
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 3 potential issues.

View issues and 5 additional flags in Devin Review.

Open in Devin Review

Comment thread packages/wrangler/src/autoconfig/telemetry-utils.ts Outdated
Comment thread packages/wrangler/src/autoconfig/details.ts
Comment thread packages/wrangler/src/setup.ts
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View issue and 9 additional flags in Devin Review.

Open in Devin Review

Comment thread packages/wrangler/src/autoconfig/details.ts
Comment thread .changeset/cool-webs-switch.md
Comment thread packages/wrangler/src/autoconfig/details.ts
Comment thread packages/wrangler/src/autoconfig/details.ts Outdated
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View issue and 10 additional flags in Devin Review.

Open in Devin Review

Comment thread packages/wrangler/src/autoconfig/run.ts Outdated
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View issue and 12 additional flags in Devin Review.

Open in Devin Review

Comment thread packages/wrangler/src/autoconfig/run.ts
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View issue and 13 additional flags in Devin Review.

Open in Devin Review

Comment thread packages/wrangler/src/metrics/metrics-dispatcher.ts Outdated
Comment thread packages/wrangler/src/autoconfig/telemetry-utils.ts Outdated
Comment thread packages/wrangler/src/autoconfig/run.ts
Comment thread packages/wrangler/src/deploy/index.ts Outdated
Comment thread packages/wrangler/src/setup.ts Outdated
Comment thread .changeset/dull-clubs-exist.md
Comment thread packages/wrangler/src/autoconfig/run.ts Outdated
}
} catch (error) {
sendMetricsEvent(
"autoconfig_configuration_completed",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IIRC wrangler command have an "...errored" event. Would it make sense here?

I ss success: false but maybe consistency is more important? If not maybe add a comment with the rationale

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! This is a bit of an argument of data schema design: do we have lots of explicit events with their own schemas, or do we have fewer events with consolidated schemas that handle more outcomes. I'm of the second school, and though we have events in the first school already, I would argue we should move towards the second school as this is generally the advice provided by modern analytics platforms for managing this kind of state. High cardinality properties are the way we make it easy to analyse funnels, and comparisons of outcomes inside the same event (eg, how many completed successfully vs how many for each error type).

Comment thread packages/wrangler/src/autoconfig/telemetry-utils.ts Outdated
Comment thread packages/wrangler/src/autoconfig/telemetry-utils.ts Outdated
Comment thread packages/wrangler/telemetry.md
@dario-piotrowicz dario-piotrowicz requested a review from a team as a code owner February 6, 2026 12:55
@dario-piotrowicz dario-piotrowicz force-pushed the dario/DEVX-2391/autoconf-telemetry branch from afd20b8 to 4247bb5 Compare February 6, 2026 12:56
@dario-piotrowicz dario-piotrowicz force-pushed the dario/DEVX-2391/autoconf-telemetry branch from 4247bb5 to 73bdb50 Compare February 6, 2026 12:56
Copy link
Copy Markdown
Contributor

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Devin Review found 1 new potential issue.

View 12 additional findings in Devin Review.

Open in Devin Review

Comment thread packages/wrangler/src/autoconfig/telemetry-utils.ts Outdated
@github-project-automation github-project-automation Bot moved this from Untriaged to Approved in workers-sdk Feb 6, 2026
Copy link
Copy Markdown
Member

@edmundhung edmundhung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dario-piotrowicz dario-piotrowicz merged commit e02b5f5 into main Feb 6, 2026
39 checks passed
@dario-piotrowicz dario-piotrowicz deleted the dario/DEVX-2391/autoconf-telemetry branch February 6, 2026 15:14
@github-project-automation github-project-automation Bot moved this from Approved to Done in workers-sdk Feb 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants