Page 1 of 1

[0.17.79] Train repaths in the middle of junction when an unconnected rail is placed.

Posted: Sun Dec 15, 2019 2:19 pm
by Stevetrov
NB I believe this is probably related to viewtopic.php?f=7&t=78988
What did you do? / What happened?
With this savefile
I placed a single rail piece unconnected to any other rails whilst trains were crossing the big junction and a number of trains repathed causing them to stop suddenly.
NB The junction is controlled by CN controlled signals (aka traffic lights) and it appears that when the rail is placed the trains repath and lose their path reservation.

Here is a little video

Some (all?) of the trains also seen to briefly "no path" even though their original path is still valid even if there are red signals.
What did you expect to happen instead? It might be obvious to you, but do it anyway!
I dont think the trains should repath but even if they do, they shouldnt lose their path reservations.
They should never stop in the middle of a junction except where there is no path for the train to continue.

Re: [0.17.79] Train repaths in the middle of junction when an unconnected rail is placed.

Posted: Sun Dec 15, 2019 9:26 pm
by Rseding91
I haven't looked into this extensively but I suspect that nothing will be changed around this.

Signals controlled by circuit network have a lot of "well screw it, the train just has to re-path all the time" associated with them due to the edge case issues they cause by being circuit controlled.

Re: [0.17.79] Train repaths in the middle of junction when an unconnected rail is placed.

Posted: Mon Dec 16, 2019 5:47 am
by Rseding91
After looking into it more I think it should be resolved (in this exact case of building 1 unconnected rail).

Building multiple rails that end up with multiple connections still causes the issue because the logic isn't sure if it just connected 2 complete different sets of rails.

The underlying issue is: forcing a rail signal closed on a trains route means it always wants to find another route because it's being told "this route is invalid - you can never drive down it" and connecting rails says to the system "maybe a new path is open that isn't blocked by a closed signal".

Re: [0.17.79] Train repaths in the middle of junction when an unconnected rail is placed.

Posted: Mon Dec 16, 2019 1:33 pm
by PyroFire
Rseding91 wrote: Mon Dec 16, 2019 5:47 am After looking into it more I think it should be resolved (in this exact case of building 1 unconnected rail).

Building multiple rails that end up with multiple connections still causes the issue because the logic isn't sure if it just connected 2 complete different sets of rails.
this is related: viewtopic.php?f=6&t=74776

Re: [0.17.79] Train repaths in the middle of junction when an unconnected rail is placed.

Posted: Mon Dec 16, 2019 2:35 pm
by Stevetrov
PyroFire wrote: Mon Dec 16, 2019 1:33 pm
Rseding91 wrote: Mon Dec 16, 2019 5:47 am After looking into it more I think it should be resolved (in this exact case of building 1 unconnected rail).

Building multiple rails that end up with multiple connections still causes the issue because the logic isn't sure if it just connected 2 complete different sets of rails.
this is related: viewtopic.php?f=6&t=74776
Yea sounds like it is the same issue although spread out over lots of ticks to create a lot of slowdown rather than hanging when using the editor.