Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add selectors34 fallback for py27 under 64-bit Win
This change addresses a bug in selectors2 (that is resolved in master but is unreleased) with fd of the "long" type not being recognized as "int". Here's the traceback it causes: Traceback (most recent call last): File "C:\projects\cheroot\cheroot\server.py", line 1788, in serve self.tick() File "C:\projects\cheroot\cheroot\server.py", line 2023, in tick conn = self.connections.get_conn(self.socket) File "C:\projects\cheroot\cheroot\connections.py", line 163, in get_conn self._selector.unregister(fno) File "c:\projects\cheroot\.tox\python\lib\site-packages\selectors2.py", line 249, in unregister key = super(SelectSelector, self).unregister(fileobj) File "c:\projects\cheroot\.tox\python\lib\site-packages\selectors2.py", line 155, in unregister key = self._fd_to_key.pop(self._fileobj_lookup(fileobj)) File "c:\projects\cheroot\.tox\python\lib\site-packages\selectors2.py", line 127, in _fileobj_lookup return _fileobj_to_fd(fileobj) File "c:\projects\cheroot\.tox\python\lib\site-packages\selectors2.py", line 90, in _fileobj_to_fd raise ValueError("Invalid file object: {0!r}".format(fileobj)) ValueError: Invalid file object: 916L Refs: * sethmlarson/selectors2#10 * https://twitter.com/webKnjaZ/status/1285695028136992769 * https://github.com/berkerpeksag/selectors34/blob/1.2.0/selectors34.py#L51 * #301 (comment)
- Loading branch information