-
Notifications
You must be signed in to change notification settings - Fork 43
Closed
Description
netcdftime.datetime objects constructed directly don't have the correct day of year or day of week; they always give a value of 1 and -1 respectively. Objects returned by utime.num2date have the correct values, except for those with Julian calendars, which still have the issue.
>>> import netcdftime
>>> print netcdftime.__version__
1.4.1
>>> date = netcdftime.DatetimeNoLeap(2000, 1, 2)
>>> print repr(date)
netcdftime._netcdftime.DatetimeNoLeap(2000, 1, 2, 0, 0, 0, 0, -1, 1)
>>> print date.dayofyr
1
>>> print date.dayofwk
-1
Python version: 2.7
netdf4 version: 1.2.7
Installed via conda forge.
Metadata
Metadata
Assignees
Labels
No labels