breaktimer-app icon indicating copy to clipboard operation
breaktimer-app copied to clipboard

Stuck on "Next break in less than a minute"

Open olshevski opened this issue 1 year ago • 21 comments

Since updating from Monterey to Ventura 13.1 BreakTimer doesn't show breaks after the system sleep. In the menu it just shows "Next break in less than a minute", but the break never starts not after a minute, nor in a longer time. Even if I press "Start break now" nothing happens.

If I relaunch the app, it starts showing breaks, but after the first sleep (the longer one, e.g. overnight), it seems to never be working.

olshevski avatar Jan 16 '23 12:01 olshevski

This happens to me as well. The app appears to get stuck when attempting to initiate the pause. Indeed, restarting the app does solve the problem.

Also, nothing gets written to the logs at this points, so there's little debugging information available.

Edit: One day later, the machine has been sleeping all night and today the problem didn't manifest. I'll keep looking for how to repro the issue.

letharion avatar Jan 26 '23 11:01 letharion

Today I noticed again the app doesn't start any breaks, and it's stuck in "Next break in less than a minute"-state.

The last few logs sadly don't help much:

[2023-02-06 13:20:02.596] [info] GONG_START_PLAY [2023-02-06 13:20:02.596] [info] Send event GONG_START_PLAY [] [2023-02-06 13:20:02.598] [info] BREAK_LENGTH_GET [2023-02-06 13:41:09.697] [info] GONG_START_PLAY [2023-02-06 13:41:09.698] [info] Send event GONG_START_PLAY []

letharion avatar Feb 08 '23 07:02 letharion

+1 to this happens to me too.

adrianh avatar Feb 08 '23 10:02 adrianh

If the app ever gets into that state, quitting and reopening will fix it.

tom-james-watson avatar Feb 08 '23 11:02 tom-james-watson

+1 to this happening to me too on Ventura 13.3.1.

It seems to be inconsistent, like sometimes it gets stuck, sometimes it doesn't. I have my MacBook Pro with its shell closed all the time and plugged to a docking station delivering power, and it usually keeps working normally. Went for launch for circa 1 hour locking the screen and then the problem happened again. Over night it happens often too. Otherwise working like a charm. If I lock the screen for shorter periods it keeps working correctly

kristiannotari avatar Apr 17 '23 14:04 kristiannotari

Another "me too". I've randomly had this issue, though not as much recently. I've seen no pattern to it.

torpesco avatar Apr 19 '23 18:04 torpesco

In a similar discussion I had to check the "prevent Mac from sleep when display is off" option under screens -> advanced. You can read more about that here: https://github.com/tom-james-watson/breaktimer-app/discussions/222#discussioncomment-5670616

Hopefully this helps to solve this issue too when dealing with docked Macs for long times, not sure about overnight though.

kristiannotari avatar Apr 20 '23 08:04 kristiannotari

For what it's worth I also use the composer primarily docked and with the lid closed at all times, which might mean the sleeping happens a lot.

letharion avatar Apr 21 '23 05:04 letharion

The app did this to me today. It was working on Friday. I don't think I've had a break reminder today. Is there some kind of diagnostics I could gather when this happens? Process samples using Activity Monitor, or anything else?

torpesco avatar Apr 24 '23 22:04 torpesco

I have the same issue, it works for some time and then gets stuck in "Next break in less than a minute" state.

cletter7 avatar Apr 25 '23 06:04 cletter7

This is regularly happening to me too.

ershov avatar Jun 13 '23 08:06 ershov

+1 on this issue. If I inspect the last few lines of the log,

[2023-06-21 11:53:50.748] [info]  BREAK_POSTPONE
[2023-06-21 12:18:58.057] [info]  ALLOW_POSTPONE_GET
[2023-06-21 12:18:58.080] [info]  SETTINGS_GET
[2023-06-21 12:18:58.085] [info]  ALLOW_POSTPONE_GET
[2023-06-21 12:18:58.107] [info]  GONG_START_PLAY
[2023-06-21 12:18:58.109] [info]  Send event GONG_START_PLAY []
[2023-06-21 12:18:58.111] [info]  BREAK_LENGTH_GET
[2023-06-21 12:38:59.337] [info]  GONG_START_PLAY
[2023-06-21 12:38:59.340] [info]  Send event GONG_START_PLAY []
[2023-06-21 17:31:24.974] [info]  SETTINGS_GET

Notice the large period of inactivty between 12:38 and 17:31. I had left my Mac to get lunch, so the display presumably turned off and it automatically went to sleep. I returned and continued working only a few minutes after the display (and probably Mac itself) went to sleep, but it got stuck in the "Next break in less than a minute" state, and the next break never initiated, and I did not notice until 5pm in the day. I clicked various buttons, including Disable, Enable, Restart break period, and Start break now, all before clicking Settings. As seen in the logs, only the settings button triggered any log actions. When I clicked Disable in this bugged state, the screen would still display the "time until next break" as "less than a minute" rather than completely removing all the aforementioned buttons and the time until next break.

wuwendell avatar Jun 22 '23 00:06 wuwendell

Hi, A little update on the issue here.

I've installed the Break Timer on another Mac (Pro, M1) with the latest OS and it works like a charm. That's while it's consistently getting stuck on my Air M2.

Any ideas where to look at to compare what's different on these two machines?

ershov avatar Jun 29 '23 05:06 ershov

Can confirm I also have the M2 chip Mac.

wuwendell avatar Jun 29 '23 21:06 wuwendell

Facing the same issue :(

MacBook Pro 16" with M1 Pro chip MacOS Ventura 13.4.1

bovae avatar Jul 21 '23 09:07 bovae

same here mac pro 13" i7 OS Sonoma v14

this might be related https://github.com/electron/electron/issues/4465

also turns out you need to reset the timer using these hooks

I see it's used in the code but looks like to monitor that you are "away" not to reset the timer

eyalyoli avatar Dec 19 '23 18:12 eyalyoli

I would suggest adding under app ready event this part:

...
import { BreakTime, tickInterval } from "../../types/breaks";
...

app.on('ready', () => {
   ...
  electron.powerMonitor.on('suspend', () => {
    clearInterval(tickInterval);
  });
  electron.powerMonitor.on('resume', () => {
    initBreaks();
  });
  ...
})

eyalyoli avatar Dec 19 '23 19:12 eyalyoli

same here

MacBook Pro 14" with M2 Pro chip MacOS Sonoma 14.1.2

Fl0rent avatar Dec 21 '23 08:12 Fl0rent

MacBook Pro 14" with M1 Pro chip MacOS Sonoma 14.1.2

Also with the same issue; restarting the app does the trick but it'll get stuck the next day or so

NourMaka avatar Feb 22 '24 15:02 NourMaka

Same here. BreakTimer works once, but subsequent times it is stuck on the "less than a minute" indicator. Cannot force a break.

Zorin OS 17 Core (Ubuntu-based)

Update: it is stuck now at

image

happydutch avatar Mar 04 '24 19:03 happydutch

This issue occurs for me on a Lenovo T14s running Windows 11. The break timer is stuck in "Next break in less than one minute" indefinitely.

lhalbers avatar Apr 18 '24 13:04 lhalbers