[issue13741] *** glibc detected *** python: double free or corruption (!prev): 0x0000000001d53ad0 ***
New submission from Andrew : Hello, This program crashes after 12-24 hours of running. My OS is Ubuntu 11.10, I'm using Python 2.7.2, and gcc 4.6.1. Here's the error: *** glibc detected *** python: double free or corruption (!prev): 0x01d53ad0 *** === Backtrace: = /lib/x86_64-linux-gnu/libc.so.6(+0x78a96)[0x7fbd28c21a96] /lib/x86_64-linux-gnu/libc.so.6(cfree+0x6c)[0x7fbd28c25d7c] /usr/lib/python2.7/dist-packages/psycopg2/_psycopg.so(+0xd6aa)[0x7fbd27c806aa] /usr/lib/python2.7/dist-packages/psycopg2/_psycopg.so(+0xde51)[0x7fbd27c80e51] /usr/lib/python2.7/dist-packages/psycopg2/_psycopg.so(+0x13f9b)[0x7fbd27c86f9b] /usr/lib/python2.7/dist-packages/psycopg2/_psycopg.so(+0x146c6)[0x7fbd27c876c6] python(PyEval_EvalFrameEx+0x2f9)[0x4b6569] python(PyEval_EvalFrameEx+0xb07)[0x4b6d77] === Memory map: 0040-00633000 r-xp 08:06 1901460 /usr/bin/python2.7 00832000-00833000 r--p 00232000 08:06 1901460 /usr/bin/python2.7 00833000-0089c000 rw-p 00233000 08:06 1901460 /usr/bin/python2.7 0089c000-008ae000 rw-p 00:00 0 01b3-01f26000 rw-p 00:00 0 [heap] 7fbd1dffc000-7fbd1dffd000 ---p 00:00 0 7fbd1dffd000-7fbd1e7fd000 rw-p 00:00 0 7fbd1e7fd000-7fbd1e7fe000 ---p 00:00 0 7fbd1e7fe000-7fbd1effe000 rw-p 00:00 0 7fbd1effe000-7fbd1efff000 ---p 00:00 0 7fbd1efff000-7fbd1f7ff000 rw-p 00:00 0 7fbd1f7ff000-7fbd1f80 ---p 00:00 0 7fbd1f80-7fbd2000 rw-p 00:00 0 7fbd2000-7fbd2011e000 rw-p 00:00 0 7fbd2011e000-7fbd2400 ---p 00:00 0 7fbd24411000-7fbd24426000 r-xp 08:06 1754089 /lib/x86_64-linux-gnu/libgcc_s.so.1 7fbd24426000-7fbd24625000 ---p 00015000 08:06 1754089 /lib/x86_64-linux-gnu/libgcc_s.so.1 7fbd24625000-7fbd24626000 r--p 00014000 08:06 1754089 /lib/x86_64-linux-gnu/libgcc_s.so.1 7fbd24626000-7fbd24627000 rw-p 00015000 08:06 1754089 /lib/x86_64-linux-gnu/libgcc_s.so.1 7fbd24627000-7fbd24628000 ---p 00:00 0 7fbd24628000-7fbd24e28000 rw-p 00:00 0 7fbd24e28000-7fbd24e34000 r-xp 08:06 1754109 /lib/x86_64-linux-gnu/libnss_files-2.13.so 7fbd24e34000-7fbd25033000 ---p c000 08:06 1754109 /lib/x86_64-linux-gnu/libnss_files-2.13.so 7fbd25033000-7fbd25034000 r--p b000 08:06 1754109 /lib/x86_64-linux-gnu/libnss_files-2.13.so 7fbd25034000-7fbd25035000 rw-p c000 08:06 1754109 /lib/x86_64-linux-gnu/libnss_files-2.13.so 7fbd25035000-7fbd2503f000 r-xp 08:06 1754113 /lib/x86_64-linux-gnu/libnss_nis-2.13.so 7fbd2503f000-7fbd2523f000 ---p a000 08:06 1754113 /lib/x86_64-linux-gnu/libnss_nis-2.13.so 7fbd2523f000-7fbd2524 r--p a000 08:06 1754113 /lib/x86_64-linux-gnu/libnss_nis-2.13.so 7fbd2524-7fbd25241000 rw-p b000 08:06 1754113 /lib/x86_64-linux-gnu/libnss_nis-2.13.so 7fbd25241000-7fbd25258000 r-xp 08:06 1754103 /lib/x86_64-linux-gnu/libnsl-2.13.so 7fbd25258000-7fbd25457000 ---p 00017000 08:06 1754103 /lib/x86_64-linux-gnu/libnsl-2.13.so 7fbd25457000-7fbd25458000 r--p 00016000 08:06 1754103 /lib/x86_64-linux-gnu/libnsl-2.13.so 7fbd25458000-7fbd25459000 rw-p 00017000 08:06 1754103 /lib/x86_64-linux-gnu/libnsl-2.13.so 7fbd25459000-7fbd2545b000 rw-p 00:00 0 7fbd2545b000-7fbd25463000 r-xp 08:06 1754105 /lib/x86_64-linux-gnu/libnss_compat-2.13.so 7fbd25463000-7fbd25662000 ---p 8000 08:06 1754105 /lib/x86_64-linux-gnu/libnss_compat-2.13.so 7fbd25662000-7fbd25663000 r--p 7000 08:06 1754105 /lib/x86_64-linux-gnu/libnss_compat-2.13.so 7fbd25663000-7fbd25664000 rw-p 8000 08:06 1754105 /lib/x86_64-linux-gnu/libnss_compat-2.13.so 7fbd25664000-7fbd2566b000 r-xp 08:06 1754132 /lib/x86_64-linux-gnu/librt-2.13.so 7fbd2566b000-7fbd2586a000 ---p 7000 08:06 1754132 /lib/x86_64-linux-gnu/librt-2.13.so 7fbd2586a000-7fbd2586b000 r--p 6000 08:06 1754132 /lib/x86_64-linux-gnu/librt-2.13.so 7fbd2586b000-7fbd2586c000 rw-p 7000 08:06 1754132 /lib/x86_64-linux-gnu/librt-2.13.so 7fbd2586c000-7fbd2587a000 r-xp 08:06 1982536 /usr/lib/python2.7/dist-packages/mx/DateTime/mxDateTime/mxDateTime.so 7fbd2587a000-7fbd25a7a000 ---p e000 08:06 1982536 /usr/lib/python2.7/dist-packages/mx/DateTime/mxDateTime/mxDateTime.so 7fbd25a7a000-7fbd25a7b000 r--p e000 08:06 1982536 /usr/lib/python2.7/dis
[issue13741] *** glibc detected *** python: double free or corruption (!prev): 0x0000000001d53ad0 ***
Andrew added the comment: I'll try Python 2.6, but this says 2.7 is supported: http://initd.org/psycopg/features/ Thanks for the suggestion! -- status: pending -> open ___ Python tracker <http://bugs.python.org/issue13741> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4732] Object allocation stress leads to segfault on RHEL
Andrew added the comment: Cannot reproduce this on RHEL 4. So far only RHEL 5.x seems to be affected. ___ Python tracker <http://bugs.python.org/issue4732> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4732] Object allocation stress leads to segfault on RHEL
Andrew added the comment: This problem appears to be specific to RHEL 5, and is not a Python problem. Linking against Google malloc (libtcmalloc) fixes the issue. This bug should be closed. ___ Python tracker <http://bugs.python.org/issue4732> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)
New submission from Andrew : Quick repoduction steps: 1) Log into a mac with macOS version 10.15.1 (10.15.x may work) 2) For build tools, use Xcode11. A minimal xcode command-tools installation also reproduced for me. 3) Download and decompress the latest python 3.8.2 source 4) run "./configure" in the top-level source folder 5) run "make" in the top-level source folder I believe this error may also occur when using python 2.7.x, 3.7.x, and others. Curiously, the errors do not occur when I use the latest 3.6.10 source. A text file containing the output of "./configure" and "make" is attached. Main Description: On Mac 10.15.1 with Xcode11 I encounter compilation errors when building the latest Python 3.8.2 source. When the build reaches the "build_ext" section in setup.py, none of the extension modules build, with each compilation attempt producing an error. For example, when the _struct extension module attempts compilation I get: --- Error Syndrome --- building '_struct' extension gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -std=c99 -Wextra -Wno-unused-result -Wno-unused-parameter -Wno-missing-field-initializers -Wstrict-prototypes -Werror=implicit-function-declaration -I./Include/internal -I./Include -I. -I/usr/local/include -I/System/Volumes/Data/mathworks/devel/sandbox/aflewell/python38_source/Python-3.8.2/Include -I/System/Volumes/Data/mathworks/devel/sandbox/aflewell/python38_source/Python-3.8.2 -c _struct.c -o build/temp.macosx-10.15-x86_64-3.8/_struct.o clang: error: no such file or directory: '_struct.c' clang: error: no input files -- After many similar errors, we get to the main build report where we see the failed extension modules: --- Snippet of build report --- Python build finished successfully! The necessary bits to build these optional modules were not found: _gdbm _hashlib _ssl ossaudiodev spwd To find the necessary bits, look in setup.py in detect_modules() for the module's name. The following modules found by detect_modules() in setup.py, have been built by the Makefile instead, as configured by the Setup files: _abc atexitpwd time Failed to build these modules: _asyncio _bisect _blake2 _bz2 _codecs_cn_codecs_hk _codecs_iso2022 _codecs_jp_codecs_kr _codecs_tw_contextvars _crypt _csv _ctypes _ctypes_test _curses _curses_panel _datetime _dbm _decimal _elementtree _heapq_json _lsprof _lzma _md5 _multibytecodec _multiprocessing _opcode _pickle _posixshmem _posixsubprocess _queue _random _scproxy _sha1 _sha256 _sha3 _sha512 _socket _sqlite3 _statistics _struct _testbuffer _testcapi _testimportmultiple _testinternalcapi _testmultiphase _tkinter _uuid _xxsubinterpreters _xxtestfuzz array audioop binascii cmath fcntl grp math mmap nis parserpyexpat readline resource select syslogtermios unicodedata xxlimited zlib -- The part "-c _struct.c" in the error syndrome stands out to me because there is not a prefix like the other modules that get built successfully before the "build_ext" section. In the successful cases, we see a prefix like "-c ./Modules/faulthandler.c". This can be seen in my attached log. Also, when I use the Python 3.6.10 source, the build for _struct looks like this and goes fine on Mac 10.15.1. This seems to be the only version of python that works for me on 10.15.1 that I know of. --- building '_struct' extension creating build/temp.macosx-10.15-x86_64-3.6/System creating build/temp.macosx-10.15-x86_64-3.6/System/Volumes creating build/temp.macosx-10.15-x86_64-3.6/System/Volumes/Data creating build/temp.macosx-10.15-x86_64-3.6/System/Volumes/Data/my_company creating build/temp.macosx-10.15-x86_64-3.6/System/Volumes/Data/my_company/devel creating build/temp.macosx-10.15-x86_64-3.6/System/Volumes/Data/my_company/devel/sandbox creating build/temp.macosx
[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)
Andrew added the comment: Thanks for your reply Ned. I think you are right about mac OS sandboxes messing something up. Python builds most of the extension modules fine if I do a straightforward build in the /tmp directory like you said. Do you know of any easy ways to disable mac OS sandboxes from being used in the python build from the command line? Alternatively, how do I open the python project in xcode11 GUI? I think I might be able to disable sandboxes from there. If you are not very familiar with mac OS sandboxes like me, feel free to leave that up to me to figure out. Regarding you question about my command line tools version: I upgraded the my xcode command line tools installation to 11.4 - I believe this is the latest version that's supported on mac 10.15.1 I still get the same error behavior though when building outside of /tmp. In this case, here is the compiler that's getting used. % gcc --version Configured with: --prefix=/Library/Developer/CommandLineTools/usr --with-gxx-include-dir=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/c++/4.2.1 Apple clang version 11.0.3 (clang-1103.0.32.29) Target: x86_64-apple-darwin19.3.0 Thread model: posix InstalledDir: /Library/Developer/CommandLineTools/usr/bin -- status: pending -> open ___ Python tracker <https://bugs.python.org/issue41129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)
Andrew added the comment: The build steps were, unpack source, ./configure, make, using default settings on a company machine. The configure_and_make_output.txt I attached should show the whole ./configure output. The only difference is that I was using xcode 11.0 for that output- the errors and behavior are identical though. The error only seems to occur when building to a network location. This is most of our user space because we oftentimes do builds across platforms with the same source. Buliding at locations or out of source builds to /tmp or /Users/Shared works fine though. /mathworks is a network location which was originally mounted at root, but now we have it mounted at /System/Volumes/Data/mathworks. From there, all other network locations are available through other mount points. We also have some related symlinks at /System/Volumes/Data. I think I need to see how the network access move to /Systems/Volumes/Data might have changed and broken things for the python build. Likely, something deep in the python build is not working well with our new network setup. I will see if I can debug deeper into setup.py and PyBuildExt.build_extensions() to see if it's not working right with our network setup and to get you a way to reproduce this behavior. It's hard to see exactly how the paths get passed to xcode and the compiler though. I'll see what I can get you. -- ___ Python tracker <https://bugs.python.org/issue41129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41129] Python extension modules fail to build on Mac 10.15.1 (Catalina)
Andrew added the comment: So I believe I've found the problem as to why we can't get the extension modules to build in our network area. It seems to be a problem with setup.py's find_file() and is_macosx_sdk_path() functions when the extension modules are building. You can find these functions around line 182 of setup.py. For some background, our network location /mathworks is usually mounted at root, but due to the restrictions on macOS Catalina, it mounts at /System/Volumes/Data and we then add a symlink to the root directory so "/mathworks -> /System/Volumes/Data/mathworks" as to not break old code and scripts. So the real problem is that we cannot find extension module files under /System/Volumes/Data. This problem occurs because in setup.py, when we attempt to find an extension module file with find_file() wherein the file registers as being in the mac sdk path since the path starts with "/System". This is a problem because find_file() then prepends the file with the sdk path which isn't quite right and fails the existence check. For example a source file that actually exists at "/System/Volumes/Data/mathworks/hub/scratch/aflewell/Python-3.8.2/Modules/" find_file() calls os.path.exists() on "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/System/Volumes/Data/mathworks/hub/scratch/aflewell/Python-3.8.2/Modules/" which fails since the path does not exist at or after the "Volumes" part. This causes find_file to think the file does not exist at all, so the compiler ends up trying to compile the file without an absolute path or relative path to it, which fails. This can be fixed by changing is_macosx_sdk_path() so it does not consider /System/Volumes/Data as part of the sdk path: Change from: def is_macosx_sdk_path(path): """ Returns True if 'path' can be located in an OSX SDK """ return ( (path.startswith('/usr/') and not path.startswith('/usr/local')) or (path.startswith('/System/') ) or path.startswith('/Library/') ) to def is_macosx_sdk_path(path): """ Returns True if 'path' can be located in an OSX SDK """ return ( (path.startswith('/usr/') and not path.startswith('/usr/local')) or (path.startswith('/System/') and not path.startswith('/System/Volumes/Data')) or path.startswith('/Library/') ) This change prevents the sdk path from being prepended to the expected path to the file. I'm not sure if this is the right fix, so I'd like your opinion on it. I don'r know much about mac's developer sdk and how it works, but it doesn't seem like anything under /System/Volumes should be included in or locatable in the sdk. Anyways, it would be nice to have an official fix for this in the official python source. Regarding reproduction, you may be able to reproduce by trying to build python under /Systems/Volumes/Data, if not, it may have to do with the mounting of our network filesystem. Thanks for your help. -- ___ Python tracker <https://bugs.python.org/issue41129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41129] setup.py test for macOS SDK files may incorrectly classify files in other file systems
Andrew added the comment: Hi Ronald. The basic idea is that >= macOS 10.15.1 Apple has made most of the filesystem read only on a folder by folder basis. They separate user-writable onto a separate filesystem, treat it like a disk, and they mount it under /System/Volumes/ as "Data". Likewise, I think the idea is that other volumes get mounted under /System/Volumes, however, since "/System/Volumes/Data" is now "firmlinked" to root, I imagine you can find mounts to the writable filesystem under "/System/Volumes/Data/Volumes" which firmlinks to /Volumes. About the read-only system volume in macOS Catalina: https://support.apple.com/en-us/HT210650 More info on the container / firmlink scheme https://bombich.com/kb/ccc5/working-apfs-volume-groups -- ___ Python tracker <https://bugs.python.org/issue41129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue42220] Argparse: wildcards processing
New submission from Andrew : It's known that Linux and Windows shells process wildcards like '*' and '?' differently. Linux shell usually expands wildcards so the application gets list of files. In contrast, Windows passes the wildcards to application. So in cross-platform applications we have to expand wildcards manually only for windows. It may not be beautiful since it's usually not part of program's logic and seems kinda of arguments processing. Could this problem be solved via adding optional functionality to argparse library? For instance some option 'expand_wildcards' in ArgumentParser constructor with default value False (in order to not break compatibility)? -- components: Library (Lib) messages: 380076 nosy: Andrew priority: normal severity: normal status: open title: Argparse: wildcards processing type: enhancement versions: Python 3.10, Python 3.6, Python 3.7, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue42220> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue14475] codecs.StreamReader.read behaves differently from regular files
Andrew added the comment: Just got this behavior, with readlines(), which is unsurprising since it internally uses read() as described in the original bug report. The break on line 468 of codecs.py seems to be the problem, it fixes it if I remove this conditional locally. http://hg.python.org/cpython/file/f6a207d86154/Lib/codecs.py#l466 I may be overlooking something, but I would assume this should be checking if the character buffer extends to the EOF of the underlaying stream at this point? As stated before can be reproduced by: f = codecs.open(...) f.read() f.readlines() -- nosy: +Andrew.S ___ Python tracker <http://bugs.python.org/issue14475> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16812] os.symlink can return wrong FileExistsError/WindowsError information
New submission from Andrew: When attempting to make a symlink using a name that already exists, a FileExistsError is raised (and rightfully so), but it lists the source name rather than the destination name. However, the existing destination name is what causes the exception to be raised, not the existing source. Since the FileExistsError is WinError 183 and I haven't attempted this on another OS, I'm marking this as Windows-specific. Issue 13775 seems to be related. -- components: Windows messages: 178493 nosy: IAmTheClaw priority: normal severity: normal status: open title: os.symlink can return wrong FileExistsError/WindowsError information type: behavior versions: Python 3.3 ___ Python tracker <http://bugs.python.org/issue16812> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16812] os.symlink can return wrong FileExistsError/WindowsError information
Andrew added the comment: I tested this on FreeBSD 9.1, and the error message is correct there. -- ___ Python tracker <http://bugs.python.org/issue16812> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue8762] default value in constructor not unique across objects
New submission from andrew : After debugging for a while I finally released that I stumbled across a Python bug (at least I believe it is). Here is a proof of concept that produces the issue: !/usr/bin/python class blah: def __init__(self, items=[]): self.items = items a = blah() b = blah() a.items.append("apples") b.items.append("oranges") print a.items print b.items print id(a.items) print id(b.items) and here is the output when the program is run: r...@x:~# python pythonbug.py ['apples', 'oranges'] ['apples', 'oranges'] 135923500 135923500 r...@x:~# as you can see the 'items' reference is the same for both objects even though they are different objects. I checked the manual and I couldn't find anything explaining such behavior. Can this possibly be correct? My python info: Python 2.5.2 (r252:60911, Jan 20 2010, 21:48:48) -- messages: 106018 nosy: bolt priority: normal severity: normal status: open title: default value in constructor not unique across objects type: behavior versions: Python 2.5 ___ Python tracker <http://bugs.python.org/issue8762> ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue27448] Race condition in subprocess.Popen which causes a huge memory leak
New submission from Andrew: We had problem where at some point python start consuming RAM. Until it ends. The reason was race condition in subprocess.Popen. Which triggered gc.disable() and never gc.enable(). The workaround we use is: subprocess.gc.isenabled = lambda: True The scenario for race condition is pretty obvious looking into the code below: gc_was_enabled = gc.isenabled() <- T1 gets false here gc.disable() try: self.pid = os.fork() <- while T2 is here except: if gc_was_enabled: gc.enable() raise ... CODE FRAGMENT 1 ... if gc_was_enabled: gc.enable() Also I wonder if exception fails in "... CODE FRAGMENT 1 ..." why don't we re-enable gc (finally block) -- messages: 269783 nosy: aonishuk priority: normal severity: normal status: open title: Race condition in subprocess.Popen which causes a huge memory leak versions: Python 2.7 ___ Python tracker <http://bugs.python.org/issue27448> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue27448] Race condition in subprocess.Popen which causes a huge memory leak
Andrew added the comment: pppery, I don't think I am breaking gc functionality with my code. The code line I gave just meant to give the basic idea of what was helping to workaround this. If you are actually interested in the code I use, it is below: def fix_subprocess_racecondition(): """ !!! PLEASE NOTE THIS SHOULD BE CALLED BEFORE ANY OTHER INITIALIZATION was done to avoid already created links to subprocess or subprocess.gc or gc """ # monkey patching subprocess import subprocess subprocess.gc.isenabled = lambda: True # re-importing gc to have correct isenabled for non-subprocess contexts import sys del sys.modules['gc'] import gc -- ___ Python tracker <http://bugs.python.org/issue27448> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue27448] Race condition in subprocess.Popen which causes a huge memory leak
Andrew added the comment: Gregory P. Smith, "if you are seeing a memory leak and the statements that fail before the gc.enable call are more than" The problem in my case was different. It was race condition between gc.isenabled and gc.disable. Isenabled was called when gc was disabled by another subprocess. This caused that later on gc.enable was not triggered. -- ___ Python tracker <http://bugs.python.org/issue27448> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue22483] Copyright infringement on PyPI
Andrew added the comment: So, I think I need to explain the situation. At first, changes in package was made by me, but package was intended for use in internal pypi (in scope of company). I don't know how it appeared here. Why did I do that? Original package was not installable via pip at all. What was changed? MANIFEST.in (just one line) and nothing more. -- nosy: +andrew.pypi ___ Python tracker <http://bugs.python.org/issue22483> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24976] Arithmetic/precision bug when using floating-point numbers
New submission from Andrew: I just recently discovered this bug, but when adding or subtracting a number and a precision error occurs when using at least 1 floating-point number in the operation. For example, 1 - 0.98 should output 0.02, but instead outputs 0..020018 (at least on my machine). Included is a simple script showing what happens, just when incrementing or decrementing by 0.01 from 0 to 1. I am running Python 3.4.3 on a 64-bit Arch Linux machine. -- components: Interpreter Core files: weirdpythonbug.py messages: 249458 nosy: videogames4all priority: normal severity: normal status: open title: Arithmetic/precision bug when using floating-point numbers type: behavior versions: Python 3.4 Added file: http://bugs.python.org/file40313/weirdpythonbug.py ___ Python tracker <http://bugs.python.org/issue24976> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46040] asyncio.coroutine documented as removed in 3.10
Change by Andrew Svetlov : -- keywords: +patch pull_requests: +28281 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30061 ___ Python tracker <https://bugs.python.org/issue46040> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46040] asyncio.coroutine documented as removed in 3.10
Andrew Svetlov added the comment: New changeset 991736697dff693b6c9f8964bb7540081bbf4ddb by Andrew Svetlov in branch '3.10': [3.10] bpo-46040: Fix removal text for @asyncio.coroutine (GH-30061) https://github.com/python/cpython/commit/991736697dff693b6c9f8964bb7540081bbf4ddb -- ___ Python tracker <https://bugs.python.org/issue46040> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46040] asyncio.coroutine documented as removed in 3.10
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46040> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45874] urllib.parse.parse_qsl does not parse empty query string with strict parsing
Andrew Svetlov added the comment: New changeset e6fe10d34096a23be7d26271cf6aba429313b01d by Christian Sattler in branch 'main': bpo-45874: Handle empty query string correctly in urllib.parse.parse_qsl (#29716) https://github.com/python/cpython/commit/e6fe10d34096a23be7d26271cf6aba429313b01d -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue45874> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45855] PyCapsule_Import still using PyImport_ImportModuleNoBlock
Andrew Svetlov added the comment: New changeset 41026c3155012d6ea50e01205c163b6739c675b8 by Kumar Aditya in branch 'main': bpo-45855: Replaced deprecated `PyImport_ImportModuleNoBlock` with PyImport_ImportModule (GH-30046) https://github.com/python/cpython/commit/41026c3155012d6ea50e01205c163b6739c675b8 -- ___ Python tracker <https://bugs.python.org/issue45855> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45855] Replace PyImport_ImportModuleNoBlock with PyImport_ImportModule in std modules
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed title: PyCapsule_Import still using PyImport_ImportModuleNoBlock -> Replace PyImport_ImportModuleNoBlock with PyImport_ImportModule in std modules ___ Python tracker <https://bugs.python.org/issue45855> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16594] SocketServer should set SO_REUSEPORT along with SO_REUSEADDR when present
Andrew Svetlov added the comment: New changeset b56774bd93822e1598bb5d6c1d0b1fe8c45a750d by AN Long in branch 'main': bpo-16594: Add allow_reuse_port on socketserver (GH-30072) https://github.com/python/cpython/commit/b56774bd93822e1598bb5d6c1d0b1fe8c45a750d -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue16594> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue16594] SocketServer should set SO_REUSEPORT along with SO_REUSEADDR when present
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: +Python 3.11 -Python 2.7 ___ Python tracker <https://bugs.python.org/issue16594> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46116] _asyncio_backend.py datagram_received doesn't handle Future cancelled, throws Exception
Andrew Svetlov added the comment: dns package is not a part of Python standard library. Please file a bug in https://github.com/rthalley/dnspython/issues bugtracker. P.S. The fix is pretty straightforward: if not fut.done(): fut.set_result(...) -- resolution: -> third party stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46116> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46099] Solaris: Fix pthread_getcpuclockid test
Andrew Svetlov added the comment: New changeset 427a490c495cde8a152e938c6f02be65620e3e59 by Jakub KulĂk in branch 'main': bpo-46099: Fix pthread_getcpuclockid test on Solaris (GH-30140) https://github.com/python/cpython/commit/427a490c495cde8a152e938c6f02be65620e3e59 -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue46099> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46099] Solaris: Fix pthread_getcpuclockid test
Andrew Svetlov added the comment: New changeset 4f945ad7a510ad6dde13353784e45239edcdc14e by Miss Islington (bot) in branch '3.10': bpo-46099: Fix pthread_getcpuclockid test on Solaris (GH-30140) (GH-30183) https://github.com/python/cpython/commit/4f945ad7a510ad6dde13353784e45239edcdc14e -- ___ Python tracker <https://bugs.python.org/issue46099> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46099] Solaris: Fix pthread_getcpuclockid test
Andrew Svetlov added the comment: New changeset a328ad7f9a9b6cd624da5efcc76daf88e0d22312 by Miss Islington (bot) in branch '3.9': bpo-46099: Fix pthread_getcpuclockid test on Solaris (GH-30140) (#30184) https://github.com/python/cpython/commit/a328ad7f9a9b6cd624da5efcc76daf88e0d22312 -- ___ Python tracker <https://bugs.python.org/issue46099> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46128] Strip IsolatedAsyncioTestCase frames from reported stacktraces
New submission from Andrew Svetlov : #7815 supports `__unittest = True` module globals to stripping unittest framework calls from a stacktrace reported by a test failure. IsolatedAsyncioTestCase missed this setup. -- components: Library (Lib) messages: 408887 nosy: asvetlov priority: normal severity: normal status: open title: Strip IsolatedAsyncioTestCase frames from reported stacktraces versions: Python 3.10, Python 3.11, Python 3.9 ___ Python tracker <https://bugs.python.org/issue46128> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46128] Strip IsolatedAsyncioTestCase frames from reported stacktraces
Change by Andrew Svetlov : -- keywords: +patch pull_requests: +28417 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30196 ___ Python tracker <https://bugs.python.org/issue46128> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
New submission from Andrew Svetlov : The change makes tests much better readable. -- components: Tests, asyncio messages: 40 nosy: asvetlov, yselivanov priority: normal severity: normal status: open title: Rewrite asyncio.locks tests with IsolatedAsyncioTestCase versions: Python 3.11 ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Change by Andrew Svetlov : -- keywords: +patch pull_requests: +28419 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30198 ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Change by Andrew Svetlov : -- versions: +Python 3.10, Python 3.9 ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue42413] Replace custom exceptions for timeouts with TimeoutError
Andrew Svetlov added the comment: New changeset da4b214304df38cf1831071804a2b83938f95923 by Kumar Aditya in branch 'main': bpo-42413: Replace `concurrent.futures.TimeoutError` and `asyncio.TimeoutError` with builtin `TimeoutError` (GH-30197) https://github.com/python/cpython/commit/da4b214304df38cf1831071804a2b83938f95923 -- ___ Python tracker <https://bugs.python.org/issue42413> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue42413] Replace custom exceptions for timeouts with TimeoutError
Andrew Svetlov added the comment: Done. Thanks, Kumar! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue42413> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46128] Strip IsolatedAsyncioTestCase frames from reported stacktraces
Andrew Svetlov added the comment: `__unittest = True` flag doesn't work smoothly with async functions, unfortunately. Need to investigate why. -- ___ Python tracker <https://bugs.python.org/issue46128> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Andrew Svetlov added the comment: New changeset 9c06fd89514a9a2865e2adcc472095f6949cecb2 by Andrew Svetlov in branch 'main': bpo-46129: Rewrite asyncio.locks tests with IsolatedAsyncioTestCase (GH-30198) https://github.com/python/cpython/commit/9c06fd89514a9a2865e2adcc472095f6949cecb2 -- ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Change by Andrew Svetlov : -- pull_requests: +28423 pull_request: https://github.com/python/cpython/pull/30202 ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Andrew Svetlov added the comment: New changeset cdb4579607ad5e0a3978ec29b8407bea4d19b4fa by Andrew Svetlov in branch '3.10': [3.10] bpo-46129: Rewrite asyncio.locks tests with IsolatedAsyncioTestCase (GH-30198) (GH-30202) https://github.com/python/cpython/commit/cdb4579607ad5e0a3978ec29b8407bea4d19b4fa -- ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Change by Andrew Svetlov : -- pull_requests: +28425 pull_request: https://github.com/python/cpython/pull/30204 ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Andrew Svetlov added the comment: New changeset f8fce5e4e4338fbe49e5e7a5a856101f69081a08 by Andrew Svetlov in branch '3.9': [3.9] bpo-46129: Rewrite asyncio.locks tests with IsolatedAsyncioTestCase (GH-30198) (GH-30204) https://github.com/python/cpython/commit/f8fce5e4e4338fbe49e5e7a5a856101f69081a08 -- ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45996] Worse error from asynccontextmanager in Python 3.10
Change by Andrew Svetlov : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue45996> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46129] Rewrite asyncio.locks tests with IsolatedAsyncioTestCase
Change by Andrew Svetlov : -- pull_requests: +28426 pull_request: https://github.com/python/cpython/pull/30205 ___ Python tracker <https://bugs.python.org/issue46129> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue45996] Worse error from asynccontextmanager in Python 3.10
Andrew Svetlov added the comment: Sorry, I closed it because async behavior reflects sync version now. If you want to improve both -- you are welcome! Perhaps it is worth another issue with another problem description. -- resolution: fixed -> wont fix ___ Python tracker <https://bugs.python.org/issue45996> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46157] Typo in JSON documentation
Andrew Svetlov added the comment: New changeset 71ef0b4c2b77195bb1adc42602549284f7ee9566 by Kumar Aditya in branch 'main': bpo-46157: fix typo in docs (GH-30237) https://github.com/python/cpython/commit/71ef0b4c2b77195bb1adc42602549284f7ee9566 -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue46157> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46194] Wrong base class for transport returned by loop.create_datagram_endpoint()
New submission from Andrew Svetlov : Selector-based event loops returns `_SelectorDatagramTransport` which inherits `asyncio.Transport` instead of `asyncio.DatagramTransport`. isinstance(transp, asyncio.DatagramTransport) fails. It doesn't affect the actual execution since `transp.sendto()` and `transp.error_received()` are correctly implemented. The bug doesn't affect Windows proactor-based implementation. The fix is relatively easy, a champion is welcome! -- components: asyncio messages: 409309 nosy: asvetlov, yselivanov priority: normal severity: normal status: open title: Wrong base class for transport returned by loop.create_datagram_endpoint() versions: Python 3.10, Python 3.11, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue46194> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46222] posixmodule sendfile FreeBSD's constants update
Andrew Svetlov added the comment: New changeset c960b191b8999a9455bb4b2c50dc224d06fee80c by David CARLIER in branch 'main': bpo-46222: posixmodule sendfile FreeBSD's constants updates. (GH-30327) https://github.com/python/cpython/commit/c960b191b8999a9455bb4b2c50dc224d06fee80c -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue46222> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46222] posixmodule sendfile FreeBSD's constants update
Change by Andrew Svetlov : -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46222> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46238] Improve constants usage / definition in asyncio.windows_events
Andrew Svetlov added the comment: New changeset 1b111338cfe7840feea95e30ea8124063c450c65 by Nikita Sobolev in branch 'main': bpo-46238: reuse `_winapi` constants in `asyncio.windows_events` (GH-30352) https://github.com/python/cpython/commit/1b111338cfe7840feea95e30ea8124063c450c65 -- ___ Python tracker <https://bugs.python.org/issue46238> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46238] Improve constants usage / definition in asyncio.windows_events
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46238> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46239] Incosistent error message in asyncio: windows_events / windows_utils
Andrew Svetlov added the comment: New changeset 5a2a65096c3ec2d37f33615f2a420d2ffcabecf2 by Nikita Sobolev in branch 'main': bpo-46239: improve error message when importing `asyncio.windows_events` (GH-30353) https://github.com/python/cpython/commit/5a2a65096c3ec2d37f33615f2a420d2ffcabecf2 -- ___ Python tracker <https://bugs.python.org/issue46239> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46239] Incosistent error message in asyncio: windows_events / windows_utils
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46239> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46239] Incosistent error message in asyncio: windows_events / windows_utils
Andrew Svetlov added the comment: New changeset cf48a148190a6ccadc144cab2e2046e95c20fb57 by Miss Islington (bot) in branch '3.10': bpo-46239: improve error message when importing `asyncio.windows_events` (GH-30353) (#30388) https://github.com/python/cpython/commit/cf48a148190a6ccadc144cab2e2046e95c20fb57 -- ___ Python tracker <https://bugs.python.org/issue46239> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46278] AbstractEventLoop.call_* should reflect the 'context' argument
New submission from Andrew Svetlov : Actual implementations of asyncio event loops (both Unix and Windows) support contextvars and accept `context` argument in `loop.call_*()` methods. Abstract event loop definition doesn't it. It is not a bug but a signature incompatibility that can embarrass human readers and machine analyzing tools. -- messages: 409829 nosy: asvetlov priority: normal severity: normal status: open title: AbstractEventLoop.call_* should reflect the 'context' argument ___ Python tracker <https://bugs.python.org/issue46278> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46278] AbstractEventLoop.call_* should reflect the 'context' argument
Change by Andrew Svetlov : -- components: +asyncio nosy: +yselivanov versions: +Python 3.10, Python 3.11, Python 3.9 ___ Python tracker <https://bugs.python.org/issue46278> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46278] AbstractEventLoop.call_* should reflect the 'context' argument
Change by Andrew Svetlov : -- type: -> behavior ___ Python tracker <https://bugs.python.org/issue46278> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46278] AbstractEventLoop.call_* should reflect the 'context' argument
Change by Andrew Svetlov : -- keywords: +patch pull_requests: +28633 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30427 ___ Python tracker <https://bugs.python.org/issue46278> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46278] AbstractEventLoop.call_* should reflect the 'context' argument
Andrew Svetlov added the comment: New changeset 861a9aaf0f517623c58ca4eb5588804b2632fcba by Miss Islington (bot) in branch '3.10': bpo-46278: fix typo introduced in GH-30427 (GH-30430) (GH-30431) https://github.com/python/cpython/commit/861a9aaf0f517623c58ca4eb5588804b2632fcba -- ___ Python tracker <https://bugs.python.org/issue46278> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46278] AbstractEventLoop.call_* should reflect the 'context' argument
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46278> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46223] asyncio cause infinite loop during debug
Andrew Svetlov added the comment: I guess applying '@reprlib.recursive_repr' decorator to 'events.Handle.__repr__()' function can help. Could you check, please? -- versions: +Python 3.10, Python 3.11 ___ Python tracker <https://bugs.python.org/issue46223> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46309] Task created by StreamReaderProtocol gets garbage collected.
Andrew Svetlov added the comment: Thanks for the bug report. Seems like your analysis is correct. Could you make a pull request which adds a task reference? -- ___ Python tracker <https://bugs.python.org/issue46309> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23819] test_asyncio fails when run under -O
Andrew Svetlov added the comment: Is anything left to do? -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue23819> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46335] asyncio.create_subprocess_exec throws RuntimeError yet still executes subprogram
Andrew Svetlov added the comment: What do you mean by *process-limited environment*? It is very unusual configuration IMHO. -- ___ Python tracker <https://bugs.python.org/issue46335> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46340] DeprecationWarning emitted when running asyncio tests
Andrew Svetlov added the comment: get_event_loop() is deprecated when there is no running event loop. Otherwise, it is equal to get_running_loop() and IS NOT deprecated. I think there is no reason to replace all occurrences where get_event_loop() works fine. -- ___ Python tracker <https://bugs.python.org/issue46340> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46310] Simplify `for` loop in `.close()` method in `asyncio/windows_events`
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46310> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46310] Simplify `for` loop in `.close()` method in `asyncio/windows_events`
Andrew Svetlov added the comment: New changeset fc75bfb8be8494e22123f2c14d1ab497c77cc22d by Nikita Sobolev in branch 'main': bpo-46310: simplify `for` loop in `asyncio/windows_events` (GH-30334) https://github.com/python/cpython/commit/fc75bfb8be8494e22123f2c14d1ab497c77cc22d -- ___ Python tracker <https://bugs.python.org/issue46310> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46335] asyncio.create_subprocess_exec throws RuntimeError yet still executes subprogram
Andrew Svetlov added the comment: Yes, your environment is clear. As I see from traceback, you are stuck not with new process creation but with new thread starting. The thread is used for waiting for the started process to finish. It is the default configuration. Maybe you need an alternative ChildWatcher setup by `asyncio.get_event_loop_policy().set_child_watcher(watcher)` call. A relatively fresh Linux can use `PidfdChildWatcher`. `MultiLoopChildWatcher` is cross-platform. `SafeChildWatcher` is the oldest and simplest implementation. Please choose one and see how it works for you. -- ___ Python tracker <https://bugs.python.org/issue46335> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46364] asyncio subprocess cannot read from /dev/stdin
Andrew Svetlov added the comment: True. Would you make a pull request that uses socketpair on AIX only? A test for desired behavior is required. -- ___ Python tracker <https://bugs.python.org/issue46364> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46425] Multiple test modules fail to run if invoked directly
Andrew Svetlov added the comment: New changeset 5a5340044ca98cbe6297668d91bccba04b102923 by Nikita Sobolev in branch 'main': bpo-46425: fix direct invocation of `asyncio` tests (#30725) https://github.com/python/cpython/commit/5a5340044ca98cbe6297668d91bccba04b102923 -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue46425> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46469] asyncio Generic classes should return GenericAlias in __class_getitem__
Andrew Svetlov added the comment: New changeset ea5b96842e066623a53015d8b2492ed61a5baf96 by Kumar Aditya in branch 'main': bpo-46469: Make asyncio generic classes return GenericAlias (GH-30777) https://github.com/python/cpython/commit/ea5b96842e066623a53015d8b2492ed61a5baf96 -- ___ Python tracker <https://bugs.python.org/issue46469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46469] asyncio Generic classes should return GenericAlias in __class_getitem__
Andrew Svetlov added the comment: New changeset 90e2998db78cd15e45b3c82f6360ac8841e03945 by Miss Islington (bot) in branch '3.10': [3.10] bpo-46469: Make asyncio generic classes return GenericAlias (GH-30777) (#30784) https://github.com/python/cpython/commit/90e2998db78cd15e45b3c82f6360ac8841e03945 -- ___ Python tracker <https://bugs.python.org/issue46469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46425] Multiple test modules fail to run if invoked directly
Andrew Svetlov added the comment: New changeset 6111d5dee2b24916ff95dba56efc569396a31851 by Miss Islington (bot) in branch '3.10': bpo-46425: fix direct invocation of `asyncio` tests (GH-30725) (#30782) https://github.com/python/cpython/commit/6111d5dee2b24916ff95dba56efc569396a31851 -- ___ Python tracker <https://bugs.python.org/issue46425> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46468] http.server documentation missing default value for port
Andrew Svetlov added the comment: New changeset c8a536624e8f5d6612e3c275c5b19592583a8cf8 by Jelle Zijlstra in branch 'main': bpo-46468: document that "-m http.server" defaults to port 8000 (GH-30776) https://github.com/python/cpython/commit/c8a536624e8f5d6612e3c275c5b19592583a8cf8 -- nosy: +asvetlov ___ Python tracker <https://bugs.python.org/issue46468> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46469] asyncio Generic classes should return GenericAlias in __class_getitem__
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46469> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46468] http.server documentation missing default value for port
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: -Python 3.9 ___ Python tracker <https://bugs.python.org/issue46468> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46468] http.server documentation missing default value for port
Andrew Svetlov added the comment: New changeset b4088801db4b4f56b177b1c01dd873c7922e6a9f by Miss Islington (bot) in branch '3.9': bpo-46468: document that "-m http.server" defaults to port 8000 (GH-30776) (#30786) https://github.com/python/cpython/commit/b4088801db4b4f56b177b1c01dd873c7922e6a9f -- ___ Python tracker <https://bugs.python.org/issue46468> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46468] http.server documentation missing default value for port
Andrew Svetlov added the comment: New changeset 923c994400b3f1c67f95d25c703e131890a16912 by Miss Islington (bot) in branch '3.10': bpo-46468: document that "-m http.server" defaults to port 8000 (GH-30776) (#30787) https://github.com/python/cpython/commit/923c994400b3f1c67f95d25c703e131890a16912 -- ___ Python tracker <https://bugs.python.org/issue46468> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46468] http.server documentation missing default value for port
Change by Andrew Svetlov : -- versions: +Python 3.9 ___ Python tracker <https://bugs.python.org/issue46468> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46425] Multiple test modules fail to run if invoked directly
Andrew Svetlov added the comment: New changeset 101a184d49756043a0c39dde6eca08b1891137a2 by Nikita Sobolev in branch 'main': bpo-46425: fix direct invocation of `test_traceback` (GH-30746) https://github.com/python/cpython/commit/101a184d49756043a0c39dde6eca08b1891137a2 -- ___ Python tracker <https://bugs.python.org/issue46425> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46425] Multiple test modules fail to run if invoked directly
Andrew Svetlov added the comment: New changeset 55f4ec460ee6dcffc26180fd982ad89083c9acb1 by Nikita Sobolev in branch 'main': bpo-46425: use absolute imports in `test_sqlite3` (GH-30676) https://github.com/python/cpython/commit/55f4ec460ee6dcffc26180fd982ad89083c9acb1 -- ___ Python tracker <https://bugs.python.org/issue46425> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46425] Multiple test modules fail to run if invoked directly
Andrew Svetlov added the comment: New changeset 57316c52bae5d6420f5067f3891ec328deb97305 by Nikita Sobolev in branch 'main': bpo-46425: fix direct invocation of `test_importlib` (GH-30682) https://github.com/python/cpython/commit/57316c52bae5d6420f5067f3891ec328deb97305 -- ___ Python tracker <https://bugs.python.org/issue46425> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46425] Multiple test modules fail to run if invoked directly
Andrew Svetlov added the comment: New changeset 1f8014c5b4ea7acee069ca453f6fbcad5990ebf0 by Nikita Sobolev in branch 'main': bpo-46425: fix direct invocation of `test_fileutils` and `test_zoneinfo` (GH-30792) https://github.com/python/cpython/commit/1f8014c5b4ea7acee069ca453f6fbcad5990ebf0 -- ___ Python tracker <https://bugs.python.org/issue46425> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46457] test_unittest: TestAsyncCase.test_debug_cleanup_same_loop() hangs with gc.set_threshold(500)
Change by Andrew Svetlov : -- assignee: -> asvetlov ___ Python tracker <https://bugs.python.org/issue46457> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46483] `pathlib.PurePath.__class_getitem__` does not return `GenericAlias`
Andrew Svetlov added the comment: IIRC it was added to reflect the presence of __class_getitem__ method in typeshed. Please feel free to drop it the method is not really needed. -- ___ Python tracker <https://bugs.python.org/issue46483> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue34680] asyncio event_loop fails when accessed from multiple threads
Andrew Svetlov added the comment: All asyncio loop methods except `loop.call_soon_threadsafe()` should be done from the same thread as been used for the loop creation. Did you violate this rule? -- ___ Python tracker <https://bugs.python.org/issue34680> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41682] [Windows] test_asyncio: Proactor test_sendfile_close_peer_in_the_middle_of_receiving failure
Andrew Svetlov added the comment: Guido, I can not confirm your suggestion but it seems correct to me. -- ___ Python tracker <https://bugs.python.org/issue41682> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue41682] [Windows] : Proactor test_sendfile_close_peer_in_the_middle_of_receiving failure
Andrew Svetlov added the comment: I'm sorry, Victor. -- ___ Python tracker <https://bugs.python.org/issue41682> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue34680] asyncio event_loop fails when accessed from multiple threads
Andrew Svetlov added the comment: BaseEventLoop has _check_loop() method that is closed in debug mode only. UnixEventLoop doesn't call this method for unix-specific API. Adding the check to add_signal_handler()/remove_signal_handler() doesn't hurt, sure. But it doesn't help as the script is executed in non-debug mode. Performing a check on every call_soon() call kills the performance, that's why debug mode is required. -- ___ Python tracker <https://bugs.python.org/issue34680> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46487] `_SSLProtocolTransport` doesn't have the `get_write_buffer_limits` implementation.
Andrew Svetlov added the comment: Technically it should not provide the method according to the current design. get_write_buffer_limits() is not a part of public transports API, this method is defined by private class _FlowControlMixin only. WriteTransport requires only get_write_buffer_size() and set_write_buffer_limits() *setter* but not get_write_buffer_limits() getter. I agree, looks weird. The best solution maybe is adding get_write_buffer_limits() to WriteTransport definition and documenting the change. Would you prepare a pull request? I'm happy to review/merge it. -- ___ Python tracker <https://bugs.python.org/issue46487> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46487] `_SSLProtocolTransport` doesn't have the `get_write_buffer_limits` implementation.
Andrew Svetlov added the comment: Forgot to write, after making the method public we can implement it in SSL transport easily. -- ___ Python tracker <https://bugs.python.org/issue46487> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue34680] asyncio event_loop fails when accessed from multiple threads
Andrew Svetlov added the comment: Please feel free to propose pull request for documentation tuning. -- ___ Python tracker <https://bugs.python.org/issue34680> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46487] `_SSLProtocolTransport` doesn't have the `get_write_buffer_limits` implementation.
Andrew Svetlov added the comment: Sorry, I didn't look into docs before writing. Now we have an interesting situation: the documentation reflects the desired state already but the code is not :) The PR should contain fixes for transports.py and sslproto.py only (plus a blurb record for NEWs). Sorry for misleading you. -- ___ Python tracker <https://bugs.python.org/issue46487> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46568] non awaited coroutines on a IsolatedAsyncioTestCase results on a RuntimeWarning
Andrew Svetlov added the comment: Your code has at least one concurrency problem. Let's look back at forward_stream() function: async def forward_stream(reader: StreamReader, writer: StreamWriter, event: asyncio.Event, source: str): writer_drain = writer.drain() # <--- awaitable is created here while not event.is_set(): try: data = await asyncio.wait_for(reader.read(1024), 1) # <-- CancelledError can be caught here, stack unwinds and writer_drain is never awaited, sure. except asyncio.TimeoutError: continue ... # the rest is not important for this case To solve the problem, you should create writer_drain *before its awaiting*, not before another 'await' call. -- ___ Python tracker <https://bugs.python.org/issue46568> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46568] non awaited coroutines on a IsolatedAsyncioTestCase results on a RuntimeWarning
Andrew Svetlov added the comment: Your version works but can be simplified. Just use await writer.drain() writer.write(data) without grabbing the drainer early. The purpose of the .drain() method is to write pausing if the write buffer side is greater than the high watermark. The 'await writer.drain()' waits until the buffer size became less than low watermark. It prevents uncontrollable write buffer growth if a peer cannot accept TCP message as fast as `writer.write()` sends them. The .drain() call has no hidden process under the hood, there is no need to get write_drain reference as early as possible. It is just 'waiting for a flag'. Also, there is no need for `await write_drain` at the end: asyncio transport sends all data from the internal write buffer before closing (and doesn't do it on 'transport.abort()'). -- ___ Python tracker <https://bugs.python.org/issue46568> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46568] non awaited coroutines on a IsolatedAsyncioTestCase results on a RuntimeWarning
Change by Andrew Svetlov : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue46568> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue46568] non awaited coroutines on a IsolatedAsyncioTestCase results on a RuntimeWarning
Andrew Svetlov added the comment: You are welcome! -- ___ Python tracker <https://bugs.python.org/issue46568> ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com