Departures.csv feed "lateness" column is reporting the same values for the "scheduled" column

54 views
Skip to first unread message

Eric

unread,
May 27, 2016, 7:00:37 PM5/27/16
to MBTA Developers
I noticed the feed came back online a few hours, but the lateness column is quite wrong. See attached.
Departures (1).csv

Ryan Hurley

unread,
May 31, 2016, 12:51:52 PM5/31/16
to MBTA Developers
This is affecting my iOS app as well. The lateness column is still showing the wrong values. 

Developer at MBTA

unread,
May 31, 2016, 2:00:52 PM5/31/16
to MBTA Developers
Hello all,

We apologize for this problem with the departures board feed. We are working on a fix for it.

Sincerely,

Developer@MBTA

Eric

unread,
Jun 1, 2016, 4:32:04 PM6/1/16
to MBTA Developers
Is there an eta on this?

StefanW

unread,
Jun 1, 2016, 5:36:04 PM6/1/16
to MBTA Developers
In case this helps in the meantime (while they are still working on the fix)...

When the .csv comes up with UNIX epoch time in the Lateness column, it appears to be
( ScheduledTime + Minutes Late )
or in other words the projected timestamp of the departure. 

I believe it's always been
( Lateness >= ScheduledTime )
as long as the epoch timestamp has been showing up. Because of that, I implemented a work-around by simply taking the difference between the two
( Lateness = Lateness - ScheduledTime ) if ( Lateness > 1000000000 )
and that's been working well.  (Note that not all of the Lateness values have been showing up with epoch time. Some are still showing the minutes delta like before.)

One note for the MBTA folks: The Departures feed still seems to have the leading-zero for Trip numbers the way the schedules were prior to May 23. For example right now the feed has Trip 023, 047, 087. I also implemented a quick work-around for that.

Developer at MBTA

unread,
Jun 2, 2016, 11:39:04 AM6/2/16
to MBTA Developers
We apologize for the delay in fixing this issue. We expect to have a fix deployed this afternoon.

In the meantime, Stefan's interpretation of the situation, and his workaround, are correct.

Developer at MBTA

unread,
Jun 2, 2016, 1:45:25 PM6/2/16
to MBTA Developers
Hi all,

The problem has been fixed. Please let us know if you have further issues with the feed.

Sincerely,
Developer@MBTA
Reply all
Reply to author
Forward
0 new messages