Re: integer value too large?



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

.



Relevant Pages

  • Re: integer value too large?
    ... Also you probably dont want the but but this is ... impossible to say without knowing what ... ... Can you put the whole script (or a couple of lines around this command ...
    (comp.lang.tcl)
  • Re: Help understanding a script
    ... never knowing this. ... Any whoo still dont understand script. ...
    (comp.lang.php)
  • Re: integer value too large?
    ... it the whole script is too large) to give us some more info as to why ... A span of about 8 months was converted to milliseconds. ... string is integer $wait_time ... extends the range of ms to 2^64-1 which would allow you to schedule ...
    (comp.lang.tcl)
  • Re: Is it possible to fasten the import of cgi?
    ... My script itself takes 3 or 4 milliseconds. ... Does the hosting provider support fastcgi? ... python scripts had to wait for one and a halve week.) ...
    (comp.lang.python)
  • Re: time manipulation getting invalid times
    ... Initially I was using the round function from Math::Round ... Turned out it was when the seconds were 59 and the milliseconds were ... Does anybody see any errors with me using this method (int) ... If your script 'deals' with milliseconds then why round or disregard them? ...
    (comp.lang.perl.misc)