Skip to content
New issue

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

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

Already on GitHub? # to your account

Discovery Fix: Using '<broadcast>' does not work on Windows. Changed to '255.255.255.… #31

Merged
merged 1 commit into from
Jul 10, 2023

Conversation

qjgn
Copy link
Contributor

@qjgn qjgn commented Jun 28, 2023

Problem

Using the <broadcast> as the sendto destination does not work on Windows and returns the following error:

asyncio\windows_events.py", line 543, in sendto        
    ov.WSASendTo(conn.fileno(), buf, flags, addr)
OSError: [WinError 10022] An invalid argument was supplied

The console output becomes cluttered when receiving the error because QRTDiscoveryProtocol Is missing an error callback.

Solution

  • Changed the broadcast address to 255.255.255.255
  • Added an error handling function which logs the error with a callstack.

Solves

#30

@qjgn qjgn changed the title Discovery Fix: Using '<broadcast>' did not work on Windows. Changed to '255.255.255.… Discovery Fix: Using '<broadcast>' does not work on Windows. Changed to '255.255.255.… Jun 28, 2023
@qjgn qjgn marked this pull request as ready for review June 28, 2023 11:53
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants