Skip to content

docs(flutter): document Android flavor workaround for split-debug-info#17268

Open
denrase wants to merge 4 commits intomasterfrom
denrase/dart-plugin-android-flavor-workaround
Open

docs(flutter): document Android flavor workaround for split-debug-info#17268
denrase wants to merge 4 commits intomasterfrom
denrase/dart-plugin-android-flavor-workaround

Conversation

@denrase
Copy link
Copy Markdown
Collaborator

@denrase denrase commented Apr 7, 2026

DESCRIBE YOUR PR

Add a troubleshooting entry for Flutter flavor builds that can overwrite the selected flavor’s Dart symbol files and break Android symbolication.

Relates to getsentry/sentry-dart-plugin#379

IS YOUR CHANGE URGENT?

Help us prioritize incoming PRs by letting us know when the change needs to go live.

  • Urgent deadline (GA date, etc.):
  • Other deadline:
  • None: Not urgent, can wait up to 1 week+

PRE-MERGE CHECKLIST

Make sure you've checked the following before merging your changes:

  • Checked Vercel preview for correctness, including links
  • PR was reviewed and approved by any necessary SMEs (subject matter experts)
  • PR was reviewed and approved by a member of the Sentry docs team

EXTRA RESOURCES

Sentry Dart Plugin Issue

Add a troubleshooting entry for Flutter flavor builds that can overwrite the selected flavor’s Dart symbol files and break Android symbolication.
@vercel
Copy link
Copy Markdown

vercel bot commented Apr 7, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
develop-docs Ready Ready Preview, Comment Apr 7, 2026 2:58pm
sentry-docs Ready Ready Preview, Comment Apr 7, 2026 2:58pm

Request Review

@codeowner-assignment codeowner-assignment bot requested a review from a team April 7, 2026 14:46
@denrase denrase requested a review from buenaflor April 7, 2026 14:48
--target=lib/main_googlePlay.dart \
--obfuscate \
--split-debug-info=debug_info/googlePlay \
--android-project-arg=active-flavor=googlePlay
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Bug: The suggested workaround may fail silently. If the --android-project-arg flag doesn't set the Gradle property as expected, the variantFilter logic is bypassed, and no build variants are filtered.
Severity: MEDIUM

Suggested Fix

Verify that --android-project-arg correctly passes the property to the variantFilter block. Add a log statement or error handling to the Kotlin script to warn the user if the active-flavor property is not found. Update the documentation with steps for the user to confirm the workaround is active.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: docs/platforms/dart/guides/flutter/troubleshooting.mdx#L153

Potential issue: The documentation suggests a workaround using the
`--android-project-arg=active-flavor=googlePlay` flag to filter Android build variants.
The corresponding Kotlin code retrieves this value using
`project.findProperty("active-flavor")`. If the flag fails to set the Gradle property,
`findProperty` returns `null`, causing the logic to exit silently (`?:
return@variantFilter`). This bypasses the intended variant filtering, leading to a
silent failure where users believe the workaround is active, but it provides no
protection against the original issue of overwritten `.symbols` files.

Did we get this right? 👍 / 👎 to inform future reviews.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants