[Bug] AppFlowy is not visible on Launch (first-time installation)
Bug Description
Appflowy's GUI is not launching after first-time installation on my system. First-time installation was with version 0.6.9.
I have tried a large variety of troubleshooting:
- Uninstall/Reinstall with versions 0.5.3, as well as all versions between 0.5.8-0.7.0
- Clearing all AppFlowy data in %AppData% and all remnant files in install location when uninstalling. -note: %AppData%/io.appflowy/AppFlowy/data never had any files in it after installation.
- Debugging, throwing logs from the exe. No output to be seen.
How to Reproduce
- Install AppFlowy for the first time on a Windows 10 PC.
- Launch AppFlowy
Expected Behavior
AppFlowy GUI app opens to the login screen.
Operating System
Windows 10
AppFlowy Version(s)
0.5.3, and all versions between 0.5.8-0.7.0
Screenshots
Additional Context
-You can also see a blank window for AppFlowy when switching tabs, but you cannot open it nor see it anywhere. It has not loaded yet, but counts as an app.
-You can see location in use.
Same problem here. I've tried with the installer version of 0.7.1, and portable (.zip) versions of 0.7.1, 0.7.0, 0.6.9, and 0.5.9.
When I run AppFlowy, I can see a "Background processes" listing in Task Manager, but no other indication of an app running. I've tried a fresh restart. No windows, no icons in the task bar, no icons in the tray.
I took out my old Windows 10 laptop (x86_64) which hasn't been used in 5 years and had a nearly fresh install of windows, and I couldn't reproduce.
I tried walking through some possible fixes with Josion (another user with this issue) on Discord, but we didn't manage to find anything that worked.
We will keep exploring what can be causing this.
Thank you @Xazin -- I'm on Windows 11 23H2 (22631.4317). Can you tell me, from a task manager perspective, is there supposed to be an AppFlowy in both Apps and Background Processes, or just the one in Background Processes like I'm seeing?
I'm a heavy virtual desktop user. I tried scanning through the other desktops to see if it had launched somewhere else but did not find the app. I wonder if it's related though.
Thank you @Xazin -- I'm on Windows 11 23H2 (22631.4317). Can you tell me, from a task manager perspective, is there supposed to be an AppFlowy in both Apps and Background Processes, or just the one in Background Processes like I'm seeing?
I'm a heavy virtual desktop user. I tried scanning through the other desktops to see if it had launched somewhere else but did not find the app. I wonder if it's related though.
It should definitely be visible in "Apps" and not in "Backgroundprocesses". Sounds like it's related indeed.
Here's my driver info if it helps: -AMD Radeon RX 5700 XT -Driver Version 24.20.11.01-240925a-407465C-AMD-Software-Adrenalin-Edition
I do not use virtual desktops, but I do have multiple monitors.
Same issue on a GTX 1060 PC, Win10. Since people mention Win11 and Radeon, I don't think that's it. Multiple monitors though.
Same behavior with 0.7.2
Hi, @Joshua-E-Weinstein @CamiloMM @birnam, here's the alpha version of the latest release, which includes a fix for the windows visible issue. We verified it on two machines (Windows 11). Could you help test if the latest package works on your machine?
https://github.com/AppFlowy-IO/AppFlowy-Builder/releases/download/0.7.3.alpha.1/AppFlowy-0.7.3-windows-x86_64.exe
Thank you! Unfortunately I see no improvement. An 'AppFlowy' entry appears in 'Background Processes' in Task Manager, but not in Apps and there is no visible window or icon in the tray.
@birnam Thanks for testing. I've built a new version. Would you like to help test it again? This time, I’ve created an executable file instead of an installer, to avoid overwriting your existing application.
https://github.com/AppFlowy-IO/AppFlowy-Builder/releases/download/0.7.3.1_main/AppFlowy-Windows-v0.7.3.1.zip
Thanks Lucas! I tested the new standalone but unfortunately I'm only seeing the same thing as before.
Same thing here. Shows up in task manager, but no window.
Feel free to ask us to run some form of diagnostic command, or whatever technical information might help you figure this out.
Hi, I checked the Flutter issues related to invisible windows and tried another workaround mentioned to rebuild the package. So far, I've attempted the following:
- Followed the Flutter team's suggestion to upgrade to the latest Flutter version (didn't work).
- Modified windows.cpp to force the window to show (didn't work).
- Assigned the restoration scope id to the app (included in v0.7.3.2.zip).
- Added back the MS_VISIBLE flag (included in v0.7.3.2.zip).
Please help test the package below. Thanks in advance!
https://github.com/AppFlowy-IO/AppFlowy-Builder/releases/download/0.7.3.1_main/AppFlowy-Windows-v0.7.3.2.zip
Sadly this one still does not work. I wish I had a Rust environment set up to help test. Are there build instructions somewhere?
Here are the build instructions for Windows.
https://docs.appflowy.io/docs/documentation/appflowy/from-source/environment-setup/building-on-windows
Thanks @LucasXu0 - after some trial and error I did get the project building. TLDR; I found a workaround by incorporating a new dependency.
Setup: Installing Flutter meant the latest version of Flutter, though, instead of the one mentioned in the instructions (3.24 vs 3.22). This created a build error because the layoutInlineChildren call definition changed to having 3 params instead of 2. The issue was inside another package though, and updating the extended_text_field package to version 16.0.0 solves it without requiring any modification to AppFlowy code.
That is just a side issue though, but now meant I could build the project and figure out the real issue.
The actual bug:
There is a crash occuring when trying to obtain a deviceId from Windows. This is being called in device_id.dart and device_info_task.dart:
There is an open issue with the same problem on the DeviceInfoPlugin package repo, although they are mis-identifying it as only a Windows 10 problem. (I'm running Windows 11) Updating to their latest version does not improve the situation, and I'm not sure what the underlying issue is. Race condition? Something wrong with the await when invoking a native system call? I don't know.
I love finally seeing a "This task failed successfully" message in the wild though :)
Solution: However, there is another package called PlatformDeviceId that I tried using in the same place and was able to get a deviceId without crashing, completely resolving the problem.
Notes:
- Actually, I only updated the code in
device_id.dartand notdevice_info_task.dart, but that was enough. If this was something like a race condition, the conditions that caused it are perhaps corrected by the time the other code is called? A final solution would probably want to test and change this in both places. - I only used the PlatformDeviceId package to replace the code in the Windows branch of that conditional. However it looks like that package does the same thing as the whole block, so it might be a good replacement for the entire thing
- I didn't look into how that
deviceIdis being used, though. If it's something that needs to be the same between AppFlowy versions (across updates) then replacing this code could cause issues. - I'm describing the issue and solution rather than forking and submitting a merge request because I didn't go through all the steps to get tests running or other forms of verification that I had the project set up right in the first place, and I don't have a working previous version I could compare against manually. Seems easier this way.
I had the same issue, and solved it this way: https://github.com/AppFlowy-IO/AppFlowy/issues/6979#issuecomment-2571743828
Try deleting %AppData%/io.appflowy (navigate to it quickly by using Run - WIN key + R)