Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hacs Version incorrect Cars mixed up #282

Open
f1dgj opened this issue Dec 20, 2024 · 6 comments
Open

Hacs Version incorrect Cars mixed up #282

f1dgj opened this issue Dec 20, 2024 · 6 comments

Comments

@f1dgj
Copy link

f1dgj commented Dec 20, 2024

Downloaded version 0.1.2 after deleting previous version, after installation and reboot shows 0.1.1 installed.
I have more than one vehicle in Porsche connect and the entities generated in HA have the entities for one vehicle mixed with others.
Door lock does not work

Before installation of 0.1.1 (2) I had deleted the integration and restarted HA, downloaded and installed the updated version rebooted and logged in, all without an issue.
All the vehicles were created but some with incorrect names, but there are entities that do not belong to some cars that have been created and for the Taycan there are items missing such as door lock.

I then deleted thee integration and reinstalled but it has created exactly the same entities

So two issues, one with the version and with the entities created.

@fredriklj
Copy link
Collaborator

fredriklj commented Dec 20, 2024

There is a mismatch between the tag (0.1.2) and what is displayed (manifest.json), my fault when doing the release. Never mind that.

On the other issue (incorrect names) can you please post the debug output from the integration. You would typically have to add the following to configuration.yaml:

logger:
  logs:
    custom_components.porscheconnect: debug
    pyporscheconnectapi: debug

Also please describe more in detail what is missing except lock switch.

@f1dgj
Copy link
Author

f1dgj commented Dec 20, 2024

Here’s what I’ve got enabling debug logging, I’ll grab screenshots of the mixed up entities from the vehicles later

Logger: homeassistant.components.lock
Source: helpers/entity_platform.py:773
integration: Lock (documentation, issues)
First occurred: 11:36:24 (6 occurrences)
Last logged: 21:25:41

Platform porscheconnect does not generate unique IDs. ID -lock already exists - ignoring lock.door_lock

Logger: homeassistant.components.lock
Source: helpers/entity_platform.py:374
integration: Lock (documentation, issues)
First occurred: 21:21:43 (1 occurrences)
Last logged: 21:21:43

Error while setting up porscheconnect platform for lock
Traceback (most recent call last):
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 374, in _async_setup_platform
await asyncio.gather(*pending)
File "/usr/src/homeassistant/homeassistant/helpers/entity_platform.py", line 641, in async_add_entities
for entity in new_entities:
^^^^^^^^^^^^
File "/config/custom_components/porscheconnect/lock.py", line 33, in
PorscheLock(coordinator, vehicle) for vehicle in coordinator.vehicles
~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/porscheconnect/lock.py", line 48, in init
super().init(coordinator, vehicle)
~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^
File "/config/custom_components/porscheconnect/init.py", line 188, in init
name=vehicle.data["name"],
~~~~~~~~~~~~^^^^^^^^
KeyError: 'name'

@f1dgj
Copy link
Author

f1dgj commented Dec 20, 2024

IMG_2469

This shows the vehicles the top one is an older Cayman that has no connectivity but has brought in the name correctly.
The second one has limited connectivity but has been given the name “mileage”

The third is a Taycan with full connectivity and is mostly correct but has no door locks. Remote climate wasn’t there initially but has now appeared.

The fourth is another 718 that in theory has limited connectivity but has appeared with no name and a bunch of entities that are unknown.

I’ll try to get more logs but will be tomorrow or Sunday

Thank you for the work done by everyone on this.

@f1dgj
Copy link
Author

f1dgj commented Dec 20, 2024

IMG_2473
IMG_2474

here’s a couple of screenshots of one of the 718’s

@fredriklj
Copy link
Collaborator

Ok, thanks for the report. I would need the full debug output from when the integration starts, that will (hopefully) show exactly what data the API returns when querying for status. It appears the data from the vehicles with limited functionality has another (unexpected) format.

@fredriklj
Copy link
Collaborator

@f1dgj Would it be possible for you to provide the debug output? Setting something like this in your configuration.yaml:

logger:
  default: info
  logs:
    homeassistant.components.cloud: debug
    custom_components.porscheconnect: debug
    pyporscheconnectapi: debug

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants