-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Duplicated stops #1229
Comments
It seems not to be duplicating the stops, but generating/creating platforms with the original stop as parent_stop, for some reason. e.g
Maybe the stop_id or lat/lon fields in the feed are changing with every feed update? |
When looking at them through the mobility explorer they seems all on the
same exact coordinate.
…On Tue, 15 May 2018, 12:44 Rui J Santos, ***@***.***> wrote:
It seems not to be duplicating the stops, but generating/creating
platforms with the original stop as parent_stop, for some reason. e.g
onestop_id | "s-rckmg7u8cz-businesspde~highbrookdr<2090"
parent_stop_onestop_id | "s-rckmg7u8cz-businesspde~highbrookdr"
onestop_id | "s-rckmg7u8cz-businesspde~highbrookdr<2073
parent_stop_onestop_id | "s-rckmg7u8cz-businesspde~highbrookdr
Maybe the stop_id or lat/lon fields in the feed are changing with every
feed update?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#1229 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AACL6O8qIZW3X_2DyHlOP6GlUkfvntfDks5tyrGJgaJpZM4T2cBO>
.
|
I think it all comes down to the feed versions after this one For some reason, the stop_id's on that one feed version, and all other feed versions that followed it, have dates attached to them, which creates a new stop/platform, because the stop_id is different in each feed because of the attached date. At least it seems to be keeping the parent_stop the same. So, I would say it's a bug in the feed and not in the transitland datastore software, which seems to be working as intended, IMO. Probably the only problem in transitland was importing those feeds when they shouldn't because they have a problem(dates attached to stop_id's, but maybe there's a reason for those dates being there, who knows?). |
Thank for investigating @Rui-Santos indeed and you can see the stop id schema here (in the archive details): https://transit.land/dispatcher/feed-versions/7e1609712ced7f7ecded0fe7deefdc6bddb68497 or here https://transit.land/dispatcher/feed-versions/270399f70f59764a945b6a063a3e7a4dae53c05d (not sure why your link open a caltrain version). What maybe is a problem for me is that I would expect providers, stops or routes and schedules not referenced in any active version of a feed to not be returned by the API: i.e. in this case, despite the feed not following the best practice to aim to keep consistent stop_id from one version to another, old stops generated from previous feeds versions that aren't the active feed version should be filtered/deleted. Why does the api keep returning these? |
Probably has something to do with this, which is at the link below
https://transit.land/documentation/datastore/feeds.html#active-feed-version |
I don't think that it is related. What I meant is that for feed X with fetched feed version 1, 2, 3 (and all of these feed version properly imported). Stops and routes imported through an anterior feed version (i.e. not from the active feed version) shouldn't be returned in the API. In this case, if version 1,2,3 had the stops: stopA.date-1, stopA.date-2, stopA.date-3 I would expect only stopA.date-3 to be returned by the API. Otherwise it's a bit complex for the client to filter out old stops and routes. |
Looking at the link you posted originally, all the 44 stops(didn't you say they were 107?) in there have the same updated_at date, which is the date of the active feed version. Is the datastore updating the entities even when they are not present in the feed? That would be a bug. Or are those stops still referenced in the feed and that is the reason they are being updated instead of just dropped? I can confirm that they are not in the Stops.txt and in the API response some of them have empty operators_serving_stop and routes_serving_stop. |
Indeed 44 sorry! sorry, 107 was on my local setup of the datastore (I do have more of the feed version imported in total) This bounding box is easier to analyse: Here's the list of stops id:
And the list of parent stop ids
In one of the latest feed version zip here's what I found for this stop (https://transitland-gtfs.s3.amazonaws.com/datastore-uploads/feed_version/7e1609712ced7f7ecded0fe7deefdc6bddb68497.zip)
The two stop could correspond to the 4 last stops returned by the API. I failed to see why it translate to 4 stops and two parent stops (based on Stops.txt) but at least the other ~16 stops shouldn't be returned anymore. Maybe since they refer to the same parent stop they don't get disabled/deleted. And indeed they all have been updated at the same date 2018-02-27 but this is not the feed importation date (I guess it might relate more to the last osm_way_id match) |
I think you may be on to something here. And indeed it seems the updated_at date is the osm_way conflation date, because it's one day after the feed version import date, in the ones I verified. |
@irees Do you have any ideas here? I'm not sure where to look further and how to address it. The route going through these stops also seems to reference every single one of it (in stop_served_by) |
Hi all,
I've running in an issue where for some feeds it seems that the stops get duplicated a lot over time, i.e. every time the feeds get a new version. It seems that all stops are created again.
You can see it here (NZ feed) where in this small bounding box you have ~107 stops that represents around two in reality:
https://transit.land//api/v1/stops?bbox=174.87233519554138%2C-36.93862462178051%2C174.88262951374054%2C-36.936056263854915&departure_time=&isochrone_mode=&isochrones_mode=&onestop_id=&pin=-36.93735974847771%2C174.87571125850081&served_by=&per_page=false
After a while it becomes a problem when fetched into valhalla because it reaches max_transit_stop or other contraints like this one for a tile. Is there a way to delete all 'old entities' that aren't used in an active feed version somewhere? I guess here valhalla keep adding these stops because most of them are served by the current route from latest feed.
Best,
Cyprien
The text was updated successfully, but these errors were encountered: