Page 1 of 1

Dates issue at end of year 2020

PostPosted: Fri Jan 01, 2021 1:12 pm
by wxPhil
I noticed an issue when looking at the "Last modified" (LM) dates in a number of FTP clients on a number of servers - and by a preocess of elimination I am coming to the conclusion the problem liklely lies with the way Ability FTP is returning these dates.

Yesterday, 31-Dec-2020 any file I uploaded had the LM date given as 01-Jan-2020 (should have been 31-Dec-2020), though the time part was correct.

Today, the LM date is correct for any file uploaded today, but yesterdays' files now show today's date - 01-Jan-2021 (again, instead of 31-Dec-2020)

Older files have the correct LM date, but all the time parts are now set to 00:00

Logging in to the servesr via remote desktop shows all dates /times are correct there.

Any clues?

Re: Dates issue at end of year 2020

PostPosted: Sat Jan 02, 2021 11:16 am
by Code Crafters
If the server dates are all correct then it could be your FTP client that's not converting these to local time. Are your FTP clients on a different time zone to your server?

Re: Dates issue at end of year 2020

PostPosted: Sat Jan 02, 2021 11:22 am
by wxPhil
I've used a couple of different clients, with the same result, and two colleagues I checked with report the same thing. And no - all clients and servers are on the same time zone settings. Hence my suspicion that it's the ftp server at the ehart of the issue.

This issue appears to only affect files uploaded on 31-Dec-2020, where the LM date is (still) showing as 01-Jan-2020 - all others are ok.

Are you able to reproduce this? Filezilla client is one fo the FTP clients we've seen this with.

Re: Dates issue at end of year 2020

PostPosted: Sat Jan 02, 2021 11:34 am
by wxPhil
Not quite - files uplaoded 31-Dec-2020 are now showing an LM date of 01-01-2021 - on 31-Dec-2020 they were showing 01-01-2020.

It seems as though a DayOfYear function is being used and not taking into account the Leap Year - so day 366 is being read as Day 1 ....

Re: Dates issue at end of year 2020

PostPosted: Mon Jan 04, 2021 10:21 am
by Code Crafters
Thanks for that info. We'll add it as a bug and investigate further. Hopefully we can fix this easily and put out an update for it in the near future. Are all other days uploaded with the right created and modified dates?

Re: Dates issue at end of year 2020

PostPosted: Mon Jan 04, 2021 2:24 pm
by wxPhil
The dates of other files seem ok, but I see that all files uploaded over a week ago have the time part set to 00:00 - though if I go far enough abck, to 25/10 (the date DST ended?) I see the time part is 01:00 - but files uploaded within the last week have teh correct time part. Weird...!