[issue44077] IP_RECVTOS option is missing from socket module
New submission from Georg Sauthoff : Currently, the socket module doesn't provide the IP_RECVTOS constant. This constant is needed for receiving the TOS byte (or the DSCP bits) via ancillary data when calling recvmsg() or recvmsg_into(). That means it would be used in a setsockopt() call like this: s.setsockopt(socket.IPPROTO_IP, socket.IP_RECVTOS, 1) This socket option is available on Linux and perhaps other operating systems, as well. See also https://manpath.be/f33/7/ip#L467 -- components: Library (Lib) messages: 393261 nosy: gms priority: normal severity: normal status: open title: IP_RECVTOS option is missing from socket module type: enhancement versions: Python 3.11 ___ Python tracker <https://bugs.python.org/issue44077> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1346874] httplib simply ignores CONTINUE
Changes by Georg Sauthoff <m...@georg.so>: -- nosy: +gms ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue1346874> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21258] Add __iter__ support for mock_open
Georg Sauthoff added the comment: For working around this issue on Python 3.5 it is sufficient to overwrite just the `return_value.__iter__` method of the object returned by `mock_open()` with an iterator that calls the mocked `readline()` method until it returns the empty string. cf. e.g. https://github.com/gsauthof/utility/blob/6489c7215dac341be4e40e5348e64d69461766dd/user-installed.py#L176-L179 This also works in combination with `csv.reader()`, i.e. when calling it with the mocked file object. -- ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue21258> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue21258] Add __iter__ support for mock_open
Changes by Georg Sauthoff <m...@georg.so>: -- nosy: +gms ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue21258> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue26308] Solaris 10 build issues
New submission from Georg Sauthoff: When building on Solaris 10 I had to patch Modules/_posixsubprocess.c -> dirfd issues Modules/socketmodule.c -> sethostname declaration setup.py -> ncurses detection See the attached patch for details. I built it like this: CC=gcc CXX=g++ LDFLAGS="-m64 -L/opt/csw/lib/64 -R/opt/csw/lib/64" CPPFLAGS="-I/opt/csw/include -I/opt/csw/include/ncursesw" CFLAGS="-m64 -D_XOPEN_SOURCE=600 -std=gnu99" CXXFLAGS="-m64" ./configure --prefix=/usr/local/python-3.5.1 Note that /opt/csw/ is popular open source repository for Solaris 10; it is the first place to go to get relatively recent stuff like gcc 4.9 etc. The first 2 hunks of the patch aren't very controversial, I guess. The Solaris-ncurses detection can be done in several ways, of course. Also, one could change ncurses package build such that the global CFLAGS (especially -D_XOPEN_SOURCE=600) are picked up. Another variation - the configure could try to detect if _XOPEN_SOURCE=600 is supported and - in case it is - automatically set it. -- components: Build files: python-3.5.1-solaris10.diff keywords: patch messages: 259852 nosy: gms priority: normal severity: normal status: open title: Solaris 10 build issues type: compile error versions: Python 3.5 Added file: http://bugs.python.org/file41852/python-3.5.1-solaris10.diff ___ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue26308> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com