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

Crash on Mac OS Monterey 12.7.5 (Intel) - Nicotine+ Version: 3.3.5.dev1 #3016

Closed
iioniis opened this issue May 22, 2024 · 6 comments
Closed
Labels
Milestone

Comments

@iioniis
Copy link

iioniis commented May 22, 2024

Nicotine+ Version: 3.3.5.dev1
GTK Version: 4.14.4
Python Version: 3.12.3 (darwin)

Type: <class 'OSError'>
Value: [Errno 22] Invalid argument
Traceback: File "/Users/runner/work/nicotine-plus/nicotine-plus/pynicotine/gtkgui/application.py", line 886, in _raise_exception
File "/usr/local/Cellar/python@3.12/3.12.3/Frameworks/Python.framework/Versions/3.12/lib/python3.12/threading.py", line 1073, in _bootstrap_inner
File "/Users/runner/work/nicotine-plus/nicotine-plus/pynicotine/slskproto.py", line 2732, in run
File "/Users/runner/work/nicotine-plus/nicotine-plus/pynicotine/slskproto.py", line 2497, in _process_ready_sockets
File "/Users/runner/work/nicotine-plus/nicotine-plus/pynicotine/slskproto.py", line 2400, in _process_ready_input_socket
Operating System/Distribution:

I wasn't active at the computer when it happened. I just came back to this report.

@iioniis iioniis added the bug label May 22, 2024
@iioniis iioniis changed the title Crash on Mac OS Monterey 12.7.5 (Intel) Crash on Mac OS Monterey 12.7.5 (Intel) - Nicotine+ Version: 3.3.5.dev1 May 22, 2024
@slook
Copy link
Member

slook commented May 22, 2024

Thank you for your bug report :)

It is caused by recent commit e181f50

incoming_sock.setsockopt(socket.SOL_SOCKET, socket.SO_RCVBUF, self.SOCKET_READ_BUFFER_SIZE)

@mathiascode
Copy link
Member

Maybe an incoming connection died while accepting it? Are you able to perform file searches without issues?

@iioniis
Copy link
Author

iioniis commented May 24, 2024

Maybe an incoming connection died while accepting it? Are you able to perform file searches without issues?

mathiascode, yes I am. Search seams to work fine. It's only happened when I'm not actively using it and uploads are going. Uploads are usually happening anyway and it doesn't crash all the time.

@slook
Copy link
Member

slook commented May 24, 2024

It is bizarre that this argument is available on the system (otherwise the program wouldn't even be able to start), yet for some reason it went away in the middle of a session.

It's only happened when I'm not actively using it

I suppose the interface could have gone down for sleep or something like that.

@mathiascode
Copy link
Member

I'll have to verify how macOS behaves myself, but the fix will most likely be to move the setsockopt calls inside the try block.

@mathiascode
Copy link
Member

I haven't been able to reproduce this issue on macOS. All incoming connections are working fine.

I don't know what the exact issue is, but it's an edge case. I'll catch the exception and remove such connections.

@mathiascode mathiascode added this to the 3.3.5 milestone Jun 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

3 participants