taskGNU Astronomy Utilities - Tasks: task #15555, Account for timezone in date...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

task #15555: Account for timezone in date strings in --datetosec

Submitted by:  Mohammad Akhlaghi <makhlaghi>
Submitted on:  Sat 22 Feb 2020 10:01:40 PM UTC  
 
Should Start On:  Sat 22 Feb 2020 12:00:00 AM UTC Should be Finished on:  Sat 22 Feb 2020 12:00:00 AM UTC
Category:  Fits Priority:  5 - Normal
Item Group:  Crash Status:  None
Privacy:  Public Percent Complete:  10%
Assigned to:  None Open/Closed:  Open
Effort:  0.00

Wed 20 May 2020 07:47:10 PM UTC, comment #2: 

Antonio Diaz Diaz suggested consulting Paul Eggert (who is the coordinator for the IANA time-zone database, and a GNU fellow).

Mohammad Akhlaghi <makhlaghi>
Project Administrator
Sun 23 Feb 2020 01:31:24 AM UTC, comment #1: 

Part of the job has been implemented and pushed to the main repository.

The implemented part is the `Z' character at the end of the date-time string. According to the w3.org standard, when its present in effect, it just means that the timezone is zero (or the time is in UTC). So this part was pretty easy to implement.

The second part is also easy (to parse the timezone `+hh:mm' or `-hh:mm' and add it to the `tp->tm_gmtoff' (see the GNU C library for more on this). But the complication is that the FITS standard also allows sub-second times (with a decimal point in the seconds). So we also have to account for that.

Mohammad Akhlaghi <makhlaghi>
Project Administrator
Sat 22 Feb 2020 10:01:40 PM UTC, original submission:  

The FITS standard's definition of the DATE keyword includes the following format: `YYYY-MM-DDThh:mm:ss', assuming the time is in UTC.

However, beyond the FITS standard, in the larger community there is also the option to add timezone information, for example with a `Z' in the end of the date string.

Although its not in the standard, some date writers may implement this extra piece of information in the string. So we should also be able to read and implement it (apply the timezone and finally return the seconds in UTC).

Mohammad Akhlaghi <makhlaghi>
Project Administrator

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by makhlaghi (Submitted the item)
  • -email is unavailable- added by makhlaghi
  • -email is unavailable- added by makhlaghi
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2020-02-23 makhlaghi Percent Complete0% => 10%
    2020-02-22 makhlaghi Carbon-Copy- => Added zahra.sharbaf2@gmail.com
        Carbon-Copy- => Added surenaftm@gmail.com

    Back to the top


    Powered by Savane 3.5