Unable to transfer profiles from chromebook
Checklist
- [x] I have used the search function to see if someone else has already submitted the same bug report.
- [x] I will describe the problem with as much detail as possible.
App
Thunderbird for Android
App version
13.0
Where did you get the app from?
Google Play
Android version
Not as far as I know.
Device model
Chromebook Asus CX3402CB
Steps to reproduce
Open Thunderbird for Android Click Get Started Click Import Settings
Expected behavior
Open camera to read the QR codes
Actual behavior
Screen flashed black and returns to Import setting screen
Logs
Please refer to: https://support.mozilla.org/en-US/questions/1542788 for more descrition of the problem. This report is following a review I posted on Google Play. The Mozilla report question is where I first reported having problems. I followed the link to retrieve logs and just bgot a page saying "This Wiki is outdated".
The android version question shows the response to a question about the ROM Chromebook version: Your Chromebook is up to date Version 141.0.7390.126 (Official Build) (64-bit)
You want to transfer your whole profile on the same Chromebook device from TB for Linux to TB for Android? That's not possible. You can only transfer settings from Thunderbird via QR Code.
You want to transfer your whole profile on the same Chromebook device from TB for Linux to TB for Android? That's not possible. You can only transfer settings from Thunderbird via QR Code.
The problem is that the chromebook will not read the QR codes. I can print those out, but the screen flashes blank and doesn't connect to the camera to read the QR codes.
Furthermore this issue has been raised because I received a response to my review on google play: "We're sorry the QR code isn't working on a Chromebook, and we'd like to explore this more if you open an issue on our GitHub repo! (https://github.com/thunderbird/thunderbird-android/issues) We are working on ways to sync settings with the desktop that don't involve a QR code!" So I am expecting someone to explore this issue more.
This has been replicated by Angelof Darkness on the support forum: https://support.mozilla.org/en-US/questions/1542788#answer-1776331
I can confirm that issue for a Chromebook Plus 15 from HP. The camera opens for a short moment and then the welcome screen comes back. An another try to scan a QR Code ends with a crash of Thunderbird on my device.
At the moment we don't support the front camera and expect a rear facing camera only. The implementation needs to account for switching between front and rear cameras.
I'd like to work on this.
I reproduced it on an Android 16 emulator set up with only a front camera, like a Chromebook. After Get started → Import settings → Scan QR code, CameraX retries for a few seconds and then the app crashes:
FATAL EXCEPTION: main
java.lang.IllegalArgumentException: No available camera can be found. Cams:1 Id:1 Lens:0 ...
at androidx.camera.core.CameraSelector.select(CameraSelector.java:109)
at androidx.camera.lifecycle.ProcessCameraProvider.bindToLifecycle(ProcessCameraProvider.kt:211)
at app.k9mail.feature.migration.qrcode.ui.CameraPreviewViewKt$CameraPreviewView$2$1.invokeSuspend(CameraPreviewView.kt:63)
CameraPreviewView hardcodes CameraSelector.LENS_FACING_BACK, and nothing catches the exception from bindToLifecycle(). The app crashes and restarts on the import screen, which matches the "screen flashes black" in the report.
Proposed fix:
- Use the back camera when
cameraProvider.hasCamera(CameraSelector.DEFAULT_BACK_CAMERA)is true, and fall back to the front camera otherwise. - If there's no camera at all, show an error message instead of crashing.
Should a button for switching between the front and rear cameras be part of this change? Or would you prefer it as a separate follow-up, since it needs a UI decision?
I used Claude Code to help investigate this.