Skip to content

Not calling disconnect  #4

@nemccarthy

Description

@nemccarthy

Hey I’ve been looking through this code as I’m using this with home assistant and have been having problems connecting to my switchbots. I am also seeing bluepy helper processes hanging around.

It seems this code should call disconnect after write packet success or failure. I know the bluepy peripheral class destructor should call disconnect but it seems this isn’t always the case as stated in the bluepy docs. I would propose calling disconnect at the end of writing.

Also with the retry logic, is there a reason that the retry should not also cover situations where connect fails?

Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions