Skip to content
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

Issue with [timer] #808

wilkowy opened this Issue Mar 6, 2019 · 1 comment


None yet
1 participant
Copy link

wilkowy commented Mar 6, 2019

Code: .tcl timer 1 [list putlog "done 1m"] ; timer 2 [list putlog "done 2m"] ; utimer 60 [list putlog "done 60s"] ; utimer 120 [list putlog "done 120s"] ; putlog "start"


[06/01:19:42] start
[06/01:20:00] done 1m
[06/01:20:41] done 60s
[06/01:21:00] done 2m
[06/01:21:41] done 120s

Is that a correct behaviour? The minute [timer] executes not after 1 minute since execution, but on the first full minute (:00) and then every minute from that. [utimer] works ok. The docs does not say about such weird behaviour.

The ban timer is also affected, but a bit different (better):

.tcl newchanban #***** "xxx!yyy@zzz" "test" "no reason" 1 "sticky"

01:33:37 -!- mode/#***** [+b xxx!yyy@zzz] by *****
01:35:01 -!- mode/#***** [-b xxx!yyy@zzz] by *****
01:35:27 -!- mode/#***** [+b xxx!yyy@zzz] by *****
01:37:02 -!- mode/#***** [-b xxx!yyy@zzz] by *****

As you can see it waits till the full minute and than it counts an 1 minute expiration.

The ban issue is acceptable as it waits at least minute, but [timer] can execute just few seconds after calling it - this makes them quite useless.

At least you should fix the docs to mention this issue as now it states "Description: executes the given Tcl command after a certain number of minutes have passed.". After and that means first interval as well.

It happens on 1.8.4 and 1.6.21.


This comment has been minimized.

Copy link

wilkowy commented Mar 6, 2019

OK, now I see in code core_secondly/core_minutely that [timer]s are broken by-design and are useless for shorter intervals (1 minute timer is always less than 60 seconds).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.