Repository navigation
Report PyDABs deploy telemetry per resource type - #6890
Open
Sankalp-Mittal wants to merge 10 commits into
Open
Sankalp-Mittal wants to merge 10 commits into
Sankalp-Mittal wants to merge 10 commits into
Conversation
Add a top-level `pydabs` section to the bundle deploy event with loader and mutator counts plus per-resource-type added/updated counts, covering only resources defined or modified in Python. The experimental.python_* fields are still populated and marked deprecated. Also fix loader and mutator counts being reported as 0 for bundles using the top-level `python` section; only `experimental/python` was read. Co-authored-by: Isaac <no-reply@databricks.com>
Add pydabs.config_section (PYTHON, EXPERIMENTAL_PYTHON, BOTH), recorded before the Python mutator copies 'python' into 'experimental/python'. Read loader and mutator counts from 'experimental/python' only, as before: that copy means it already covers the 'python' section. Co-authored-by: Isaac <no-reply@databricks.com>
Collaborator
Integration test reportCommit: 35c13f8
Top 3 slowest tests (at least 2 minutes):
|
acceptance/bundle/python/telemetry{,-experimental} assert per-type counts and
config_section for both sections, and acceptance/bundle/telemetry/deploy
asserts the pydabs section is omitted without Python.
Co-authored-by: Isaac <no-reply@databricks.com>
Sankalp-Mittal
marked this pull request as ready for review
October 20, 2026 13:02
Sankalp-Mittal
requested review from
janniklasrose,
maksim-zuev-db and
rugpanov
and removed request for
janniklasrose,
maksim-zuev-db and
rugpanov
October 20, 2026 13:02
Group the deprecation under one comment, as for the Resource*Count fields, and mark the remaining use with nolint while both are populated. Co-authored-by: Isaac <no-reply@databricks.com>
Deploy once with 'python' and once with 'experimental/python' in the same test instead of two near-identical directories, and run only the current databricks-bundles version: the telemetry doesn't depend on it. Co-authored-by: Isaac <no-reply@databricks.com>
Contributor
|
Commit: Regression test reportSelected 1 changed tests (limit=20, 0 not selected) 1 tests: regression=1 unreleased=0 coverage=0 failing=0
TestAccept/bundle/python/telemetry/DMS=/PYDAB_VERSION=current: branch ✅ | main (edebd84) ❌ | latest (v1.22.1) ❌main (edebd84): latest (v1.22.1): same output as main (edebd84) |
| PydabsConfigSectionUnspecified PydabsConfigSection = "TYPE_UNSPECIFIED" | ||
| PydabsConfigSectionPython PydabsConfigSection = "PYTHON" | ||
| PydabsConfigSectionExperimentalPython PydabsConfigSection = "EXPERIMENTAL_PYTHON" | ||
| PydabsConfigSectionBoth PydabsConfigSection = "BOTH" |
Member
There was a problem hiding this comment.
what's the purpose of BOTH, can't this be consolidated as a union of the other two?
Contributor
Author
There was a problem hiding this comment.
this is an enum and not bool so union doesn't work over here, while I could change it to a bool that would need a proto change and I don't think there is any major advantage to doing that over just having an enum
Fill one entry per type from the added and updated maps and sort once, instead of concatenating, sorting and compacting the key lists. Co-authored-by: Isaac <no-reply@databricks.com>
andrewnester
approved these changes
Oct 23, 2026
The direct engine is now the only engine, and the acceptance harness rejects EnvMatrix.DATABRICKS_BUNDLE_ENGINE. Co-authored-by: Isaac <no-reply@databricks.com>
The pydabs section carries the same counts. Consumers read pydabs for new CLIs and fall back to experimental.python_* for older ones. Co-authored-by: Isaac <no-reply@databricks.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
pydabssection to the bundle deploy telemetry event (BundleDeployPydabs) with:resource_loaders_count,resource_mutators_countadded_resources_count,updated_resources_countresources: one entry per resource type added or updated by Python (resource_type,added_count,updated_count), sorted by type.config_section: where the user declared Python support:PYTHON,EXPERIMENTAL_PYTHON, orBOTH.bundle.Metrics.PythonAddedResources/PythonUpdatedResources) instead of two totals.config_sectionis recorded at the start of theload_resourcesphase, beforeapplyBackwardsCompatibilityFixescopiespythonintoexperimental.python. After that copy the two sections can't be told apart.experimental.python_*is no longer sent:pydabscarries the same counts. Readers usepydabsfor new CLIs and fall back toexperimental.python_*for older ones.Why
The only per-type resource data in deploy telemetry today is
resources_metadata, which covers the merged YAML + Python config. It can't show which resource types are actually defined or modified in Python. This adds counts limited to those resources.config_sectionshows how many bundles still useexperimental.pythonrather thanpython.updated_countincludes Python-defined resources that a mutator then modifies, so it can overlap withadded_count.This PR is a draft until the telemetry backend schema accepts the new
pydabsfield.Tests
TestPydabsMetrics(a type only updated, never added) andTestPythonConfigSection(none / both); everything else is covered by the acceptance test.acceptance/bundle/python/telemetrydeploys a YAML job and schema, a Python loader adding a job and a pipeline, and a job mutator, once withpython:and once withexperimental.python:. It asserts jobs 1 added / 2 updated, pipelines 1 added / 0 updated, no schemas, 1 loader / 1 mutator, andconfig_sectionPYTHONthenEXPERIMENTAL_PYTHON.go test ./acceptance -run 'TestAccept/bundle/(telemetry|python)'passes.This pull request and its description were written by Isaac.