Report forwarded to debian-bugs-dist@lists.debian.org, Ryan Murray <rmurray@debian.org>: Bug#364975; Package at.
(full text, mbox, link).
Acknowledgement sent to Stuart Scharf <ss@kashrut.com>:
New Bug report received and forwarded. Copy sent to Ryan Murray <rmurray@debian.org>.
(full text, mbox, link).
Subject: at command ignores savings time when given UTC time
Date: Wed, 26 Apr 2006 20:39:21 -0400
Package: at
Version: 3.1.10
at does not seem to recognize DST when computing the difference from UTC
and used the standard time difference instead.
ss@debian:/etc$ dpkg -l at
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Installed/Config-files/Unpacked/Failed-config/Half-installed
|/ Err?=(none)/Hold/Reinst-required/X=both-problems (Status,Err: uppercase=bad)
||/ Name Version Description
+++-==============-==============-============================================
ii at 3.1.10 Delayed job execution and batch processing
ss@debian:/etc$ cat timezone
America/New_York
ss@debian:/etc$ echo 'echo hi' | at 20:00 UTC
warning: commands will be executed using /bin/sh
job 2 at Thu Apr 27 15:00:00 2006
This should have been scheduled for 16:00:00.
Information forwarded to debian-bugs-dist@lists.debian.org, Ryan Murray <rmurray@debian.org>: Bug#364975; Package at.
(full text, mbox, link).
Acknowledgement sent to Håkon Stordahl <haastord@online.no>:
Extra info received and forwarded to list. Copy sent to Ryan Murray <rmurray@debian.org>.
(full text, mbox, link).
tags 364975 patch
thanks
The following patch seems to be the quick and dirty way to fix this
problem:
diff -Naur a/parsetime.y b/parsetime.y
--- a/parsetime.y 2005-08-05 03:31:04.000000000 +0000
+++ b/parsetime.y 2007-09-26 14:24:26.000000000 +0000
@@ -503,8 +503,8 @@
return 0;
if (isgmt) {
exectime -= timezone;
- if (currtm.tm_isdst && !exectm.tm_isdst)
- exectime -= 3600;
+ if (exectm.tm_isdst > 0)
+ exectime += 3600;
}
if (exectime < currtime)
panic("refusing to create job destined in the past");
However, I believe this isn't good enough. Skip to the next paragraph
unless interested in a lengthy discussion of why I think so.
The fix seems to work in almost all cases, but might fail in subtle
ways when 'at' is invoked just before a DST forward adjustment in the
spring. For example, in timezone +01:00 with DST changeover to +02:00
at 02:00, consider the time specification "00:00 UTC + 2 hours". This
will cause 'at' to schedule commands for execution at 03:00 (+02:00).
This seems incorrect, at least when considering that "00:00 UTC + 3 hours"
will cause 'at' to schedule commands to be executed at 05:00 (+02:00).
This problem seem somehow to be related to the way DST shifts are
accounted for in the function add_seconds in file parsetime.y.
Also, the code fails when DST is observed and the DST shift is
anything other than 1 hour, which seems to be the case in at least
some rare locations. (But, since the DST shift is user-configurable by
setting the TZ environment variable, I think that other DST shifts
should be supported for this reason as well.)
So, I have also included a patch which attempts to be independent from
whether DST is observed in the handling of UTC, by setting the TZ
environment variable to UTC while parsing and converting the time
specification. This is suggested by the glibc documentation (section
21.4.3) as the most portable way to convert "broken-down time" (struct
tm) in UTC to "simple time" (time_t).
Unfortunately this requires somewhat more complicated code. This
includes setting TZ to UTC as soon as the UTC token is encountered in
the parsing of the time specification. This seems to be required
because during the parsing, some functions which rely on the TZ
variable, like mktime, might get called. Setting TZ at this point has
the effect that, for example when 'at' is issued just before a DST
fall-back, the time specification "23:00 UTC + 10 hours" will not be
interpreted as if really 11 hours is to be added instead of 10 (to
account for the DST shift), which would have been the case had "UTC"
not been specified. I believe this behavior is reasonable.
Also, the location in the code where TZ is set relies on the
requirement (which by chance is satisfied) that the time of day part
of the time specification (which contains the UTC token if it is
present) must be parsed before the date part, because it seems to be
only for tokens in the date part that such functions are called.
There also is code to restore the original state of the TZ environment
variable when the parsing and conversion are done, so that for example
the commands scheduled by at won't be affected by the changes to TZ.
Tags added: patch
Request was from Håkon Stordahl <haastord@online.no>
to control@bugs.debian.org.
(Mon, 26 Nov 2007 21:51:10 GMT) (full text, mbox, link).
Added tag(s) confirmed.
Request was from ansgar@43-1.org (Ansgar Burchardt)
to control@bugs.debian.org.
(Tue, 24 Nov 2009 13:18:04 GMT) (full text, mbox, link).
Information forwarded
to debian-bugs-dist@lists.debian.org, Ansgar Burchardt <ansgar@43-1.org>: Bug#364975; Package at.
(Sat, 27 Mar 2010 14:30:04 GMT) (full text, mbox, link).
Acknowledgement sent
to mel pullen <mel@pullen.com>:
Extra info received and forwarded to list. Copy sent to Ansgar Burchardt <ansgar@43-1.org>.
(Sat, 27 Mar 2010 14:30:04 GMT) (full text, mbox, link).
Package: at
Version: 3.1.10.2
Followup-For: Bug #364975
today is Sat Mar 27 10:44:51 GMT 2010
zdump GMT shows:
GMT Sat Mar 27 10:45:26 2010 GMT
zdump UTC shows:
UTC Sat Mar 27 10:45:58 2010 UTC
cat /etc/timezone shows:
Europe/London
at commands using utc and localtime:
at 12:45 utc
warning: commands will be executed using /bin/sh
at> ls
at> <EOT>
job 383 at Sat Mar 27 11:45:00 2010
at 12:45
warning: commands will be executed using /bin/sh
at> ls
at> <EOT>
job 384 at Sat Mar 27 12:45:00 2010
-- System Information:
Debian Release: 5.0.4
APT prefers stable
APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.26-2-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/bash
Versions of packages at depends on:
ii exim4 4.69-9 metapackage to ease Exim MTA
(v4)
ii exim4-daemon-light [mail- 4.69-9 lightweight Exim MTA (v4)
daemon
ii libc6 2.7-18lenny2 GNU C Library: Shared libraries
ii libpam0g 1.0.1-5+lenny1 Pluggable Authentication
Modules l
ii lsb-base 3.2-20 Linux Standard Base 3.2 init
scrip
at recommends no packages.
at suggests no packages.
-- no debconf information
Information forwarded
to debian-bugs-dist@lists.debian.org, Ansgar Burchardt <ansgar@43-1.org>: Bug#364975; Package at.
(Thu, 17 Feb 2011 11:42:02 GMT) (full text, mbox, link).
Acknowledgement sent
to paolo@paolomontrasio.com:
Extra info received and forwarded to list. Copy sent to Ansgar Burchardt <ansgar@43-1.org>.
(Thu, 17 Feb 2011 11:42:02 GMT) (full text, mbox, link).
Information forwarded
to debian-bugs-dist@lists.debian.org, Ansgar Burchardt <ansgar@debian.org>: Bug#364975; Package at.
(Sun, 30 Oct 2011 09:57:03 GMT) (full text, mbox, link).
Acknowledgement sent
to Christoph Biedl <debian.axhn@manchmal.in-ulm.de>:
Extra info received and forwarded to list. Copy sent to Ansgar Burchardt <ansgar@debian.org>.
(Sun, 30 Oct 2011 09:57:04 GMT) (full text, mbox, link).
Paolo Montrasio wrote...
> The version of at included in Debian 6 contains the bug (at 3.1.12).
Same for 3.1.13-1, hit me due to the DST switch last night.
> Luckily the patch included in
> http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=364975#10 still
> works.
Quick workaround for me: "TZ=UTC at <timestamp>". Small side effect:
at's reply is in UTC, too. The next atq will show the queue in
localtime.
Could you please at least document this flaw in the manpage?
Christoph
Information forwarded
to debian-bugs-dist@lists.debian.org, Jose M Calhariz <jose@calhariz.com>: Bug#364975; Package at.
(Tue, 17 Jan 2017 12:51:02 GMT) (full text, mbox, link).
Acknowledgement sent
to Dmitriy Kovalkov <kovalkov@fastvps.ru>:
Extra info received and forwarded to list. Copy sent to Jose M Calhariz <jose@calhariz.com>.
(Tue, 17 Jan 2017 12:51:03 GMT) (full text, mbox, link).
Any news about this bug?
Problem exist in
Last in Arch:
[kovalkov@localhost ~]$ at -V
at version 3.1.19
Please report bugs to the Debian bug tracking system (
http://bugs.debian.org/)
or contact the maintainers (at@packages.debian.org).
Last in Ubuntu 16.04:
apt-cache policy at
at:
Installed: (none)
Candidate: 3.1.18-2ubuntu1
Version table:
3.1.18-2ubuntu1 500
500 http://ru.archive.ubuntu.com/ubuntu xenial/main amd64 Packages
Last in Debian 8:
root@repo:/# at -V
at version 3.1.13
Please report bugs to the Debian bug tracking system (
http://bugs.debian.org/)
or contact the maintainers (at@packages.debian.org).
---
Respectfully, Dmitrii Kovalkov
FASTVPS technical department
Information forwarded
to debian-bugs-dist@lists.debian.org: Bug#364975; Package at.
(Wed, 18 Jan 2017 21:12:02 GMT) (full text, mbox, link).
Acknowledgement sent
to Jose M Calhariz <jose@calhariz.com>:
Extra info received and forwarded to list.
(Wed, 18 Jan 2017 21:12:02 GMT) (full text, mbox, link).
Thank you for pointing me out this defect. I will review it at first
opportunity.
Kind regards
Jose M Calhariz
On 17/01/17 12:47, Dmitriy Kovalkov wrote:
> Any news about this bug?
>
> Problem exist in
>
> Last in Arch:
>
> [kovalkov@localhost ~]$ at -V
> at version 3.1.19
> Please report bugs to the Debian bug tracking system (
> http://bugs.debian.org/)
> or contact the maintainers (at@packages.debian.org).
>
> Last in Ubuntu 16.04:
>
> apt-cache policy at
> at:
> Installed: (none)
> Candidate: 3.1.18-2ubuntu1
> Version table:
> 3.1.18-2ubuntu1 500
> 500 http://ru.archive.ubuntu.com/ubuntu xenial/main amd64 Packages
>
> Last in Debian 8:
>
> root@repo:/# at -V
> at version 3.1.13
> Please report bugs to the Debian bug tracking system (
> http://bugs.debian.org/)
> or contact the maintainers (at@packages.debian.org).
>
> ---
> Respectfully, Dmitrii Kovalkov
> FASTVPS technical department
>
Information forwarded
to debian-bugs-dist@lists.debian.org, Jose M Calhariz <calhariz@debian.org>: Bug#364975; Package at.
(Thu, 18 Jul 2019 03:57:02 GMT) (full text, mbox, link).
Acknowledgement sent
to Jose M Calhariz <jose.calhariz@tecnico.ulisboa.pt>:
Extra info received and forwarded to list. Copy sent to Jose M Calhariz <calhariz@debian.org>.
(Thu, 18 Jul 2019 03:57:02 GMT) (full text, mbox, link).
Hi,
I am working in a new release of at daemon and I have incorporated
your second patch. Are you interested in reviewing the code and the
if fixed the problem?
Kind regards
Jose M Calhariz
--
--
Modems de 2400, por favor transitar na pista a direita.
Source: at
Source-Version: 3.2.2-1
Done: Jose M Calhariz <calhariz@debian.org>
We believe that the bug you reported is fixed in the latest version of
at, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to 364975@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Jose M Calhariz <calhariz@debian.org> (supplier of updated at package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmaster@ftp-master.debian.org)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Format: 1.8
Date: Sun, 25 Apr 2021 18:36:34 +0100
Source: at
Architecture: source
Version: 3.2.2-1
Distribution: experimental
Urgency: medium
Maintainer: Jose M Calhariz <calhariz@debian.org>
Changed-By: Jose M Calhariz <calhariz@debian.org>
Closes: 364975519716792040863045
Changes:
at (3.2.2-1) experimental; urgency=medium
.
* New release 3.2.2
* Jose M Calhariz
- Add helper script batch-job
* New release 3.2.1
* Jose M Calhariz
- Include config.h on parsetime.l, see
88a3bed41de234220f007c785e3aa45bd62446c6 for more info and
original author.
- Check if libc provides __isleap() macro, see
02a0a98d94b24284177dad7747edbdc3088d63cd
* New release 3.2.0:
* Jose M Calhariz
- Print time of new job before the input of the commands,
(Closes: #863045)
- Do not drop seconds on -t option, (Closes: #792040)
- Start using nice levels from 0 instead of 2. (Closes: #519716)
- Correctly handle DST when specifying a UTC time. (Closes: #364975)
* Gerhard Poul:
- Add flag to send email to other user. MR 5
* Clean patches directory.
* Update Build-Depends, silent lintian warning.
* Add public PGP of upstream aka myself.
* Update debian/watch.
* Bump Standards-Version to 4.3.0, no changes were made.
* Acknowledge the NMU and incorporated the changes.
Checksums-Sha1:
3bb54156b90bd2d406167c8e82b70af665174084 2147 at_3.2.2-1.dsc
aa91f5ed2b292a54442f83ecce92a2ff52067ce5 127677 at_3.2.2.orig.tar.gz
51007e6dcd0ed120f59cdc0e7d8ca37fa9500226 833 at_3.2.2.orig.tar.gz.asc
00d5fe0844844ad5f93ada8ce9d16919e5a47e6a 20016 at_3.2.2-1.debian.tar.xz
c00fc34d58e0ecb4f79a6cb48d8b9feb0ef31ebf 6059 at_3.2.2-1_amd64.buildinfo
Checksums-Sha256:
ed77f8a716ba7e70c1f999b26a322910f71fe54ac0eab138a49ba7fb327d2f17 2147 at_3.2.2-1.dsc
2211da14914fde1f9cc83592838fb6385a32fb11fcecb7816c77700df6559088 127677 at_3.2.2.orig.tar.gz
c7226ed1f413e9fd01f5c0e422f7f2bf2897df95209e8bd7f0feba5df56f0d90 833 at_3.2.2.orig.tar.gz.asc
b94d3f7c017f19e4fc07d0c5fcad287a9f103870c55621325eafa808b2534d5c 20016 at_3.2.2-1.debian.tar.xz
1aea283b3fb7f10de77c0ba421dca9e7d1129c33750e106a332fe624ee79d142 6059 at_3.2.2-1_amd64.buildinfo
Files:
421fb3577bd1f800da325f0c4d99a2f5 2147 admin standard at_3.2.2-1.dsc
34c379193bb020f39efa021ac651d475 127677 admin standard at_3.2.2.orig.tar.gz
1804a48980acfa78e5c1a5ac6220d8ae 833 admin standard at_3.2.2.orig.tar.gz.asc
6487a58baaaeaa2aa05237df248e99a0 20016 admin standard at_3.2.2-1.debian.tar.xz
5c5f710a21e3b78b5cacd88d7cbe79f5 6059 admin standard at_3.2.2-1_amd64.buildinfo
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCAAdFiEERkvHzUOf7l6LQJigNIp3jWiF748FAmCFuU8ACgkQNIp3jWiF
74/MGQ/+OxeYSw1YBtc1hYnLFc+UQvpB/dgjAT7fuSdZXJ9RiF9A29diES7dtQyE
2Hpv+QfGLLpiu09uja8d2M/aepoMXaY7tImn8be7/5+VpKOifPOWdBH5IOosEOkL
ibfBQXQMFDGgJCzV15Dr7KN42fxnWU7aZTpUFcEKU8VdsW00XQCiYffOLrTZeSf3
LkQ0qSWS0ZGTv5MWb8pllCfHoGsMEmIVPawgv0EAP/oCsEDdOxHXxOsGNMjzviSD
YD26imz8fm/zhzrk+BpSMPQCIPv6VCcgxD8MYRnlCQWySD12HFRHCM22lYt1CIxD
y5DTR5zqSb+cADuAe+vAeA9O+mI3cTyNkEwrzKQUsqO8dEerloz7H0gfzyIUhyYB
jygB11IIzPUrA9CJGelfu3vOFCu5OqZq93uzrthUM7UF/KWzvBl2pjp0UZJUWr6w
FSJVplotzjxGUwHPUkGS6RWA5oA5PVIRNdFNTogl/XUL094re8m8SoBhhCcgaanh
w+binDkp+p4rK+aQGN9KDBekyQ31ftWI8nW7o0+81qG6bRz2KSoZUbaEzpAfkJ4r
r31/SMDCLfL6IzNjNaucFFyszfbBUznvZtz539A10Ckita63gwB6oR5R6LAIV9zs
LaZPcAswYBJbCBHSNr7qCEgdcTBrweLUN5MI//6LHMPuBgGKoA0=
=ePdg
-----END PGP SIGNATURE-----
Bug archived.
Request was from Debbugs Internal Request <owner@bugs.debian.org>
to internal_control@bugs.debian.org.
(Mon, 07 Feb 2022 07:29:33 GMT) (full text, mbox, link).
Debbugs is free software and licensed under the terms of the GNU
Public License version 2. The current version can be obtained
from https://bugs.debian.org/debbugs-source/.