Skip to content
This repository was archived by the owner on May 7, 2025. It is now read-only.

Conversation

@simontuckwell
Copy link

The current code doesn't support Blynk servers using IPv6 addresses as the socket defaults to IPv4 (family AF_INET) and the address tuple returned by getaddrinfo() has extra values for an IPv6 host.

These changes use the family, type and proto returned by getaddrinfo() and remove the extra values in the address tuple before opening the socket.

The new code also filters the type and proto in the call to getaddrinfo() so that fewer tuples are returned. It still uses only the first element in the list.

Tested on Fedora Linux and Python 3.11.3.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant