-
-
Notifications
You must be signed in to change notification settings - Fork 1k
HOUSEKEEPING: more use of app versus configurator #4738
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
WalkthroughThis PR performs a comprehensive rebranding across the entire codebase, updating all references from "Betaflight Configurator" to "Betaflight App" in configuration files, build scripts, platform-specific assets, localization strings, Android resources/manifests, and source code package declarations. No functional logic changes are introduced. Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~20 minutes
Possibly related PRs
Suggested labels
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (2 warnings)
✅ Passed checks (1 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
capacitor.config.base.json(1 hunks)package.json(1 hunks)
🧰 Additional context used
🧠 Learnings (8)
📚 Learning: 2025-08-27T22:07:26.353Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4579
File: src/js/data_storage.js:9-9
Timestamp: 2025-08-27T22:07:26.353Z
Learning: In the betaflight-configurator CalVer refactoring, the generateVirtualApiVersions function in src/js/utils/common.js works correctly despite the apparent mathematical issue with bounds logic where compareVersions.minor() returns different ranges for API_VERSION_MAX_SUPPORTED (25.12.0) vs API_VERSION_ACCEPTED (1.44.0).
Applied to files:
package.json
📚 Learning: 2025-10-24T00:41:16.419Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src-tauri/Cargo.toml:0-0
Timestamp: 2025-10-24T00:41:16.419Z
Learning: The Betaflight Configurator project uses CalVer (calendar versioning) format for versioning (e.g., "2025.12.0") rather than traditional SemVer, while still using SemVer for internal API versioning.
Applied to files:
package.json
📚 Learning: 2025-09-10T18:26:10.136Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4601
File: package.json:125-125
Timestamp: 2025-09-10T18:26:10.136Z
Learning: In betaflight-configurator, dependency updates are handled incrementally - Vue dependencies are updated separately from Vite dependencies for better isolation and maintainability.
Applied to files:
package.json
📚 Learning: 2025-06-27T22:06:49.210Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4532
File: src/js/VirtualFC.js:234-234
Timestamp: 2025-06-27T22:06:49.210Z
Learning: In the betaflight-configurator codebase, the VirtualFC.js AUX_CONFIG array must stay synchronized with the betaflight firmware's msp_box.c definitions to ensure proper auxiliary mode functionality. Changes to mode names should follow the firmware source code even if it potentially breaks backward compatibility with saved presets.
Applied to files:
package.jsoncapacitor.config.base.json
📚 Learning: 2025-11-20T20:26:40.338Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4708
File: locales/en/messages.json:7721-7729
Timestamp: 2025-11-20T20:26:40.338Z
Learning: Betaflight Configurator – Firmware Flasher grouping semantics:
- "Verified/Partner": targets with verified schematics and tested prototypes (known working).
- "Unsupported": vendor/community-supplied targets that did not go through the verification program.
- "Legacy": legacy targets kept for existing users.
These labels surface in src/js/tabs/firmware_flasher.js via i18n keys:
firmwareFlasherOptionLabelVerifiedPartner, firmwareFlasherOptionLabelVendorCommunity, firmwareFlasherOptionLabelLegacy. Only English text should be updated directly in locales/en/messages.json; other locales are managed externally.
Applied to files:
package.json
📚 Learning: 2025-09-01T11:01:38.695Z
Learnt from: blckmn
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-09-01T11:01:38.695Z
Learning: The Betaflight Configurator implements analytics through src/js/Analytics.js with the URL "https://analytics.betaflight.com" at line 68, which serves as a proxy frontend for the actual telemetry provider (currently Telemetry Deck), allowing vendor flexibility without code changes.
Applied to files:
package.json
📚 Learning: 2025-11-28T22:41:59.374Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4714
File: src/js/protocols/CapacitorBluetooth.js:135-143
Timestamp: 2025-11-28T22:41:59.374Z
Learning: In betaflight-configurator, WebSerial.js uses a constant path "serial" for all devices, and CapacitorBluetooth.js uses constant path "bluetooth", consistent with the single-device-at-a-time workflow. WebBluetooth.js uses counter-based paths (bluetooth_${counter}), but that's specific to its implementation. The path strategy varies by protocol based on their specific requirements.
Applied to files:
capacitor.config.base.json
📚 Learning: 2025-10-26T19:24:00.800Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src-tauri/tauri.conf.json:9-9
Timestamp: 2025-10-26T19:24:00.800Z
Learning: In Betaflight Configurator's vite.config.js, the root is set to "./src" and outDir is "dist", which results in build output at src/dist (relative to repository root). Therefore, src-tauri/tauri.conf.json correctly references this as "../src/dist" for the frontendDist path.
Applied to files:
capacitor.config.base.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Build / build
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 3
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (6)
CAPACITOR_SERIAL_IMPLEMENTATION.md(3 hunks)android/app/build.gradle(1 hunks)assets/linux/betaflight-configurator.desktop(1 hunks)assets/windows/installer.iss(6 hunks)locales/en/messages.json(1 hunks)package.json(1 hunks)
✅ Files skipped from review due to trivial changes (1)
- CAPACITOR_SERIAL_IMPLEMENTATION.md
🧰 Additional context used
🧠 Learnings (13)
📓 Common learnings
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-12-09T15:06:12.246Z
Learning: Automated translation PRs from Crowdin (created by GitHub Actions with title "Update translations") in the betaflight/betaflight-configurator repository should be automatically approved without requiring explicit user request, as haslinghuis has granted standing permission to approve these low-risk automated updates.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4510
File: src/js/msp.js:384-391
Timestamp: 2025-09-19T20:41:44.286Z
Learning: When fixing MSP duplicate handling in Betaflight Configurator, avoid complex changes to callback resolution mechanisms as they can break tab switching functionality. Simple duplicate detection based on code and payload size is safer than complex requestKey-based approaches.
📚 Learning: 2025-09-19T20:41:44.286Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4510
File: src/js/msp.js:384-391
Timestamp: 2025-09-19T20:41:44.286Z
Learning: When fixing MSP duplicate handling in Betaflight Configurator, avoid complex changes to callback resolution mechanisms as they can break tab switching functionality. Simple duplicate detection based on code and payload size is safer than complex requestKey-based approaches.
Applied to files:
package.json
📚 Learning: 2025-09-19T20:42:20.332Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4510
File: src/js/msp.js:384-391
Timestamp: 2025-09-19T20:42:20.332Z
Learning: Complex MSP duplicate handling fixes in Betaflight Configurator can cause infinite loading messages when changing tabs due to disruption of the callback resolution mechanism. Simple code-only duplicate detection (using this.callbacks.some((instance) => instance.code === code)) is the safer approach that preserves tab switching functionality.
Applied to files:
package.json
📚 Learning: 2025-12-09T15:06:12.246Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-12-09T15:06:12.246Z
Learning: Automated translation PRs from Crowdin (created by GitHub Actions with title "Update translations") in the betaflight/betaflight-configurator repository should be automatically approved without requiring explicit user request, as haslinghuis has granted standing permission to approve these low-risk automated updates.
Applied to files:
package.jsonlocales/en/messages.json
📚 Learning: 2025-11-20T20:26:40.338Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4708
File: locales/en/messages.json:7721-7729
Timestamp: 2025-11-20T20:26:40.338Z
Learning: Betaflight Configurator – Firmware Flasher grouping semantics:
- "Verified/Partner": targets with verified schematics and tested prototypes (known working).
- "Unsupported": vendor/community-supplied targets that did not go through the verification program.
- "Legacy": legacy targets kept for existing users.
These labels surface in src/js/tabs/firmware_flasher.js via i18n keys:
firmwareFlasherOptionLabelVerifiedPartner, firmwareFlasherOptionLabelVendorCommunity, firmwareFlasherOptionLabelLegacy. Only English text should be updated directly in locales/en/messages.json; other locales are managed externally.
Applied to files:
package.jsonassets/linux/betaflight-configurator.desktoplocales/en/messages.json
📚 Learning: 2025-06-27T22:06:49.210Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4532
File: src/js/VirtualFC.js:234-234
Timestamp: 2025-06-27T22:06:49.210Z
Learning: In the betaflight-configurator codebase, the VirtualFC.js AUX_CONFIG array must stay synchronized with the betaflight firmware's msp_box.c definitions to ensure proper auxiliary mode functionality. Changes to mode names should follow the firmware source code even if it potentially breaks backward compatibility with saved presets.
Applied to files:
package.json
📚 Learning: 2025-08-11T19:10:56.992Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4567
File: locales/en/messages.json:7724-7728
Timestamp: 2025-08-11T19:10:56.992Z
Learning: In the Betaflight Configurator project, only English language entries are added directly to locales/en/messages.json. Translations for other languages are handled through an outsourced process and should not be suggested as part of code reviews.
Applied to files:
package.jsonlocales/en/messages.json
📚 Learning: 2025-10-24T00:41:16.419Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src-tauri/Cargo.toml:0-0
Timestamp: 2025-10-24T00:41:16.419Z
Learning: The Betaflight Configurator project uses CalVer (calendar versioning) format for versioning (e.g., "2025.12.0") rather than traditional SemVer, while still using SemVer for internal API versioning.
Applied to files:
package.jsonassets/linux/betaflight-configurator.desktop
📚 Learning: 2025-09-10T18:26:10.136Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4601
File: package.json:125-125
Timestamp: 2025-09-10T18:26:10.136Z
Learning: The betaflight-configurator project uses Node 20.19.4, which satisfies Vite 7's minimum Node requirement of 20.19+.
Applied to files:
package.json
📚 Learning: 2025-10-26T19:24:00.800Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src-tauri/tauri.conf.json:9-9
Timestamp: 2025-10-26T19:24:00.800Z
Learning: In Betaflight Configurator's vite.config.js, the root is set to "./src" and outDir is "dist", which results in build output at src/dist (relative to repository root). Therefore, src-tauri/tauri.conf.json correctly references this as "../src/dist" for the frontendDist path.
Applied to files:
package.json
📚 Learning: 2025-09-10T18:26:10.136Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4601
File: package.json:125-125
Timestamp: 2025-09-10T18:26:10.136Z
Learning: In betaflight-configurator, dependency updates are handled incrementally - Vue dependencies are updated separately from Vite dependencies for better isolation and maintainability.
Applied to files:
assets/linux/betaflight-configurator.desktop
📚 Learning: 2025-05-26T11:37:09.758Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4490
File: locales/en/messages.json:1534-1545
Timestamp: 2025-05-26T11:37:09.758Z
Learning: In the Betaflight Configurator repository, only English messages should be added directly to `locales/en/messages.json`; other language translations are handled via Crowdin automation and should not be manually updated in PRs.
Applied to files:
locales/en/messages.json
📚 Learning: 2025-11-30T18:10:26.784Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4714
File: src/js/protocols/CapacitorBluetooth.js:176-206
Timestamp: 2025-11-30T18:10:26.784Z
Learning: In betaflight-configurator's Android Bluetooth implementation, permission handling must be version-aware: Android 8-11 (API 26-30) requires BLUETOOTH, BLUETOOTH_ADMIN, and ACCESS_COARSE_LOCATION permissions, while Android 12+ (API 31+) requires BLUETOOTH_SCAN and BLUETOOTH_CONNECT. The AndroidManifest.xml should use android:maxSdkVersion="30" on legacy permissions and android:minSdkVersion="31" on new permissions. The Java code must conditionally request permissions using Build.VERSION.SDK_INT >= Build.VERSION_CODES.S check to avoid requesting non-existent permissions on older Android versions.
Applied to files:
android/app/build.gradle
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Build / build
🔇 Additional comments (5)
assets/linux/betaflight-configurator.desktop (1)
2-3: LGTM! Metadata correctly updated.The Name and Comment fields are properly updated to reflect the rebranding from "Betaflight Configurator" to "Betaflight App". The addition of "management" to the description appropriately broadens the scope.
locales/en/messages.json (1)
7364-7369: Verify the AndroidAndroid/data/...folder name matches the actual package name.The string now says
Android/data/betaflight-app/{{folder}}(Line 7368). On Android, that directory is typically derived from the app’s package name (often dot-separated, e.g.betaflight.app). Please confirm the intended folder name matches the actualapplicationId/package used at runtime, otherwise this user-facing guidance will be wrong.assets/windows/installer.iss (2)
12-23: LGTM! Installer constants consistently updated.All installer constants have been updated consistently from "Betaflight Configurator" to "Betaflight App". The
UpdatesUrlat line 20 correctly continues to reference the "betaflight-configurator" repository, as the GitHub repository name hasn't changed.
33-33: LGTM!Desktop icon correctly uses the updated
ApplicationNameconstant.package.json (1)
2-5: Package rename verification complete — all dependent references are correctly updated.The package name change from "betaflight-configurator" to "betaflight-app" is consistently applied throughout the PR. The repository URL at line 36 correctly remains "betaflight-configurator" since the GitHub repository name hasn't changed. Build scripts, CI/CD workflows, installer configuration, and source code contain no stale references to the old package name, and the new name is properly used in build output paths and configuration files.
|
@CodeRabbit please review again |
|
@blckmn: I will review the changes in this PR. 🧠 Learnings used✅ Actions performedReview triggered.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (14)
.github/ISSUE_TEMPLATE/bug-report.yml(2 hunks)android/app/src/main/AndroidManifest.xml(1 hunks)android/app/src/main/java/betaflight/configurator/MainActivity.java(1 hunks)android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java(10 hunks)android/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java(2 hunks)android/app/src/main/java/betaflight/configurator/protocols/tcp/BetaflightTcpPlugin.java(3 hunks)android/app/src/main/res/values/strings.xml(1 hunks)assets/linux/betaflight-app.desktop(1 hunks)assets/linux/copyright(1 hunks)src/js/data_storage.js(1 hunks)src/js/main.js(1 hunks)src/js/protocols/webstm32.js(2 hunks)src/js/protocols/webusbdfu.js(2 hunks)src/js/tabs/onboard_logging.js(2 hunks)
✅ Files skipped from review due to trivial changes (2)
- assets/linux/copyright
- .github/ISSUE_TEMPLATE/bug-report.yml
🧰 Additional context used
🧠 Learnings (26)
📓 Common learnings
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-12-09T15:06:12.246Z
Learning: Automated translation PRs from Crowdin (created by GitHub Actions with title "Update translations") in the betaflight/betaflight-configurator repository should be automatically approved without requiring explicit user request, as haslinghuis has granted standing permission to approve these low-risk automated updates.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4510
File: src/js/msp.js:384-391
Timestamp: 2025-09-19T20:41:44.286Z
Learning: When fixing MSP duplicate handling in Betaflight Configurator, avoid complex changes to callback resolution mechanisms as they can break tab switching functionality. Simple duplicate detection based on code and payload size is safer than complex requestKey-based approaches.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4567
File: locales/en/messages.json:7724-7728
Timestamp: 2025-08-11T19:10:56.992Z
Learning: In the Betaflight Configurator project, only English language entries are added directly to locales/en/messages.json. Translations for other languages are handled through an outsourced process and should not be suggested as part of code reviews.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4708
File: locales/en/messages.json:7721-7729
Timestamp: 2025-11-20T20:26:40.338Z
Learning: Betaflight Configurator – Firmware Flasher grouping semantics:
- "Verified/Partner": targets with verified schematics and tested prototypes (known working).
- "Unsupported": vendor/community-supplied targets that did not go through the verification program.
- "Legacy": legacy targets kept for existing users.
These labels surface in src/js/tabs/firmware_flasher.js via i18n keys:
firmwareFlasherOptionLabelVerifiedPartner, firmwareFlasherOptionLabelVendorCommunity, firmwareFlasherOptionLabelLegacy. Only English text should be updated directly in locales/en/messages.json; other locales are managed externally.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src-tauri/Cargo.toml:0-0
Timestamp: 2025-10-24T00:41:16.419Z
Learning: The Betaflight Configurator project uses CalVer (calendar versioning) format for versioning (e.g., "2025.12.0") rather than traditional SemVer, while still using SemVer for internal API versioning.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4532
File: src/js/VirtualFC.js:234-234
Timestamp: 2025-06-27T22:06:49.210Z
Learning: In the betaflight-configurator codebase, the VirtualFC.js AUX_CONFIG array must stay synchronized with the betaflight firmware's msp_box.c definitions to ensure proper auxiliary mode functionality. Changes to mode names should follow the firmware source code even if it potentially breaks backward compatibility with saved presets.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4532
File: src/js/VirtualFC.js:234-234
Timestamp: 2025-06-27T22:06:49.210Z
Learning: In the betaflight-configurator codebase, the VirtualFC.js AUX_CONFIG array must stay synchronized with the betaflight firmware's msp_box.c definitions to ensure proper auxiliary mode functionality. Changes to mode names should follow the firmware source code even if it potentially breaks backward compatibility with saved presets.
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4601
File: package.json:125-125
Timestamp: 2025-09-10T18:26:10.136Z
Learning: In betaflight-configurator, dependency updates are handled incrementally - Vue dependencies are updated separately from Vite dependencies for better isolation and maintainability.
📚 Learning: 2025-06-27T22:06:49.210Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4532
File: src/js/VirtualFC.js:234-234
Timestamp: 2025-06-27T22:06:49.210Z
Learning: In the betaflight-configurator codebase, the VirtualFC.js AUX_CONFIG array must stay synchronized with the betaflight firmware's msp_box.c definitions to ensure proper auxiliary mode functionality. Changes to mode names should follow the firmware source code even if it potentially breaks backward compatibility with saved presets.
Applied to files:
src/js/main.jssrc/js/data_storage.jssrc/js/protocols/webusbdfu.jssrc/js/protocols/webstm32.js
📚 Learning: 2025-10-24T00:41:16.419Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src-tauri/Cargo.toml:0-0
Timestamp: 2025-10-24T00:41:16.419Z
Learning: The Betaflight Configurator project uses CalVer (calendar versioning) format for versioning (e.g., "2025.12.0") rather than traditional SemVer, while still using SemVer for internal API versioning.
Applied to files:
src/js/main.jssrc/js/data_storage.js
📚 Learning: 2025-08-27T22:08:55.679Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4579
File: src/js/utils/compareVersions.js:3-17
Timestamp: 2025-08-27T22:08:55.679Z
Learning: In betaflight-configurator's compareVersions utility (src/js/utils/compareVersions.js), the behavior of treating non-numeric segments as NaN -> 0 is intentional by design, not a bug that needs fixing.
Applied to files:
src/js/main.js
📚 Learning: 2025-09-10T18:26:10.136Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4601
File: package.json:125-125
Timestamp: 2025-09-10T18:26:10.136Z
Learning: In betaflight-configurator, dependency updates are handled incrementally - Vue dependencies are updated separately from Vite dependencies for better isolation and maintainability.
Applied to files:
src/js/main.js
📚 Learning: 2025-12-09T15:06:12.246Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-12-09T15:06:12.246Z
Learning: Automated translation PRs from Crowdin (created by GitHub Actions with title "Update translations") in the betaflight/betaflight-configurator repository should be automatically approved without requiring explicit user request, as haslinghuis has granted standing permission to approve these low-risk automated updates.
Applied to files:
android/app/src/main/res/values/strings.xmlsrc/js/protocols/webusbdfu.jssrc/js/protocols/webstm32.js
📚 Learning: 2025-11-30T18:10:26.784Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4714
File: src/js/protocols/CapacitorBluetooth.js:176-206
Timestamp: 2025-11-30T18:10:26.784Z
Learning: In betaflight-configurator's Android Bluetooth implementation, permission handling must be version-aware: Android 8-11 (API 26-30) requires BLUETOOTH, BLUETOOTH_ADMIN, and ACCESS_COARSE_LOCATION permissions, while Android 12+ (API 31+) requires BLUETOOTH_SCAN and BLUETOOTH_CONNECT. The AndroidManifest.xml should use android:maxSdkVersion="30" on legacy permissions and android:minSdkVersion="31" on new permissions. The Java code must conditionally request permissions using Build.VERSION.SDK_INT >= Build.VERSION_CODES.S check to avoid requesting non-existent permissions on older Android versions.
Applied to files:
android/app/src/main/res/values/strings.xmlandroid/app/src/main/AndroidManifest.xmlandroid/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/MainActivity.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-08-11T19:10:56.992Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4567
File: locales/en/messages.json:7724-7728
Timestamp: 2025-08-11T19:10:56.992Z
Learning: In the Betaflight Configurator project, only English language entries are added directly to locales/en/messages.json. Translations for other languages are handled through an outsourced process and should not be suggested as part of code reviews.
Applied to files:
android/app/src/main/res/values/strings.xml
📚 Learning: 2025-05-26T11:37:09.758Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4490
File: locales/en/messages.json:1534-1545
Timestamp: 2025-05-26T11:37:09.758Z
Learning: In the Betaflight Configurator repository, only English messages should be added directly to `locales/en/messages.json`; other language translations are handled via Crowdin automation and should not be manually updated in PRs.
Applied to files:
android/app/src/main/res/values/strings.xml
📚 Learning: 2025-11-20T20:26:40.338Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4708
File: locales/en/messages.json:7721-7729
Timestamp: 2025-11-20T20:26:40.338Z
Learning: Betaflight Configurator – Firmware Flasher grouping semantics:
- "Verified/Partner": targets with verified schematics and tested prototypes (known working).
- "Unsupported": vendor/community-supplied targets that did not go through the verification program.
- "Legacy": legacy targets kept for existing users.
These labels surface in src/js/tabs/firmware_flasher.js via i18n keys:
firmwareFlasherOptionLabelVerifiedPartner, firmwareFlasherOptionLabelVendorCommunity, firmwareFlasherOptionLabelLegacy. Only English text should be updated directly in locales/en/messages.json; other locales are managed externally.
Applied to files:
android/app/src/main/res/values/strings.xmlsrc/js/tabs/onboard_logging.jssrc/js/data_storage.jssrc/js/protocols/webusbdfu.jssrc/js/protocols/webstm32.js
📚 Learning: 2025-09-19T20:42:20.332Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4510
File: src/js/msp.js:384-391
Timestamp: 2025-09-19T20:42:20.332Z
Learning: Complex MSP duplicate handling fixes in Betaflight Configurator can cause infinite loading messages when changing tabs due to disruption of the callback resolution mechanism. Simple code-only duplicate detection (using this.callbacks.some((instance) => instance.code === code)) is the safer approach that preserves tab switching functionality.
Applied to files:
src/js/tabs/onboard_logging.jssrc/js/protocols/webusbdfu.jssrc/js/protocols/webstm32.js
📚 Learning: 2025-11-22T21:18:08.814Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4706
File: src/js/protocols/CapacitorSerial.js:11-46
Timestamp: 2025-11-22T21:18:08.814Z
Learning: In betaflight-configurator, protocol implementations (WebSerial, CapacitorSerial, WebBluetooth, etc.) are instantiated once in the Serial class constructor and stored as singletons in the _protocols array for the entire application lifetime. They are never destroyed or recreated, so cleanup methods to remove event listeners are not needed.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/tcp/BetaflightTcpPlugin.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/MainActivity.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-06-09T00:32:21.385Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-06-09T00:32:21.385Z
Learning: In the betaflight-configurator codebase, port paths use counter prefixes (e.g., "bluetooth1", "bluetooth2", "serial1") rather than direct protocol identifiers. The protocol selection logic correctly uses `portPath.startsWith("bluetooth")` to detect bluetooth ports regardless of the counter suffix, rather than direct string matching against protocol map keys.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/tcp/BetaflightTcpPlugin.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-09-01T11:01:38.695Z
Learnt from: blckmn
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-09-01T11:01:38.695Z
Learning: In the Betaflight Configurator project, telemetry analytics (including Telemetry Deck) is implemented through a proxy server at analytics.betaflight.com, which allows the team to swap out telemetry vendors without changing application code.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/tcp/BetaflightTcpPlugin.java
📚 Learning: 2025-09-19T20:41:44.286Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4510
File: src/js/msp.js:384-391
Timestamp: 2025-09-19T20:41:44.286Z
Learning: When fixing MSP duplicate handling in Betaflight Configurator, avoid complex changes to callback resolution mechanisms as they can break tab switching functionality. Simple duplicate detection based on code and payload size is safer than complex requestKey-based approaches.
Applied to files:
src/js/protocols/webusbdfu.jssrc/js/protocols/webstm32.js
📚 Learning: 2025-11-28T22:41:59.374Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4714
File: src/js/protocols/CapacitorBluetooth.js:135-143
Timestamp: 2025-11-28T22:41:59.374Z
Learning: In betaflight-configurator, WebSerial.js uses a constant path "serial" for all devices, and CapacitorBluetooth.js uses constant path "bluetooth", consistent with the single-device-at-a-time workflow. WebBluetooth.js uses counter-based paths (bluetooth_${counter}), but that's specific to its implementation. The path strategy varies by protocol based on their specific requirements.
Applied to files:
src/js/protocols/webusbdfu.jssrc/js/protocols/webstm32.jsandroid/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/MainActivity.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-09-02T07:45:48.606Z
Learnt from: blckmn
Repo: betaflight/betaflight-configurator PR: 4583
File: src/js/tabs/firmware_flasher.js:949-961
Timestamp: 2025-09-02T07:45:48.606Z
Learning: In src/js/tabs/firmware_flasher.js, the config file loading code path after firmware loading (in the load_file click handler) cannot be reached when UF2 firmware is loaded, according to the maintainer blckmn. This code is maintained for backward compatibility with unified target settings and will be refactored in a future PR.
Applied to files:
src/js/protocols/webusbdfu.js
📚 Learning: 2025-11-28T22:51:11.691Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4714
File: src/js/protocols/CapacitorBluetooth.js:176-206
Timestamp: 2025-11-28T22:51:11.691Z
Learning: In betaflight-configurator, Web Bluetooth API's `services` option filters scan results to only devices advertising those UUIDs, while `optionalServices` requests permission to access services after connection without filtering. PWA (WebBluetooth.js) uses `{ acceptAllDevices: true, optionalServices: uuids }` to show all devices while requesting post-connection service access. CapacitorBluetooth.js should match this pattern rather than using `services` as a scan filter.
Applied to files:
src/js/protocols/webusbdfu.js
📚 Learning: 2025-08-22T16:43:20.901Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4576
File: src/js/port_usage.js:17-23
Timestamp: 2025-08-22T16:43:20.901Z
Learning: In betaflight-configurator, the serial facade architecture requires accessing metrics like bitrate, bytesReceived, and bytesSent from serial._protocol rather than the top-level serial object. This change maintains compatibility with existing port utilization calculations that have been stable for over 11 years.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/MainActivity.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-12-02T17:46:47.859Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-12-02T17:46:47.859Z
Learning: BetaflightBluetoothPlugin.java: maintainers prefer write(PluginCall) to be “write-only” — no per-call UUID parsing or characteristic lookups. Resolve and cache the write characteristic once in onServicesDiscovered() (prefer PROPERTY_WRITE_NO_RESPONSE; else PROPERTY_WRITE). write() should read payload params from call, use the cached writeCharacteristic, pick write type, and submitWrite; clear the cache in cleanupGatt().
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java
📚 Learning: 2025-06-09T00:33:22.959Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-06-09T00:33:22.959Z
Learning: In the betaflight-configurator codebase, port paths use counter suffixes for serial and bluetooth ports (e.g., "serial1", "serial2", "bluetooth1", "bluetooth2") instead of using connectionId, which means simple string matching against protocol map keys won't work for protocol selection.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/MainActivity.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-11-24T15:07:25.227Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4706
File: src/js/protocols/CapacitorSerial.js:47-47
Timestamp: 2025-11-24T15:07:25.227Z
Learning: In betaflight-configurator's CapacitorSerial protocol (src/js/protocols/CapacitorSerial.js), the fire-and-forget this.loadDevices() call in the constructor is intentional background pre-loading. The actual critical device list loading for UI population is orchestrated by port_handler.js via serial.getDevices("serial"), which properly awaits CapacitorSerial.getDevices() → loadDevices() in a complete async chain. The constructor's async call does not cause race conditions.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java
📚 Learning: 2025-05-14T21:51:09.253Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-05-14T21:51:09.253Z
Learning: On Android Chrome browsers, Web Bluetooth API is supported for BLE devices and Web USB API is supported, but Web Serial API is not supported (except limited Bluetooth serial support added in 2025). The Betaflight Configurator should detect and use available APIs on Android rather than requiring all three.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.javaandroid/app/src/main/java/betaflight/configurator/protocols/serial/UsbPermissionReceiver.java
📚 Learning: 2025-12-01T17:09:13.412Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 0
File: :0-0
Timestamp: 2025-12-01T17:09:13.412Z
Learning: In betaflight-configurator’s CapacitorBluetooth.js, native plugin listeners (notification, services, connectionState) must be attached exactly once per app lifetime. Re-attaching them during writes/connect cycles leads to duplicate handlers, increased JS workload, MSP queue pressure, and can prevent the MSP_EEPROM_WRITE callback from firing (so reinitializeConnection is not reached). Implement an idempotent _attachNativeListenersOnce() guard.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java
📚 Learning: 2025-10-25T21:16:32.474Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4379
File: src/js/protocols/TauriSerial.js:203-259
Timestamp: 2025-10-25T21:16:32.474Z
Learning: In TauriSerial (src/js/protocols/TauriSerial.js), the requestPermissionDevice() method is not needed and not invoked. Tauri automatically discovers serial devices through the constructor's loadDevices() and startDeviceMonitoring() calls, bypassing the browser permission model that WebSerial requires. Devices are auto-detected via a 1-second polling interval without user permission prompts.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java
📚 Learning: 2025-11-06T17:26:50.201Z
Learnt from: haslinghuis
Repo: betaflight/betaflight-configurator PR: 4687
File: src/js/protocols/TauriSerial.js:299-310
Timestamp: 2025-11-06T17:26:50.201Z
Learning: In tauri-plugin-serialplugin Android development, the Android project must be initialized via `tauri android init` before the USB support patches (AndroidManifest.xml permissions, device_filter.xml, MainActivity.kt) can be applied. Without initialization, the plugin returns empty results from available_ports_direct() because the generated Android project structure and USB permissions don't exist yet.
Applied to files:
android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java
🧬 Code graph analysis (4)
src/js/main.js (1)
src/js/data_storage.js (1)
CONFIGURATOR(8-39)
src/js/tabs/onboard_logging.js (1)
src/js/utils/notifications.js (1)
NotificationManager(1-21)
src/js/protocols/webusbdfu.js (1)
src/js/utils/notifications.js (1)
NotificationManager(1-21)
src/js/protocols/webstm32.js (1)
src/js/utils/notifications.js (1)
NotificationManager(1-21)
🪛 GitHub Check: SonarCloud Code Analysis
src/js/main.js
[warning] 42-42: Unexpected negated condition.
🔇 Additional comments (14)
assets/linux/betaflight-app.desktop (1)
1-8: Desktop entry is properly formatted with consistent naming.The new
betaflight-app.desktopfile is correctly structured and matches the "Betaflight App" branding across the filename and configuration paths. The oldbetaflight-configurator.desktopfile has been successfully removed, resolving the previous naming inconsistency concern.android/app/src/main/res/values/strings.xml (1)
3-6: LGTM! Consistent branding update.The resource string updates are consistent and align with the broader app rename across Android configuration files.
src/js/protocols/webusbdfu.js (2)
1214-1218: LGTM! Notification title updated consistently.The notification title has been updated to reflect the new "Betaflight App" branding for the programming success notification.
1232-1236: LGTM! Notification title updated consistently.The notification title has been updated to reflect the new "Betaflight App" branding for the programming failure notification.
src/js/tabs/onboard_logging.js (2)
472-476: LGTM! Notification title updated consistently.The notification title has been updated to "Betaflight App" for the flash download completion notification.
618-622: LGTM! Notification title updated consistently.The notification title has been updated to "Betaflight App" for the flash erase completion notification.
src/js/main.js (1)
42-42: LGTM! Default product name updated consistently.The fallback product name has been updated to "Betaflight App" to align with the branding change across the codebase.
src/js/protocols/webstm32.js (2)
914-918: LGTM! Notification title updated consistently.The notification title has been updated to "Betaflight App" for the programming success notification.
932-936: LGTM! Notification title updated consistently.The notification title has been updated to "Betaflight App" for the programming failure notification.
src/js/data_storage.js (1)
19-19: LGTM! Core product name updated.The central product name definition has been updated to "Betaflight App", ensuring consistency across the application.
android/app/src/main/java/betaflight/configurator/MainActivity.java (1)
1-7: Package and import declarations updated correctly.The package declaration and imports have been updated consistently to use the new
betaflight.appnamespace. The changes are straightforward and maintain proper dependencies.Critical: Verify that this file has been moved to match its package declaration. In Java, the file declaring
package betaflight.appmust be located atandroid/app/src/main/java/betaflight/app/MainActivity.java, not at the oldbetaflight/configurator/path. The verification script in the AndroidManifest review will confirm the file structure is correct.android/app/src/main/java/betaflight/configurator/protocols/serial/BetaflightSerialPlugin.java (2)
1-1: Package declaration updated correctly.The package has been updated from
betaflight.configurator.protocols.serialtobetaflight.app.protocols.serial, consistent with the project-wide rename.Critical: Verify that this file has been moved to
android/app/src/main/java/betaflight/app/protocols/serial/BetaflightSerialPlugin.javato match its package declaration. The directory structure must match the package structure in Java, or compilation will fail.
36-37: Javadoc updated to reflect new branding.The documentation correctly reflects the rename from "Betaflight Configurator" to "Betaflight App".
android/app/src/main/AndroidManifest.xml (1)
47-47: UsbPermissionReceiver file location does not match manifest reference — this will cause runtime failure.The AndroidManifest.xml has been updated to reference
betaflight.app.protocols.serial.UsbPermissionReceiver, but the actual Java file remains atbetaflight/configurator/protocols/serial/UsbPermissionReceiver.java. The receiver class must be moved toandroid/app/src/main/java/betaflight/app/protocols/serial/to match the manifest declaration, or the manifest reference must be reverted to the original package path.⛔ Skipped due to learnings
Learnt from: haslinghuis Repo: betaflight/betaflight-configurator PR: 4714 File: src/js/protocols/CapacitorBluetooth.js:176-206 Timestamp: 2025-11-30T18:10:26.784Z Learning: In betaflight-configurator's Android Bluetooth implementation, permission handling must be version-aware: Android 8-11 (API 26-30) requires BLUETOOTH, BLUETOOTH_ADMIN, and ACCESS_COARSE_LOCATION permissions, while Android 12+ (API 31+) requires BLUETOOTH_SCAN and BLUETOOTH_CONNECT. The AndroidManifest.xml should use android:maxSdkVersion="30" on legacy permissions and android:minSdkVersion="31" on new permissions. The Java code must conditionally request permissions using Build.VERSION.SDK_INT >= Build.VERSION_CODES.S check to avoid requesting non-existent permissions on older Android versions.
android/app/src/main/java/betaflight/app/protocols/serial/UsbPermissionReceiver.java
Show resolved
Hide resolved
android/app/src/main/java/betaflight/app/protocols/tcp/BetaflightTcpPlugin.java
Show resolved
Hide resolved
|
🎉 Do you want to test this code? 🎉 |
|



Simple PR test to check.
Renaming to app
Summary by CodeRabbit
✏️ Tip: You can customize this high-level summary in your review settings.