psa_car_controller icon indicating copy to clipboard operation
psa_car_controller copied to clipboard

record preconditioning failureCause

Open gernot-h opened this issue 1 year ago • 1 comments

By chance, I noticed that our Astra L Hybrid's door was not locked/closed correctly by looking at the debug log:

2024-02-14 22:14:51,368 :: DEBUG :: response body: {...
"preconditioning":{"airConditioning":{"createdAt":"2024-02-14T21:07:48Z","updatedAt":"2024-02-14T21:07:48Z","status":"Failure","failureCause":"DoorOpened","programs":[{"enabled":false,"slot":1,"recurrence":"Daily","start":"PT7H30M","occurence":{"day":["Mon","Tue","Wed","Thu","Fri"]}}]}}

The get_vehicleinfo API also reported the status, but it didn't mention the helpful failureCause.

I think support for this field was once in the code, but got removed in 619cefd4. I wonder whether there was a specific reason to remove this field?

I need to do more tests tomorrow, for now I prefer to keep the car's door closed over night. ;-)

gernot-h avatar Feb 14 '24 21:02 gernot-h

Indeed, we just need to re-add some of the lines once removed in 619cefd4 to make the information appear in get_vehicleinfo again, see #763.

gernot-h avatar Feb 15 '24 20:02 gernot-h