Re: integer value too large?
- From: Mark Janssen <mpc.janssen@xxxxxxxxx>
- Date: 28 Apr 2007 15:10:28 -0700
On Apr 29, 12:02 am, Mark Janssen <mpc.jans...@xxxxxxxxx> wrote:
On Apr 28, 11:34 pm, tickle007 <tickle_b...@xxxxxxxxx> wrote:
On Apr 28, 5:00 pm, Mark Janssen <mpc.jans...@xxxxxxxxx> wrote:
What is your Tcl version? If it is 8.4 the value in $wait_time might b
too large. Also you probably dont want the [...] but {...} but this is
impossible to say without knowing what ... is.
Can you put the whole script (or a couple of lines around this command
it the whole script is too large) to give us some more info as to why
it fails?
This is on an ActiveState 8.4 version of Tcl on Windows XP.
Apparently, the value in the "after" amount is too big. We traced the
error. A span of about 8 months was converted to milliseconds. This
was first seen by a QA analyst where they are supposed to enter a few
minutes, but they entered a few months.
Is there a limit on how frequently after the command works?
There is no (imposed) limit on the frequency of after, there is
however a limit on the maximum of milliseconds you can specify for
after. The actual limit depends on your system (32 or 64 bit)
You can check in your script if the number is within limits for
validation, by using
string is integer $wait_time
which will return 1 if the value is in range. On my system the max
number of milliseconds is 2^32-1 (which equals approximately 50 days).
Mark
I forgot to mention that in 8.5 the range has been extended to a wide
integer (which can be checked by [string is wideinteger]) which
extends the range of ms to 2^64-1 which would allow you to schedule
events after the big crunch.
Mark
.
- Follow-Ups:
- Re: integer value too large?
- From: Mark Janssen
- Re: integer value too large?
- References:
- integer value too large?
- From: tickle007
- Re: integer value too large?
- From: Mark Janssen
- Re: integer value too large?
- From: tickle007
- Re: integer value too large?
- From: Mark Janssen
- integer value too large?
- Prev by Date: Re: integer value too large?
- Next by Date: Re: integer value too large?
- Previous by thread: Re: integer value too large?
- Next by thread: Re: integer value too large?
- Index(es):
Relevant Pages
|