flobz / psa_car_controller

Control psa car with connected_car v4 API.
GNU General Public License v3.0
391 stars 199 forks source link

Data not refreshing anymore #570

Closed JaySea77 closed 1 year ago

JaySea77 commented 1 year ago

Describe the bug Information is not updating anymore since this morning

To Reproduce Steps to reproduce the behavior:

  1. what command did you use : I just restarted my Home Assisant
  2. when the bug append ? Since this morning no updates.
  3. Does it persist after restarting the program? Yes
  4. Does it persist after recreate config by going to http://server_address:port/config?

Config file Where do I find the file in Home Assistant?

Environment (please complete the following information):

Additional context Add any other context about the problem here. logging.txt

JaySea77 commented 1 year ago

Seems that the api is not responding. This is likely a ban? How long would a ban last?

p4block commented 1 year ago

Same here

2023-06-20 13:00:09,295 :: ERROR :: force_update:
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psacc/application/charge_control.py", line 70, in force_update
    self.psacc.remote_client.wakeup(self.vin)
  File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/common/utils.py", line 22, in wrapper
    raise RateLimitException
psa_car_controller.common.utils.RateLimitException

Works if you restart the container after it's "broken" :thinking:

Rate limit seems weird to me considering how not frequent updates are in my setup.

JaySea77 commented 1 year ago

Mycitroen app is not working either so I bet it is a ban. Hopefully it will be lifted soon. I used the Home Assistant addon and that requested the vehicle info every minute which is way too often.

p4block commented 1 year ago

I upped the refresh frequency from 60s to 300s and it's been working fine for an hour. Thought the ?from_cache=1 would make that unimportant but turns out you still need to be careful with frequency.

EDIT: still working fine a day later

JaySea77 commented 1 year ago

Still nothing is getting updated. Latest update yesterday 05:18. Both on psa car controller as in the MyCitroën app. I do get the info in get_vehicleinfo though. This means I can get info from the api, but the connection to the car is lost?

sebj54 commented 1 year ago

Same problem here since a few days… My car does not even charge any more if I choose the delayed charge and I can't see anything from the official app. My car appears with a "Order in progress" message.

I am going to change the refresh frequency, reconnect everything and see if the problem is solved. I will let you all know if it worked 🤞

JaySea77 commented 1 year ago

I even turned psa car controller off for more than a day and sti the MyCitroën app did nothing. Weird thing though that when logging in, I get my current mileage but after 2 seconds it jumps back to 19-06 05:18.

Also for now I changed my sensors to update every 10 minutes so the frequency shouldn't be an issue anymore.

Apollon77 commented 1 year ago

For me it also do not work anymore ... error is like

2023-06-24 08:43:47,817 :: INFO :: mqtt msg received: psa/RemoteServices/to/cid/AP-ACNT200001088381/VehCharge/state/ProcessManagement b'{"process_date":"2023-06-24T08:43:47Z","vin":"XXXXXX","correlation_id":"46cb8bd5c5bf4d6ca7e82ecfb176f63a20230624084347385","process_code":"900","process_message":"[process.900.request.accepted.key]"}'
2023-06-24 08:43:47,844 :: INFO :: mqtt msg received: psa/RemoteServices/to/cid/AP-ACNT200001088381/VehCharge/state b'{"resp_date":"2023-06-24T08:43:47Z","vin":"XXXXXXX","correlation_id":"46cb8bd5c5bf4d6ca7e82ecfb176f63a20230624084347385","return_code":"420","reason":"[rights.error.ves.sev.not.stopped.key]"}'
2023-06-24 08:43:47,844 :: ERROR :: 420 : [rights.error.ves.sev.not.stopped.key]

What key is meaned here? But "rights error" sounds like something else like not allowed access anymore or such. Maybe they did changes to block us :-)

JaySea77 commented 1 year ago

Was an issue with communication between car and webservice. It restored by itself.