Skip to content

General: Tie debug overlay to log recording, drop Debug menu#593

Merged
d4rken merged 1 commit into
mainfrom
refactor/remove-debug-menu
May 7, 2026
Merged

General: Tie debug overlay to log recording, drop Debug menu#593
d4rken merged 1 commit into
mainfrom
refactor/remove-debug-menu

Conversation

@d4rken

@d4rken d4rken commented May 7, 2026

Copy link
Copy Markdown
Member

What changed

The "Debug" entry under Settings → General is gone. Its three toggles (Debug mode, Fake data, Unfiltered BLE data) had become redundant — debug logs are still captured via Settings → Support → Record debug log.

When you start recording a debug log, device cards on the Overview screen now show the same raw payload data that the old "Debug mode" toggle used to surface. Anyone helping with support for a new headphone type can capture the relevant info just by sharing a debug recording — no hidden toggle to flip first.

Technical Context

  • isDebugModeEnabled and showFakeData had no writers outside the deleted UI, so both flags and the code they gated (FakeBleData, the BleScanner.map injection point) are removed. The DataStore keys are left orphan — no migration needed, DataStore tolerates them.
  • DebugSettings.showUnfiltered is replaced by an ephemeral unfilteredOverride MutableStateFlow on BlePodMonitor. TroubleShooterViewModel toggles it via setUnfilteredOverride(...), wrapped in try/finally so cancellation, exception, or back-press always resets it. Process restart auto-resets too. This closes a latent bug: any existing user who'd manually flipped that toggle on would have had it stuck-on after the menu disappeared, with no recovery path and noisier scans.
  • New global Bugs.isDebug: MutableStateFlow<Boolean> mirrored from RecorderModule.state.isRecording. OverviewViewModel observes this instead of the deleted DebugSettings.isDebugModeEnabled flag, so the device-card raw-payload overlay flips on with the recorder and off when it stops.
  • Orphan strings (settings_debug_*, settings_fake_data_*, settings_blescanner_unfiltered_*) cleared from values/strings.xml and all 75 values-*/strings.xml files — keeps Android lint's ExtraTranslation check happy without waiting for the next Crowdin sync.

@d4rken d4rken merged commit 4d3a9bc into main May 7, 2026
11 checks passed
@d4rken d4rken deleted the refactor/remove-debug-menu branch May 7, 2026 13:42
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.

1 participant