Closed michaz closed 6 years ago
This should happen in PersonAgent -> when(Moving) -> receives AlightVehicleTrigger.
We pay when we exit the vehicle. @michaz there has been a change since the last time you worked on these protocols... agents no longer track leg by leg the progress of their transit (or any other) trip. Now they just get notified by the driver when it's time to alight. This was done to both reduce the messaging volume but more importantly to make it simpler for ride hail vehicles to get dynamically dispatched to pickup new passengers without needed to modify any data in the existing passengers.
And/or maybe where the PathTraversalEvent is thrown? Or even put it in the PathTraversalEvent? Since vehicles are tolled, the toll could go in there. Splitting toll between passengers seems to be the next step?
Then again, people pay money, not vehicles, and things like city tolls which are due once per day don't map cleanly to individual trips.
Got paid tolls into PathTraversalEvents, will now do the last step and let private car occupants get an Event for the payment, like/where @colinsheppard said. Happening here https://github.com/LBNL-UCB-STI/beam/tree/mz/reactivate-tests-4ci
If I don't get that branch to build on Jenkins, like, tomorrow, I'll cherry-pick it to another PR.
@wrashid @colinsheppard What's the expected behavior for tolls and ride hailing? Customer pays tolls on top of fare?
@michaz I think we want the ride hailing manager to pay the toll and pass the cost on to the customer.
This will make it easier to deal with splitting tools during pooled rides.
It also should keep it simple re: putting toll into PathTraversalEvent.... doesn't matter who the driver is, all we care about is the driver pays the toll and then the parent of the driver (PersonAgent or RideHailAgent) should handle what do with that that (e.g. add to plan score or notify the ride hail manager).
Closed by PR #929
Means that toll collection must "happen" at the right point, probably by throwing money events.
Ensure that agents know about toll and take it into account even in later iterations where they don't ask the router for a new route, but for a newly embodied old route.