refactor(distribution): Separate upload and SDK installation controls#1017
Merged
runningcode merged 4 commits intomainfrom Oct 27, 2025
Merged
refactor(distribution): Separate upload and SDK installation controls#1017runningcode merged 4 commits intomainfrom
runningcode merged 4 commits intomainfrom
Conversation
Refactor the distribution API to provide clearer separation between: - Upload control via `enabled` property - Auto-update SDK installation via `updateSdkVariants` property This replaces the previous `enabledVariants` property which conflated both concerns. Key changes: - Add `enabled: Boolean` property to control distribution uploads (defaults to false during EA) - Rename `enabledVariants` to `updateSdkVariants` to clarify it controls auto-update SDK installation only - Add validation to ensure `updateSdkVariants` doesn't include variants in `ignoredVariants` - Add validation to ensure `updateSdkVariants` requires `enabled=true` - Update upload logic to check `enabled` instead of variant membership - Update tests to reflect new API 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Remove references to Early Access and General Availability from code comments to keep the implementation focused on current behavior. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Apply spotless code formatting to distribution changes. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
Set distribution.enabled convention to match sizeAnalysis.enabled, which uses CI detection (currently evaluates to false). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
13bd0a9 to
1923911
Compare
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.
Summary
Refactor the distribution API to provide clearer separation between upload control and auto-update SDK installation.
Note, this does not move the
enabledproperty outside the ignored variants. So enabled only works for variants that are enabled and therefore have sentry enabled.Key Changes
Added
enabledproperty: Controls whether build distribution uploads are enabledfalseignoredVariantsRenamed
enabledVariantstoupdateSdkVariants: Clarifies this property controls auto-update SDK installation only, not uploadsUpdated upload logic: Now checks
distribution.enabledinstead of variant membership inenabledVariantsAdded build-time validation:
updateSdkVariantscontains variants inignoredVariantsupdateSdkVariantsis set butenabledis falseNew API Example
sentry { ignoredVariants = setOf("debug") sizeAnalysis { enabled = true // Explicit control over size uploads } distribution { enabled = true // Controls build uploads for distribution (only for non-ignored variants) updateSdkVariants = setOf("beta") // Controls auto-update SDK installation } }Migration Guide
Before:
distribution { enabledVariants = ["beta"] }After:
distribution { enabled = true updateSdkVariants = ["beta"] }🤖 Generated with Claude Code