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

Aranet4 v1.4.16 recognized as "version lower than v1.2.0" #116467

Closed
Nikkulin3 opened this issue Apr 30, 2024 · 14 comments
Closed

Aranet4 v1.4.16 recognized as "version lower than v1.2.0" #116467

Nikkulin3 opened this issue Apr 30, 2024 · 14 comments
Assignees

Comments

@Nikkulin3
Copy link

The problem

Trying to add my new aranet4 do home assistant is not working. It claims an old version for aranet4 but the aranet app tells me otherwise

Aranet4 Version: v1.4.16 (as in aranet app)
aranet app
aranet integration response

What version of Home Assistant Core has the issue?

2024.4.4

What was the last working version of Home Assistant Core?

No response

What type of installation are you running?

Home Assistant OS

Integration causing the issue

Aranet

Link to integration documentation on our website

https://www.home-assistant.io/integrations/aranet

Diagnostics information

No response

Example YAML snippet

No response

Anything in the logs that might be useful for us?

No response

Additional information

No response

@home-assistant
Copy link

Hey there @aschmitz, @thecode, @Anrijs, mind taking a look at this issue as it has been labeled with an integration (aranet) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of aranet can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign aranet Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


aranet documentation
aranet source
(message by IssueLinks)

@thecode
Copy link
Member

thecode commented Apr 30, 2024

I think you have the same issue as #115602 but you identified the root cause.
@Anrijs FYI

@Anrijs
Copy link
Contributor

Anrijs commented Apr 30, 2024

I am not able to reproduce this at the moment, but i have got some ideas.
What hardware are You using? How are bluetooth advertisements received?

@thecode
Copy link
Member

thecode commented Apr 30, 2024

@Nikkulin3 (and others that want to provide a log with the advertisements sent by your devices)

Please add the following to configuration.yaml, restart home assistant, try to add a device or wait for a update from an existing device and attach the log.

logger:
  default: info
  logs:
    homeassistant.components.bluetooth: debug

Note: it is better to drag the log into the comment (which will add it as an attachment) and not copy paste as it is hard to read logs in GitHub.

Thanks

@Nikkulin3
Copy link
Author

Thanks for the quick reply!

Hardware: Raspberry Pi 4-64 4GB using the on-board bluetooth.
fyi: I'm connecting some Govee BLE devices with bluetooth for temp/humidity and reading data from them successfully.
The Aranets Bluetooth MAC-Address is E2:5C:41:DD:43:DA. (see log / image)
image

For the log, I cleared everything from boot, then tried adding the device again. The log is the
cat .. | grep homeassistant.components.bluetooth-version. I think that's what you asked...
ha-bluetooth.log

@Anrijs I don't know what you mean with "How are bluetooth advertisements received?" but I hope the log clears that up for you.

@thecode
Copy link
Member

thecode commented Apr 30, 2024

Thanks @Nikkulin3.

@Anrijs from his log:

2024-04-30 21:26:17.387 DEBUG (MainThread) [homeassistant.components.bluetooth] Rediscovered adapters: {'hci0': {'address': 'DC:A6:32:5B:71:C6', 'sw_version': 'homeassistant', 'hw_version': 'usb:v1D6Bp0246d0548', 'passive_scan': True, 'manufacturer': 'Raspberry Pi Trading Ltd', 'product': None, 'vendor_id': None, 'product_id': None}}

Advertisements received by standard PI Bluetooth adapter (using passive scan, no device name)

The log contains all advertisements from his device, I believe they can be injected offline to understand the problem.

@Anrijs
Copy link
Contributor

Anrijs commented May 1, 2024

I might have found the issue, but someone will need to check if fix works.
Try upgrading aranet4 to aranet4==2.3.4b1

@Nikkulin3
Copy link
Author

Not sure how to access pip from within the home assistant os. On my PC, the current version aranet4==2.3.3 connects with the aranet device, which is unexpected and makes things hard to debug for me.

@Anrijs
Copy link
Contributor

Anrijs commented May 2, 2024

See #115602 (comment)
But instead of aranet4==2.2.2, use aranet4==2.3.4b1

@Nikkulin3
Copy link
Author

I am unable to find the file /usr/src/homeassistant/homeassistant/components/aranet/manifest.json on my HA-OS file system nor any folder named aranet or aranet4 while searching /.
Neither with ssh addon or portainer addon+console ingress.
A more elaborate explanation of what shell into home assistant container means exactly (which container? how?) would probably help. I am probably looking in the wrong places.

@Anrijs
Copy link
Contributor

Anrijs commented May 4, 2024

You can shell into container by running docker exec -t -i homeassistant /bin/bash

@Nikkulin3
Copy link
Author

Thanks. I was first looking for pip/docker access in the SSH connection (where no docker or pip exists) and in the portainer addon. Solution: the container "homeassistant" is explicitly hidden in portainer settings.
Anyways...

Previously installed version was 2.3.3, I can confirm the command aranetctl --scan does work in the container.

Then I installed via pip install aranet4==2.3.4b1.
The manual scan worked (--scan) but not the integration/adding of a device. Once I did a reboot, I was able to install the device without a problem. This is great and all, but what confuses me is the following: After the reboot, in the docker container, the pip show aranet4 command shows the old 2.3.3 version and not the new one. Is this expected behavior?

Any other tests I can do?

@thecode
Copy link
Member

thecode commented May 7, 2024

Then I installed via pip install aranet4==2.3.4b1.

Don't use pip install, edit the manifest as explained #115602 (comment) via sed or manual edit the file, after restart the container (core) to install the updated dependency.

pip show aranet4 command shows the old 2.3.3 version and not the new one. Is this expected behavior?

This is because HA will reinstall the dependency according to the manifest.

@Anrijs Anrijs mentioned this issue May 19, 2024
20 tasks
@thecode
Copy link
Member

thecode commented May 19, 2024

Fixed by #117738

@thecode thecode closed this as completed May 19, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Jun 18, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants