emericg / WatchFlower

A plant monitoring application that reads and plots data from compatible Bluetooth sensors and thermometers like Xiaomi 'Flower Care' or Parrot 'Flower Power'
https://emeric.io/WatchFlower
GNU General Public License v3.0
195 stars 29 forks source link

WatchFlower.exe just hangs with a blank screen #47

Closed Stan-Gobien closed 3 years ago

Stan-Gobien commented 3 years ago

Describe the bug The program worked fine for a couple of weeks. Now since a couple of days it won't open anymore. The program starts to the Windows tray, but on right click "show" or "settings" a blank screen open with the title "Watchflower (not responding)" and just hangs. Waited a couple of minutes but no success. Taskmanager shows WatchFlower.exe with a constant 6% CPU (16T CPU, shows 1 thread almost at max constantly) and a steady 85.224KB RAM with no change. Seems like it's stuck in some kind of loop.

Expected behavior I expected the program to open. It worked (sort of) fine for a couple of weeks.

To Reproduce Don't know how to reproduce on your system

Screenshots afbeelding

afbeelding

afbeelding

Your environment Windows 10 x64 21H1 AMD Ryzen 7 3700X / 32GB RAM / SSD storage Watchflower 2.1 x64 for windows zip from the site

Additional context I tried renaming the "DB" file in %AppData%\WatchFlower and a new database is created but the problem is not solved.

Stan-Gobien commented 3 years ago

And ofcourse, after submitting the bug report I decide to check if WatchFlower saves settings in the Windows Registry. Computer\HKEY_CURRENT_USER\SOFTWARE\WatchFlower Deleted the Key, and sure enough the program starts again.

So problem solved (for now).

Stan-Gobien commented 3 years ago

Problem has reappeared now (the next day) when I start up my computer.

Deleted the reg key again, and works again.

emericg commented 3 years ago

Hi. This is a bit weird given nothing has changed on WatchFlower side, but why not, with Windows you never know...

Can you try the newest version first: https://ci.appveyor.com/project/emericg/watchflower There are some changes on the code that handle multiple launches (but maybe it's worse now :p)

Otherwise, to try and pinpoint what's wrong, can you try deleting only a couple of register keys from the WatchFlower folder? All of the keys from ApplicationWindow/x,y, width, hieght, visibility... can have an impact on startup. Maybe settings/startMinimized and settings/trayEnabled). The others, very unlikely ...

emericg commented 3 years ago

A more direct link to download the latest version: https://ci.appveyor.com/project/emericg/watchflower/build/artifacts

Stan-Gobien commented 3 years ago

It was working today without issues. Nevertheless, I updated to the latest build using your link.

emericg commented 3 years ago

Alright keep me posted if anything else happens.

emericg commented 3 years ago

Please re-open this issue if you have any new informations.

Stan-Gobien commented 3 years ago

Seems to work Ok now.

Stan-Gobien commented 2 years ago

Happens again. afbeelding

Watchflower remember the last position, on my secondary screen but hangs when I open it by double clicking on the tray icon (autostart).

Stan-Gobien commented 2 years ago

I looked at the registry key "HKEY_CURRENT_USER\SOFTWARE\WatchFlower\WatchFlower\ApplicationWindow" The value for x was fffff9ee The value for y was ffffffff

I set both values to 0 and now Watchflower opens fine on my primary screen.

I dragged the window back to the approximate same location on my secondary screen and closed the window. The registry hex values for x and y are updated with new values (x = fffff66b; y = a7). I closed the window and try to reopen by double click, it hangs again.

Reset values for width and height, instead of x and y -> no success. Reset values for x and y again -> succes.

I'll now leave the program on my primary monitor to see if it happens as well.

Another important factor. My secondary monitor is on the left of my primary monitor, which is why the coordinates are negative to 0,0 position.

emericg commented 2 years ago

Ok thanks for the detailed feedback, that is very valuable information! I'll see if I can test on a second monitor, but I can already check the code for a few things related to that now.

I'll let you know what I find.

Stan-Gobien commented 2 years ago

So far it's working fine on my primary screen.