Guido van Rossum added the comment:
Ok, I fixed test_writer_callback() in the tulip repo.
Indeed the error I reported first is gone now.
I logged the value of kev on failure, and got this output:
ERROR:root:kev = <select.kevent ident=83 filter=-2 flags=0x1 fflags=0x0
data=0x131750 udata=0x0>
Traceback (most recent call last):
File "/Users/guido/tulip/tulip/selectors.py", line 178, in _key_from_fd
return self._fd_to_key[fd]
KeyError: 83
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/guido/tulip/tulip/selectors.py", line 330, in select
key = self._key_from_fd(fd)
File "/Users/guido/tulip/tulip/selectors.py", line 180, in _key_from_fd
raise RuntimeError("No key found for fd {}".format(fd))
RuntimeError: No key found for fd 83
The full traceback printed by the unittest framework was:
ERROR: test_sock_client_ops (tulip.events_test.KqueueEventLoopTests)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/guido/tulip/tulip/selectors.py", line 178, in _key_from_fd
return self._fd_to_key[fd]
KeyError: 83
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/Users/guido/tulip/tulip/events_test.py", line 168, in
test_sock_client_ops
el.run_until_complete(el.sock_sendall(sock, b'GET / HTTP/1.0\r\n\r\n'))
File "/Users/guido/tulip/tulip/unix_events.py", line 146, in
run_until_complete
self.run()
File "/Users/guido/tulip/tulip/unix_events.py", line 110, in run
self._run_once()
File "/Users/guido/tulip/tulip/unix_events.py", line 582, in _run_once
event_list = self._selector.select(timeout)
File "/Users/guido/tulip/tulip/selectors.py", line 330, in select
key = self._key_from_fd(fd)
File "/Users/guido/tulip/tulip/selectors.py", line 180, in _key_from_fd
raise RuntimeError("No key found for fd {}".format(fd))
RuntimeError: No key found for fd 83
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue16853>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com