Skip to content

[Bug] Errors thrown and window flashes black on Linux Arm ChromeOS #7808

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

Open
nissimk opened this issue Apr 22, 2025 · 7 comments
Open

[Bug] Errors thrown and window flashes black on Linux Arm ChromeOS #7808

nissimk opened this issue Apr 22, 2025 · 7 comments

Comments

@nissimk
Copy link

nissimk commented Apr 22, 2025

Bug Description

I built the code on an aarch64 vm in Google cloud using the git clone method to install flutter. I modified the debian/CONTROL file to say arm64 as the architecture and built a .Deb package using the script. I installed the script in the "penguin Linux" environment on my Chromebook. The app runs but the window flashes between the login screen and blank. And these errors print in the console:

2025-04-22 06:00:04 ERROR dart_ffi: [Flutter]: Uncaught platform error
StackTrace:
#0 DBusClient._callMethod (package:dbus/src/dbus_client.dart:1120)

#1 DBusClient.callMethod (package:dbus/src/dbus_client.dart:621)

#2 DBusRemoteObjectManager.getManagedObjects (package:dbus/src/dbus_remote_object_manager.dart:80)

#3 NetworkManagerClient.connect (package:nm/src/network_manager_client.dart:2351)

#4 ConnectivityPlusLinuxPlugin.checkConnectivity (package:connectivity_plus/src/connectivity_plus_linux.dart:24)

#5 NetworkListener.start (package:appflowy/core/network_monitor.dart:22)

#6 AppLauncher.launch (package:appflowy/startup/startup.dart:241)

#7 FlowyRunner.run (package:appflowy/startup/startup.dart:153)

#8 runAppFlowy (package:appflowy/startup/startup.dart:39)
#9 main (package:appflowy/main.dart:10)

at dart-ffi/src/lib.rs:290

(AppFlowy:1516): Gdk-CRITICAL **: 06:00:11.117: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

The device is a Lenovo duet with a MediaTek Kompanio 500 and 4gb of ram.

How to Reproduce

I used a t2a-standard-4 Google cloud instance to build the source. This machine runs on Arm64 CPU architecture. I had to attach a 40GB disk because the 10GB default disk is not big enough for the build output. Make sure to checkout appFlowy source to the attached disk. Follow method 2 to install flutter from here: https://docs.appflowy.io/docs/documentation/appflowy/from-source/environment-setup/building-on-linux

Follow the build instructions from that link.
Modify frontend/scripts/linux_distribution/deb/DEBIAN/control and set architecture to arm64
follow instructions for build deb from the readme to build .deb file.

Use gcloud scp to transfer deb file to Chromebook.
Use sudo dpkg -i AppFlowy_0.8.9.deb to install Deb file in chrome linux
run AppFlowy

The steps I ran on the cloud instance could also be done on any other Arm64 Linux machine with enough RAM and storage.

Expected Behavior

The app runs without weird flashing black and without printing error messages in the console

Operating System

Linux

AppFlowy Version(s)

0.8.9

Screenshots

No response

Additional Context

No response

@LucasXu0
Copy link
Collaborator

Hi @nissimk, since I didn't test it on ARM64 Linux and Flutter hasn't released official ARM64 support on Linux, there may be some unknown issues when you build the application. It would be better if you could attach a video recording and the detailed logs to help us address the issues.

@nissimk
Copy link
Author

nissimk commented Apr 23, 2025

Screen.recording.2025-04-23.8.59.59.AM.webm

You can see at first the screen was black. Then when I switched back and forth to the terminal and back to AppFlowy then the UI was visible but it was not responding to the mouse.

@nissimk
Copy link
Author

nissimk commented Apr 23, 2025

`nissim@penguin:~$ AppFlowy

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:10.809: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:10.813: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed
Creating user data folder for URL: https://beta.appflowy.cloud, root:/home/nissim/.local/share/io.appflowy.appflowy/data 2025-04-23 09:00:12 INFO flowy_core: 💡Some("Linux 12 Debian GNU/Linux"), platform: Linux
at flowy-core/src/lib.rs:96

{"msg":"💡Some("Linux 12 Debian GNU/Linux"), platform: Linux","time":"04-23 09:00:12","target":"flowy_core"}
{"msg":"[🟢 INIT - START]","time":"04-23 09:00:12","target":"flowy_core"}
2025-04-23 09:00:12 INFO flowy_core: 🔥AppFlowy Configuration { app_version: Version { major: 0, minor: 8, patch: 9 }, storage_path: "/home/nissim/.local/share/io.appflowy.appflowy/data_beta.appflowy.cloud", application_path: "/home/nissim/.local/share/io.appflowy.appflowy/data", base_url: "https://beta.appflowy.cloud", ws_url: "wss://beta.appflowy.cloud:443/ws/v1", gotrue_url: "https://beta.appflowy.cloud/gotrue", enable_sync_trace: false }
at flowy-core/src/lib.rs:116
in flowy_core::init
{"msg":"[INIT - EVENT] 🔥AppFlowy Configuration { app_version: Version { major: 0, minor: 8, patch: 9 }, storage_path: "/home/nissim/.local/share/io.appflowy.appflowy/data_beta.appflowy.cloud", application_path: "/home/nissim/.local/share/io.appflowy.appflowy/data", base_url: "https://beta.appflowy.cloud\", ws_url: "wss://beta.appflowy.cloud:443/ws/v1", gotrue_url: "https://beta.appflowy.cloud/gotrue\", enable_sync_trace: false }","time":"04-23 09:00:12","target":"flowy_core"}
{"msg":"[INIT - END]","time":"04-23 09:00:13","target":"flowy_core"}
2025-04-23 09:00:13 INFO dart_ffi: [Flutter]: [AutoUpdate] current version: 0.8.9, current cpu architecture: x86_64
at dart-ffi/src/lib.rs:286

{"msg":"[Flutter]: [AutoUpdate] current version: 0.8.9, current cpu architecture: x86_64","time":"04-23 09:00:13","target":"dart_ffi"}
2025-04-23 09:00:13 INFO dart_ffi: [Flutter]: [AutoUpdate] feed url: https://github.com/AppFlowy-IO/AppFlowy/releases/latest/download/appcast-linux-x86_64.xml
at dart-ffi/src/lib.rs:286

{"msg":"[Flutter]: [AutoUpdate] feed url: https://github.com/AppFlowy-IO/AppFlowy/releases/latest/download/appcast-linux-x86_64.xml","time":"04-23 09:00:13","target":"dart_ffi"}
2025-04-23 09:00:13 INFO flowy_storage::manager: register file progress stream: 2599033822031163
at flowy-storage/src/manager.rs:139

{"msg":"register file progress stream: 2599033822031163","time":"04-23 09:00:13","target":"flowy_storage::manager"}
2025-04-23 09:00:13 INFO dart_ffi: [Flutter]: Loaded icon groups in 156ms
at dart-ffi/src/lib.rs:286

{"msg":"[Flutter]: Loaded icon groups in 156ms","time":"04-23 09:00:13","target":"dart_ffi"}
2025-04-23 09:00:13 ERROR dart_ffi: [Flutter]: Uncaught platform error
StackTrace:
#0 DBusClient._callMethod (package:dbus/src/dbus_client.dart:1120)

#1 DBusClient.callMethod (package:dbus/src/dbus_client.dart:621)

#2 DBusRemoteObjectManager.getManagedObjects (package:dbus/src/dbus_remote_object_manager.dart:80)

#3 NetworkManagerClient.connect (package:nm/src/network_manager_client.dart:2351)

#4 ConnectivityPlusLinuxPlugin._startListenConnectivity (package:connectivity_plus/src/connectivity_plus_linux.dart:67)

at dart-ffi/src/lib.rs:290

{"msg":"[Flutter]: Uncaught platform error\nStackTrace:\n#0 DBusClient._callMethod (package:dbus/src/dbus_client.dart:1120)\n\n#1 DBusClient.callMethod (package:dbus/src/dbus_client.dart:621)\n\n#2 DBusRemoteObjectManager.getManagedObjects (package:dbus/src/dbus_remote_object_manager.dart:80)\n\n#3 NetworkManagerClient.connect (package:nm/src/network_manager_client.dart:2351)\n\n#4 ConnectivityPlusLinuxPlugin._startListenConnectivity (package:connectivity_plus/src/connectivity_plus_linux.dart:67)\n\n","time":"04-23 09:00:13","target":"dart_ffi"}
2025-04-23 09:00:13 ERROR dart_ffi: [Flutter]: Uncaught platform error
StackTrace:
#0 DBusClient._callMethod (package:dbus/src/dbus_client.dart:1120)

#1 DBusClient.callMethod (package:dbus/src/dbus_client.dart:621)

#2 DBusRemoteObjectManager.getManagedObjects (package:dbus/src/dbus_remote_object_manager.dart:80)

#3 NetworkManagerClient.connect (package:nm/src/network_manager_client.dart:2351)

#4 ConnectivityPlusLinuxPlugin.checkConnectivity (package:connectivity_plus/src/connectivity_plus_linux.dart:24)

#5 NetworkListener.start (package:appflowy/core/network_monitor.dart:22)

#6 AppLauncher.launch (package:appflowy/startup/startup.dart:241)

#7 FlowyRunner.run (package:appflowy/startup/startup.dart:153)

#8 runAppFlowy (package:appflowy/startup/startup.dart:39)

#9 main (package:appflowy/main.dart:10)

at dart-ffi/src/lib.rs:290

{"msg":"[Flutter]: Uncaught platform error\nStackTrace:\n#0 DBusClient._callMethod (package:dbus/src/dbus_client.dart:1120)\n\n#1 DBusClient.callMethod (package:dbus/src/dbus_client.dart:621)\n\n#2 DBusRemoteObjectManager.getManagedObjects (package:dbus/src/dbus_remote_object_manager.dart:80)\n\n#3 NetworkManagerClient.connect (package:nm/src/network_manager_client.dart:2351)\n\n#4 ConnectivityPlusLinuxPlugin.checkConnectivity (package:connectivity_plus/src/connectivity_plus_linux.dart:24)\n\n#5 NetworkListener.start (package:appflowy/core/network_monitor.dart:22)\n\n#6 AppLauncher.launch (package:appflowy/startup/startup.dart:241)\n\n#7 FlowyRunner.run (package:appflowy/startup/startup.dart:153)\n\n#8 runAppFlowy (package:appflowy/startup/startup.dart:39)\n\n#9 main (package:appflowy/main.dart:10)\n\n","time":"04-23 09:00:13","target":"dart_ffi"}

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:26.546: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:26.546: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:31.763: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:46.050: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:00:46.050: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:02:39.544: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:02:41.575: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:02:41.584: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:02:41.862: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed

(AppFlowy:2683): Gdk-CRITICAL **: 09:02:41.863: gdk_device_get_source: assertion 'GDK_IS_DEVICE (device)' failed
embedder.cc (2439): 'FlutterEngineRemoveView' returned 'kInvalidArguments'. Remove view info was invalid. The implicit view cannot be removed.

(AppFlowy:2683): GLib-GObject-WARNING **: 09:02:42.646: g_object_weak_unref: couldn't find weak ref 0x7f82205bb0(0x55602d16b8)
`

@nissimk
Copy link
Author

nissimk commented Apr 23, 2025

Has anybody tested in Chromebook Linux environment on amd64 architecture?

@khorshuheng
Copy link
Collaborator

Internally, we have tested on Fedora, Arch Linux, Ubuntu for amd64, but we don't currently have a Chromebook to test the app on.

@LucasXu0
Copy link
Collaborator

@nissimk Could you update the connectivity_plus package, as the error comes from it?

@nissimk
Copy link
Author

nissimk commented Apr 25, 2025

Good news is that I built and ran on my new raspberry pi 5 and it was working well. I didn't get a chance to package and move it to the Chromebook yet but I will this weekend.

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

No branches or pull requests

3 participants