emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Tim Cross <theophilusx@gmail.com>
To: Allen Li <vianchielfaura@gmail.com>
Cc: emacs-orgmode@gnu.org, Nicolas Goaziou <mail@nicolasgoaziou.fr>
Subject: Re: Bug: org-2ft and/or float-time is wrong [9.1.2 (9.1.2-22-ga2a034-elpaplus @ ~/.emacs.d/elpa/org-plus-contrib-20171023/)]
Date: Thu, 02 Nov 2017 15:56:16 +1100	[thread overview]
Message-ID: <874lqdth1r.fsf@gmail.com> (raw)
In-Reply-To: <CAJr1M6fcoo8y7m90H4iWEZ1CO-xeMPq8hTLwicjfiDMQ6VFOww@mail.gmail.com>


OK, thanks for the additional information. That helps a lot.

We can now narrow down where the issue is.

After having looked (only very casually) at some of the org date/time
related functions, I think there may be quite a few issues. I'm not
convinced the root cause is org-2ft converting to UTC, though I think
that change has probably revealed some of the issues.

There does seem to be some inconsistency or lack of clarity regarding
some of these operations and it could well be that the switch to using
UTC is not the correct approach, but just switching back probably isn't
either What does appear to be required is increased consistency in some
of these functions or where/how they are used. .

To correctly fix this, I feel more analysis is warranted. I'm prepared
to look at this and present a summary and options, but it will have to
wait until after 21st when I start leave from work. It is a complex area
and perhaps my skills won't be up to it, but I should at least be able
to identify the main areas needing attention/decisions. 

Whether we should change back to non-UTC for time comparisons in the
meantime is not something I feel informed enough to make a call. It
really depends on the daylight savings time related issues affecting
clock tables and other functionality.  This is probably something core
org maintainers will need to make a call on.

Tim


Allen Li <vianchielfaura@gmail.com> writes:

> On Wed, Nov 1, 2017 at 8:27 PM, Tim Cross <theophilusx@gmail.com> wrote:
>>
>> I get that, what I am not clear about is where you encounter this issue
>> when using org .eg. is it when entering now as a date for generating an
>> agenda of past or current scheduled items etc or is this a problem with
>> some custom functions you have written where you need to enter 'now'
>> manually and due to the use of UTC in time comparisons are forced to
>> adjust manually for UTC or something else? This is what is not
>> clear. From my own use, I don't see the issue you describe with
>> scheduled items not appearing or appearing when they shouldn't, so don't
>> know how to reproduce the issue your having i.e. when I do agenda
>> searches, I don't see deadline or scheduled items showing up when they
>> should not etc.
>
> It is when doing any kind of tag search.  So org-agenda, mostly.
>
> I'm not surprised you cannot reproduce it because it is dependent on
> your local timezone.
>
>>
>> This matters because if the issue is the former, then we likely do have
>> a real bug. However, if it is the latter, then it may be a bug or it may
>> be just an implementation weakness or it could just be a difference of
>> opinions on how it should be.
>>
>> Your examples don't clarify what the issue is. It is obvious that if we
>> convert times to UTC for calculation purposes that this will affect the
>> display of those timestamps, but as far as I can tell, org doesn't
>> convert back and use those converted values in any visible way. Provided
>> all values are converted consistently, it should not matter. Therefore,
>> if there is a problem, then something must not be getting converted
>> correctly, but it is not possible to narrow down where this is without
>> more info.
>
> Ah, perhaps I should make the issue clearer.
>
> When I run this at 2017-11-01 20:55:30
>
> (org-2ft "<now>")
> 1509594900.0
>
> (org-2ft "<2017-11-01 20:55:30>")
> 1509569700.0
>
> Therefore when org.el does a tag search for SCHEDULED="<now>", it will
> not match <2017-11-01 20:55:30>, assuming that I have frozen my system
> clock to that time.
>
>>
>> If you can provide an ECM then we can avoid assumptions and different
>> interpretations and focus on the issue.
>
> Again, this is dependent on your local time zone.  Try setting your
> time zone to America/Los_Angeles.
>
> 1. emacs -Q
> 2. Assume it is 2017-10-10 12:00:00 local time
> 3. Create an agenda file
>
> * TODO thing
> SCHEDULED:<2017-10-10 13:00:00>
>
> 4. M-x org-agenda RET m SCHEDULED>"<now>"
>
> Expected:
>
> thing shows up
>
> Actual:
>
> thing does not show up
>
>>
>> Tim
>>
>> --
>> Tim Cross


-- 
Tim Cross

  parent reply	other threads:[~2017-11-02  4:56 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-31  0:40 Bug: org-2ft and/or float-time is wrong [9.1.2 (9.1.2-22-ga2a034-elpaplus @ ~/.emacs.d/elpa/org-plus-contrib-20171023/)] Allen Li
2017-10-31  4:33 ` Allen Li
2017-10-31 18:23   ` Nicolas Goaziou
2017-10-31 18:35     ` Allen Li
2017-10-31 18:52       ` Nicolas Goaziou
2017-11-01  5:07         ` Allen Li
2017-11-01  5:41           ` Tim Cross
2017-11-01  6:26             ` Allen Li
2017-11-01  7:18               ` Tim Cross
2017-11-01  8:28                 ` Allen Li
2017-11-01 13:09                   ` Tim Cross
2017-11-01 19:14                     ` Allen Li
2017-11-01 19:21                       ` Allen Li
2017-11-02  0:09                         ` Tim Cross
2017-11-02  0:26                           ` Allen Li
2017-11-02  3:27                             ` Tim Cross
2017-11-02  4:05                               ` Allen Li
2017-11-02  4:28                                 ` Allen Li
2017-11-02  4:49                                   ` Allen Li
2017-11-02  4:56                                 ` Tim Cross [this message]
2017-11-02  5:12                                   ` Allen Li
2017-11-02 16:19                                     ` Nick Dokos
2017-11-02 19:56                                     ` Tim Cross
2017-11-01 20:55           ` Nicolas Goaziou
2017-11-02  0:10             ` Allen Li
2017-11-02  9:35               ` Nicolas Goaziou
2017-11-02 11:12                 ` Tim Cross

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=874lqdth1r.fsf@gmail.com \
    --to=theophilusx@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    --cc=mail@nicolasgoaziou.fr \
    --cc=vianchielfaura@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).