Transport icon indicating copy to clipboard operation
Transport copied to clipboard

Some trains missing from API

Open CedricReichenbach opened this issue 8 years ago • 2 comments

I just noticed that some trains seem to have disappeared from the API recently, even though they're still reported by the SBB website.

One that's reproducable is the S 4 from Bern to Thun at 23:46 (bottom one in screenshot): bildschirmfoto vom 2017-09-04 um 21 12 17

The output of http://transport.opendata.ch/v1/connections?from=bern&to=thun&time=23:40 contains the S 1 train and a later IC, but not the S 4.

This problem likely roots in the search.ch API, which doesn't report any S 4 for the corresponding request: https://fahrplan.search.ch/api/route.json?from=Bern&to=Thun&time=23:40

Since when?

As it happens, I think the missing connection was still reported correctly on July 10, so a regression must have been introduced with a change in that time frame since then.

A wild guess

The S 1 and the S 4 look quite similar data-wise, e.g. both depart at the same time. Maybe some duplicate removal mechanism kicked in too eagerly.

CedricReichenbach avatar Sep 04 '17 19:09 CedricReichenbach

S4 is still there (see departure table) just not for this query because you are 30% slower and seems to have no benefit at all compared to S1.

helbling avatar Sep 05 '17 01:09 helbling

@helbling Ok, so it's filtered out. It might have benefits in some occasions, e.g. if occupation is higher in the S1, or if the traveler prefers one route over the other (e.g. for sightseeing).

CedricReichenbach avatar Sep 05 '17 10:09 CedricReichenbach