OpenRailAssociation / osrd

An open source web application for railway infrastructure design, capacity analysis, timetabling and simulation
https://osrd.fr
GNU Lesser General Public License v3.0
436 stars 40 forks source link

TSv2: Multiple problems to create a train with 'arrival on stop signal' on TSV2 #7585

Closed woshilapin closed 4 days ago

woshilapin commented 3 months ago

What happened?

Multiple different bugs happened in a relatively simple scenario. See the video and the description.

https://github.com/OpenRailAssociation/osrd/assets/2520723/204180e9-9bb9-4208-b957-8aaae355421c

  1. I'm trying to create a train from the track above and an arrival point on the right. We can see that the pathfinding, highlighted in green on the track, doesn't go all the way to the arrival point but stops at the switch/node.
  2. I'm adding a via and then go on the tab for scheduled stops, I see only 2 lines.
  3. When I click on the 'arrival on stop signal' checkbox for the last stop, it works. But when I try to click the same checkbox for the via, it doesn't get checked
  4. Each time I click the checkbox for the via, the identifier on the left changes
  5. When I go back to the itinerary tab, a new via appeared

What did you expect to happen?

How can we reproduce it (as minimally and precisely as possible)?

Here's a video to reproduce the steps. The TSV2 and new STDCM features are activated in the user profile.

https://github.com/OpenRailAssociation/osrd/assets/2520723/204180e9-9bb9-4208-b957-8aaae355421c

What operating system, browser and environment are you using?

OSRD version (top right corner Account button > Informations)

625d185

woshilapin commented 3 months ago

Note: the Station that appears in the tab for scheduled stops, is expected (even if it's surprising in terms of User Experience). When launching a pathfinding, the response will contain all Operational points on the way (the station is an Operational Point). I tested the functionality of 'arrival on stop signal' for Operational Point, and it works as expected. So only via seems to create problems with my video-recorded scenario.

SharglutDev commented 2 months ago

For the issue concerning the number of operational points listed in the times and stops table, we only have two because it only shows the via added on the map and the existing operational points in this path. When origin and/or destination are added by click on map (so not from an op on the path), we should add them to the list in the times and stops table.

SharglutDev commented 1 month ago

@woshilapin would you mind to retest the app regarding the issue to check if all your concerns have been resolved to close it ? :) (except the input table issue reported here : https://github.com/OpenRailAssociation/osrd/issues/8019)

woshilapin commented 1 month ago

So I tried a similar scenario (without the via) and got a whole lot of other weird behaviors. I had to test on rec since dev was broken. Here is the video and a list below.

https://github.com/user-attachments/assets/2e7322c7-d942-406d-9728-1b4560894b24

Scenario (see in bold all the unexpected behavior):

  1. Select a random point on the track as the origin
  2. Select another random point on the track as the destination
  3. Go to the "scheduled stops" tab: a third scheduled point has appeared, it's the Operational Point between the origin and destination, but the ordering of the "scheduled points" is incorrect, the Operational Point should be in the middle
  4. I click on "arrival on stop signal" but the checkbox can't be checked (note: it might be https://github.com/OpenRailAssociation/osrd/issues/8019)
  5. I go to the "routing" tab, then go back to the "scheduled stops" tabs, the checkbox for "arrival on stop signal" is now checked
  6. Same with the duration for a stop, if I fill in with a value, but when I type "Enter", the value comes back to zero, until I switch tab to "routing" then back to "scheduled stops", and then, the value is 10
  7. I click on "arrival on stop signal" for the Operational Point, it doesn't get checked
  8. I delete the middle scheduled point (which I suspect is the destination of my pathfinding), then go back to "routing" tab, the destination changed, but the pathfinding didn't
SharglutDev commented 1 month ago

Probably most of your issues will be fixed with this PR.

woshilapin commented 1 month ago

So as tested yesterday, much less is happening. There is still some ordering problems in the scheduled stops when suppressing one of them. See the following video.

https://github.com/user-attachments/assets/8b5b7780-bbf2-4910-8834-919a3db4e574

theocrsb commented 3 weeks ago

This PR would fix the problem when clicking on the cross in the video

theocrsb commented 1 week ago

@woshilapin, can you check if this ticket should be closed?

woshilapin commented 4 days ago

Last scenario tested again. Looks good. The constraints are now deleted when clicking on the red cross, without weird reordering of scheduled points, and the path is drawn correctly on the map. Note that the via is still preserved (not sure if it should be considered as a constraint that should also disappear too, but we can re-open a bug later it this starts to be a valid use case). I'm closing the ticket.