Flodu31 / HomeAssistant-PeugeotIntegration

Integration between Peugeot API and Home Assistant
96 stars 15 forks source link

KeyError 'vin' #45

Open aflegler opened 10 months ago

aflegler commented 10 months ago

Hi,

I submitted my User-Config an got an Error named "vin":

2023-08-21 14:45:02,013 :: INFO :: Starting analysis on AndroidManifest.xml
2023-08-21 14:45:02,055 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,056 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,059 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,062 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,065 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,066 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,079 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,080 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,082 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,083 :: INFO :: Namespace mapping (58, 422) already seen! This is usually not a problem but could indicate packers or broken AXML compilers.
2023-08-21 14:45:02,189 :: INFO :: APK file was successfully validated!
2023-08-21 14:45:02,191 :: WARNING :: Requested API level 31 is larger than maximum we have, returning API level 28 instead.
2023-08-21 14:45:31,964 :: INFO :: save config change
2023-08-21 14:45:33,259 :: WARNING :: Can't get car model, please report an issue on github with your car model and first ten letter of your VIN : VR7EZZKXZP
2023-08-21 14:45:33,261 :: ERROR :: 'vin'
Traceback (most recent call last):
File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/web/view/config_views.py", line 133, in connectPSA
res = firstLaunchConfig(app_name, email, password, countrycode)
File "/usr/local/lib/python3.9/dist-packages/psa_car_controller/psa/setup/app_decoder.py", line 100, in firstLaunchConfig
car = psacc.vehicles_list.get_car_by_vin(vehicle["vin"])
KeyError: 'vin'
2023-08-21 14:45:33,269 :: INFO :: 172.30.32.1 - - [21/Aug/2023 14:45:33] "POST /_dash-update-component HTTP/1.1" 200 -

In myCitroen-App the first vehicle has no VIN. Perhaps this is the reason for the error.

The car that I am trying to connect is an "e-Berlingo".

ThoHilde commented 7 months ago

I had the same problem until yesterday. I also had a car without vin in my profile. You have to delete this car in the my-citroen app and then you can use the PSA controller.

aflegler commented 7 months ago

I had the same problem until yesterday. I also had a car without vin in my profile. You have to delete this car in the my-citroen app and then you can use the PSA controller.

I couldn't delete the car without a VIN due to a bug in the MyCitroen app. I created a new account with a different email and added the vehicle with VIN there.