[issue24429] msvcrt error when embedded
New submission from erik flister: normally, CDLL(find_library('c')) is fine. but when running embedded in a context that uses a different runtime version, this will cause an error (example: http://stackoverflow.com/questions/30771380/how-use-ctypes-with-msvc-dll-from-within-matlab-on-windows/). using ctypes.cdll.msvcrt apparently finds the correct runtime. i was surprised by this, i thought this was supposed to be identical to find_library('c'). in any case, some libraries (uuid.py) use the one that breaks. can you either switch everything to ctypes.cdll.msvcrt, or have find_library('c') change to be identical to it? -- components: Library (Lib), Windows, ctypes messages: 245162 nosy: erik flister, paul.moore, steve.dower, tim.golden, zach.ware priority: normal severity: normal status: open title: msvcrt error when embedded type: behavior versions: Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12833] raw_input misbehaves when readline is imported
Martin Panter added the comment: Actually, there should either be a space before the double-colons, or the full stops should be removed. So either of these options: . . . when a backspace is typed. :: . . . when a backspace is typed:: -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12833 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue672115] Assignment to __bases__ of direct object subclasses
Changes by Antoine Pitrou pit...@free.fr: -- type: behavior - enhancement versions: +Python 3.6 -Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue672115 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
koobs added the comment: Additionally on koobs-freebsd9, in my home directory (which is on ZFS) The buildbot home directories are on UFS -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
koobs added the comment: Larry: The same two hosts that the FreeBSD Python buildslaves run on :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24431] StreamWriter.drain is not callable concurrently
New submission from Martin Teichmann: Currently there is an assert statement asserting that no two tasks (asyncio tasks, that is) can use StreamWriter.drain at the same time. This is a weird limitiation, if there are two tasks writing to the same network socket, there is no reason why not both of them should drain the socket after (or before) writing to it. A simple bug fix is attached. -- components: asyncio files: patch messages: 245172 nosy: Martin.Teichmann, gvanrossum, haypo, yselivanov priority: normal severity: normal status: open title: StreamWriter.drain is not callable concurrently type: behavior versions: Python 3.4, Python 3.5, Python 3.6 Added file: http://bugs.python.org/file39681/patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24431 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
R. David Murray added the comment: Note that the shorter patch means that the test is not actually testing what the comments say it is testing, so either the comments should admit we are checking that the result is something close to what we set, or the longer fix should be used so as to continue to use the more rigorous test on platforms that support it. Ideally the latter. -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24432] Upgrade windows builds to use OpenSSL 1.0.2b
New submission from Alex Gaynor: https://www.openssl.org/news/secadv_20150611.txt -- components: Library (Lib) keywords: security_issue messages: 245173 nosy: alex, christian.heimes, dstufft, giampaolo.rodola, janssen, paul.moore, pitrou, steve.dower, tim.golden, zach.ware priority: normal severity: normal status: open title: Upgrade windows builds to use OpenSSL 1.0.2b ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24432 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
Steve Dower added the comment: msvcrt isn't the right version, it just happens to load. It's actually an old, basically unsupported version. The problem would seem to be that Python 2.7 does not activate its activation context before loading msvcrt90 via ctypes. Eryksun (nosied - hope you're the same one :) ) posted a comment on the SO post with a link to a separate answer that shows how to do it, but it would be better for MATLAB to embed the manifest in their host executable if they're going to load the DLL directly. We could probably also condition uuid to not do that check on Windows, since I don't think those functions will ever exist, at least against 2.7 they won't. -- nosy: +eryksun ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24433] There is no asyncio.ensure_future in Python 3.4.3
New submission from Олег Иванов: Docs claims there there is asyncio.ensure_future https://docs.python.org/3/library/asyncio-task.html?highlight=ensure_future#asyncio.ensure_future but example from docs does'nt work: import asyncio loop = asyncio.get_event_loop() tasks = [ asyncio.ensure_future(print(asasda)), ] loop.run_until_complete(asyncio.wait(tasks)) loop.close() Fails with: AttributeError: 'module' object has no attribute 'ensure_future' -- assignee: docs@python components: Documentation messages: 245176 nosy: docs@python, Олег Иванов priority: normal severity: normal status: open title: There is no asyncio.ensure_future in Python 3.4.3 type: behavior versions: Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24433 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24433] There is no asyncio.ensure_future in Python 3.4.3
Zachary Ware added the comment: The docs also say New in version 3.4.4 :) -- nosy: +zach.ware resolution: - not a bug stage: - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24433 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24432] Upgrade windows builds to use OpenSSL 1.0.2b
Ned Deily added the comment: Marking as release blocker for 3.5.0 -- nosy: +benjamin.peterson, larry, ned.deily priority: normal - release blocker stage: - needs patch versions: +Python 2.7, Python 3.4, Python 3.5, Python 3.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24432 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24400] Awaitable ABC incompatible with functools.singledispatch
Guido van Rossum added the comment: FYI I am on vacation and don't have the bandwidth to look into this, so I hope you will all work together to find a solution without my help. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24400 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
Changes by Caleb Levy caleb.l...@berkeley.edu: -- components: Library (Lib) nosy: clevy, rhettinger, stutzbach priority: normal severity: normal status: open title: ItemsView.__contains__ does not mimic dict_items type: behavior versions: Python 2.7, Python 3.2, Python 3.3, Python 3.4, Python 3.5, Python 3.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24435] Grammar/Grammar points to outdated guide
New submission from Chris Angelico: Grammar/Grammar points to PEP 306, which points instead to the dev guide. The exact link is not provided, but it'd be useful to skip the PEP altogether and just link to https://docs.python.org/devguide/grammar.html in the file. -- messages: 245180 nosy: Rosuav priority: normal severity: normal status: open title: Grammar/Grammar points to outdated guide ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24435 ___ ___ 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 rep...@bugs.python.org http://bugs.python.org/issue22483 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
New submission from Caleb Levy: The current implementation ItemsView.__contains__ reads class ItemsView(MappingView, Set): ... def __contains__(self, item): key, value = item try: v = self._mapping[key] except KeyError: return False else: return v == value ... This poses several problems. First, any non-iterable or iterable not having exactly two elements will raise an error instead of returning false. Second, an ItemsView object is roughly the same as a set of tuple-pairs hashed by the first element. Thus, for example, [a, 1] in d.items() will return False for any dict d, yet in the current ItemsView implementation, this is True. The patch changes behavior to immediately return false for non-tuple items and tuples not of length 2, avoiding unnecessary exceptions. It also adds tests to collections which fail under the old behavior and pass with the update. -- keywords: +patch Added file: http://bugs.python.org/file39682/ItemsView_contains.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23830] Add AF_IUCV support to sockets
Neale Ferguson added the comment: Updated patch against head (96580:3156dd82df2d). Built on s390x and x86_64. Test suite ran on both - tests successfully ignored on x86_64 and passed on s390x. -- versions: +Python 3.6 -Python 3.5 Added file: http://bugs.python.org/file39683/af_iucv_cpython.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23830 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
koobs added the comment: I have tested both patches (test_os by trent) and almostequaltime by harrison on the default branch, and *both* result in test_os passing. They also resolve the test_utime failure reported in bug 24175 and very likely 16287 (born from this issue) -- versions: +Python 3.6 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
koobs added the comment: Hmm, that was supposed to be: issue 24175 and very likely issue 16287 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24430] ZipFile.read() cannot decrypt multiple members from Windows 7zFM
era added the comment: The call to .setpassword() doesn't seem to make any difference. I was hoping it would offer a workaround, but it didn't. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24430 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24430] ZipFile.read() cannot decrypt multiple members from Windows 7zfm
New submission from era: The attached archive from the Windows version of the 7z file manager (7zFM version 9.20) cannot be decrypted into memory. The first file succeeds, but the second one fails. The following small program is able to unzip other encrypted zip archives (tried one created by Linux 7z version 9.04 on Debian from the package p7zip-full, and one from plain zip 3.0-3 which comes from the InfoZip distribution, as well as a number of archives of unknown provenance) but fails on the attached one. from zipfile import ZipFile from sys import argv container = ZipFile(argv[1]) for member in container.namelist(): print(member %s % member) try: extracted = container.read(member) print(extracted %s % repr(extracted)[0:64]) except RuntimeError, err: extracted = container.read(member, 'hello') container.setpassword('hello') print(extracted with password 'hello': %s % repr(extracted)[0:64]) Here is the output and backtrace: member hello/ extracted '' member hello/goodbye.txt Traceback (most recent call last): File ./nst.py, line 13, in module extracted = container.read(member, 'hello') File /usr/lib/python2.6/zipfile.py, line 834, in read return self.open(name, r, pwd).read() File /usr/lib/python2.6/zipfile.py, line 901, in open raise RuntimeError(Bad password for file, name) RuntimeError: ('Bad password for file', 'hello/goodbye.txt') The 7z command is able to extract it just fine: $ 7z -phello x /tmp/hello.zip 7-Zip 9.04 beta Copyright (c) 1999-2009 Igor Pavlov 2009-05-30 p7zip Version 9.04 (locale=en_US.UTF-8,Utf16=on,HugeFiles=on,1 CPU) Processing archive: /tmp/hello.zip Extracting hello Extracting hello/goodbye.txt Extracting hello/hello.txt Everything is Ok Folders: 1 Files: 2 Size: 15 Compressed: 560 -- files: hello.zip messages: 245165 nosy: era priority: normal severity: normal status: open title: ZipFile.read() cannot decrypt multiple members from Windows 7zfm Added file: http://bugs.python.org/file39680/hello.zip ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24430 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24430] ZipFile.read() cannot decrypt multiple members from Windows 7zFM
Changes by era era+pyt...@iki.fi: -- components: +Library (Lib) title: ZipFile.read() cannot decrypt multiple members from Windows 7zfm - ZipFile.read() cannot decrypt multiple members from Windows 7zFM type: - behavior ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24430 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24330] Idle doc: explain Configure Idle not in Options on OSX, etc.
André Freitas added the comment: I have added the explanation in the Docs and IDLE help file. Found also that IDLE help.txt is out of sync with the Docs and needs to be fixed. I will open a new Issue. -- keywords: +patch nosy: +André Freitas Added file: http://bugs.python.org/file39686/patch.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24330 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
Steve Dower added the comment: Python needs to be recompiled to use a different CRT, and that will break all existing extension modules (.pyd's). That said, in some situations it is the right answer, typically because existing extension modules would be broken anyway, but I don't think that applies here. To load msvcr90.dll, you need to declare in your executable which version you want to use using a manifest. This enables side-by-side use of the CRT, so different programs can use different versions and they are all managed by the operating system (for security fixes, etc.). Otherwise, you get hundreds of copies of the CRT and they are likely to be lacking the latest patches. A way to hack in the manifest is to put it alongside the executable. You could take the file from http://stackoverflow.com/questions/27389227/how-do-i-load-a-c-dll-from-the-sxs-in-python/27392347#27392347 and put it alongside the MATLAB executable as matlab.exe.manifest or whatever, which avoids having to get Mathworks involved, and that might allow you to load msvcr90.dll. If they've already embedded a manifest into the executable (which is very likely), then I don't know which one will win or what effects may occur if the original one is ignored. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
erik flister added the comment: it would be better for MATLAB to embed the manifest in their host executable if they're going to load the DLL directly. can you help me understand? as far as i could tell, we need python to use the msvcr*.dll that comes with matlab, not v/v. it's hard (as a customer) to get mathworks (matlab's author) to do anything, but if the fix would best be done by them, they might listen to official python muckity-mucks, especially since their python integration is relatively new... no idea how to find out who to contact there though. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24436] _PyTraceback_Add has no const qualifier for its char * arguments
New submission from Michael Ensslin: The prototype for the public API function _PyTraceback_Add is declared _PyTraceback_Add(char *, char *, int); Internally, its char * arguments are passed verbatim to PyCode_NewEmpty, which takes const char * arguments. The missing 'const' qualifier for the arguments of _PyTraceback_Add thus serves no purpose, and means that C++ code can't invoke the method with const char * arguments. I've attached a proposed patch. I can't think of any negative consequences from adding the 'const' qualifier (famous last words). -- components: Interpreter Core files: const.patch keywords: patch messages: 245185 nosy: mic-e priority: normal severity: normal status: open title: _PyTraceback_Add has no const qualifier for its char * arguments versions: Python 3.5, Python 3.6 Added file: http://bugs.python.org/file39685/const.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24436 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24436] _PyTraceback_Add has no const qualifier for its char * arguments
Changes by Michael Ensslin michael.enss...@googlemail.com: -- type: - enhancement ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24436 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24437] Add information about the buildbot console view and irc notices to devguide
New submission from R. David Murray: Here is a proposed addition to the devguide talking about the buildbot console interface (which I find far more useful than the waterfall view), and mentioning the notifications posted to #python-dev (which is a good way to find out if you broke the buildbots). -- components: Devguide files: buildbot-console-irc.patch keywords: patch messages: 245190 nosy: ezio.melotti, ncoghlan, r.david.murray, willingc priority: normal severity: normal stage: patch review status: open title: Add information about the buildbot console view and irc notices to devguide Added file: http://bugs.python.org/file39687/buildbot-console-irc.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24437 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
erik flister added the comment: thanks - i still don't understand tho. if python would have to be recompiled to use a different crt, why wouldn't matlab? if a manifest could fix matlab, why couldn't one fix python? i ran into all this trying to get shapely to load in matlab, and using msvcrt instead of find_library('c') solved it there: https://github.com/Toblerity/Shapely/issues/104#issuecomment-111050335 that solution seems so much easier than any of this manifest/sxs stuff -- but you're saying it's wrong? sorry i'm slow, never dealt with any of this stuff before... -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
Steve Dower added the comment: python.exe already has the manifest it needs, but it can't be embedded into python27.dll - it has to go into the exe file. That's why Python can't make it so that msvcr90.dll is loaded. Depending on what you're using it for, the C Runtime may keep some state in between function calls. For things like string copying (with no locale) you'll be okay, but most of the complication stuff assumes that every call into the CRT is calling into the *same* CRT. When you load different CRTs at the same time (as is happening here already, or when you load mscvrt.dll directly), you have to be very careful not to intermix them together at all. The most obvious example is open file handles. If you open a file with CRT 9.0 (msvcr90.dll) and then try and read from it with CRT 6.0 (msvcrt.dll), you'll probably crash or at least corrupt something. The same goes for memory allocations - if CRT 9.0 does a malloc() and then CRT 10.0 does the free(), you're almost certainly going to corrupt something because they are not compatible. I suspect Mathworks is relying on people installing Python themselves so they don't have to redistribute it as part of MATLAB, which is totally fine, but you have to be prepared to deal with this situation. If they make their own build, they need to distribute it themselves (easy) and explain to people why numpy doesn't work anymore unless you use their special build of numpy too (ie. because it uses a different CRT). Like I said initially, we would probably accept a patch for uuid.py to skip the CRT scan on Windows, and similar changes like that where appropriate. If you need to be able to load the DLL yourself, you either need to carefully consider how the functions you call may interact with other implementations/versions that may be loaded, or set up the manifest so you can load msvcr90.dll. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
STINNER Victor added the comment: The resolution of os.utime()+os.stat() depends on two things: - resolution of the timestamp on the filesystem used to run test_os (where TESTFN is written) - resolution of the C internal function used by os.utime() os.utime() can have a resolution of 1 ns (ex: it's usually the case on Linux), whereas the FAT filesystem has as resolution of 2 seconds. os.utime() can have a resolution of 1 us (ex: FreeBSD) whereas the ZFS filesystem has a resolution of 1 ns. Currently, test_os.test_*utime*_ns checks that os.utime() is able to copy the timestamp of a file 1 to a file 2. Problem: we don't know the resolution of the timestamp of the file 2. We can get the resolution of the C internal function used by os.utime(). It is implemented in the attached test_os.patch. But it's much more complex to get the timestamp resolution of the filesystem, in a portable way. Random thoughts: * use a timestamp with a resolution of 1 us, smaller than 2^24 to avoid rounding issues. Example: (atime=1.002003, mtime=4.005006)? * compute the effective utime resolution: call os.utime() with a well known timestamp with a resolution of 1 nanosecond (smaller than 2^24 to avoid rounding issues) and call os.stat() to check which digits were preserved test_os must not depend too much on the filesystem. I don't think that we should implement complex code just to check a simple field in the os.stat_result structure. The first idea (call utime with a fixed number, don't rely on an unknown file timestamp) is probably enough. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
Steve Dower added the comment: Ah, it can go into the DLL, and it's already there. The problem may be that there is conflicting information about which resource ID - https://msdn.microsoft.com/en-us/library/aa374224(v=vs.90).aspx says it should be 1 while your link says 2. python27.dll has the manifest as resource 2, so if that is incorrect, then that could be a reason why it's not working. (Looking at the search paths in that link above, there are other potential reasons if it's finding a compatible assembly in the MATLAB folder, but it sounds like that's not the case.) I guess we need someone with the patience to go through and figure out exactly whether it should be 1 or 2. That person is not me, sorry. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
erik flister added the comment: if it can't go into your .dll, what are libraries like shapely supposed to do? tell their users to do all this manifest stuff if they're running embedded? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
erik flister added the comment: relevant: http://stackoverflow.com/questions/30771380/how-use-ctypes-with-msvc-dll-from-within-matlab-on-windows/#comment49619037_30771380 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24436] _PyTraceback_Add has no const qualifier for its char * arguments
Serhiy Storchaka added the comment: LGTM. -- nosy: +Mark.Shannon, pitrou, serhiy.storchaka stage: - commit review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24436 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24429] msvcrt error when embedded
erik flister added the comment: am i reading this wrong, that you can put the manifest into the .dll? https://msdn.microsoft.com/en-us/library/ms235560(v=vs.90).aspx -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24429 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24426] re.split performance degraded significantly by capturing group
Patrick Maupin added the comment: Thank you for the quick response, Serhiy. I had started investigating and come to the conclusion that it was a problem with the compiler rather than the C engine. Interestingly, my next step was going to be to use names for the compiler constants, and then I noticed you did that exact same thing in the 3.6 tree. I will try this out on my use-case tomorrow to make sure it fixes my issue, but now I'm intrigued by the inner workings of this, so I have two questions: 1) Do you know if anybody maintains a patched version of the Python code anywhere? I could put a package up on github/PyPI, if not. 2) Do you know if anybody has done a good writeup on the behavior of the instruction stream to the C engine? I could try to do some work on this and put it with the package, if not, or point to it if so. Thanks and best regards, Pat -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24426 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
STINNER Victor added the comment: test_utime_ns.patch: rewrite _test_utime_ns(). It now uses constant timestamps for atime and mtime with a resolution of 1 us. The test will fail if the internal function of os.utime() has a resolution of 1 sec (utime() with time_t) of if the resolution of filesystem timestamp is worse than 1 us. In practice on buildbots, it looks like the effective resolution of 1 us (FreeBSD, Solaris), 100 ns (Windows) or 1 ns (Linux). So 1 us should work on all buildbot slaves. test_utime_ns.patch doesn't call os.utime() on directories, only on a regular file. I don't understand the purpose of testing with a directory. Are we testing the OS or Python? -- Added file: http://bugs.python.org/file39688/test_utime_ns.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
Martin Panter added the comment: Added a couple suggestions for the test case on Reitveld. -- nosy: +vadmium stage: - patch review ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
STINNER Victor added the comment: almostequaltime.diff is wrong: it allows a different of 10 seconds, whereas the issue is a difference of less than 1000 nanoseconds. test_os.patch looks more correct, but I didn't review the patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24400] Awaitable ABC incompatible with functools.singledispatch
Nick Coghlan added the comment: Low level review sent. Regarding the new opcode, it appears the main thing it provides is early detection of yielding from a coroutine in a normal generator, which is never going to work properly (a for loop or other iterative construct can't drive a coroutine as it expects to be driven), but would be incredibly painful to debug if you did it accidentally. For me, that counts as a good enough reason to add a new opcode during the beta period (just as adding the new types is necessary to fix various problems with the original not-actually-a-different-type implementation). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24400 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
Caleb Levy added the comment: @serhiy.storchaka: I don't think that will work. First of all, x, y = item will raise a ValueError if fed an iterable whose length is not exactly 2, so you would have to check for that. Moreover, if item is something like a dict, for example, then: {a: 1, b: 2} in DictLikeMapping(a=b) could return True, which I don't think would be expected behavior. I'm not terribly fond of the instance check myself, but in this case I can't see any other way to do it: the built in dict_items necessarily consists of *tuples* of key-value pairs. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
Caleb Levy added the comment: Sorry; that should be DictLikeMapping(a=b).items(), where DictLikeMapping is defined in the patch unit tests. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23996] _PyGen_FetchStopIterationValue() crashes on unnormalised exceptions
Changes by Stefan Behnel sco...@users.sourceforge.net: Added file: http://bugs.python.org/file39692/fix_stopiteration_value.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23996 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23996] _PyGen_FetchStopIterationValue() crashes on unnormalised exceptions
Stefan Behnel added the comment: Here are two patches that fix this case, one with special casing, one without. Please choose and apply one. -- Added file: http://bugs.python.org/file39691/fix_stopiteration_value_slow.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23996 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23760] Tkinter in Python 3.4 on Windows don't post internal clipboard data to the Windows clipboard on exit
Changes by Martin Panter vadmium...@gmail.com: -- components: +Windows nosy: +paul.moore, steve.dower, tim.golden, zach.ware -vadmium ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23760 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23760] Tkinter in Python 3.4 on Windows don't post internal clipboard data to the Windows clipboard on exit
Zachary Ware added the comment: I don't believe there's anything Python can do about this, unless it can be confirmed that this is a bug that's been fixed in a more recent version of Tcl/Tk 8.6, in which case we can update our dependency. The easy test for whether updating Tcl/Tk in 3.4 (which uses 8.6.1) will do any good is to try this out with 3.5.0b2 (which uses the latest 8.6.4). -- resolution: - third party status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23760 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
Serhiy Storchaka added the comment: Additional check hits performance. First issue can be resolved by changing code to try: key, value = item except TypeError: return False Second issue can be resolved by comparing not v with value, but (key, v) with item. However I'm not sure that fixing it is worth such complication of the code. -- nosy: +serhiy.storchaka versions: -Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24437] Add information about the buildbot console view and irc notices to devguide
Zachary Ware added the comment: Due to lack of Rietveld, comments in-line (? lines) below: @@ -42,6 +42,24 @@ bbreport.py -q 3.x +* The buildbot console interface at http://buildbot.python.org/all/console + (this link will take a while to load), which provides a summary view of all ? I think it can be assumed that most pages from buildbot.python.org will be slow to load :) ? Perhaps add that comment in the 'The Web interface...' paragraph above? + builders and all branches. This works best on a wide, high resolution + monitor. You can enter the your mercurial username (your name ? s/the your/your/ + your@email) in the 'personalized for' box in the upper right corner to see + the results just for changesets submitted by you. Clicking on the colored + circles will allow you to open a new page containing whatever information + about that particular build is of interest to you. You can also access + builder information by clicking on the builder status bubbles in the top + line. + +If you like IRC, having an irc client open to the #python-dev channel on ? Should 'irc' be capitalized? +irc.freenode.net is useful. If a build fails (and the previous build by the +same builder did not) then a message is posted to the channel. Likewise if a +build passes when the previous one did not, a message is posted. Keeping an ? I think this could be simplified to 'Any time a builder switches from passing ? to failing (or vice versa), a message is posted to the channel.' ? 'switches from passing to failing' is still a bit iffy, though. Maybe ? 'fails a build after a successful build'? Or a simpler 'switches from green to red'? ? That could be construed as color-blind-ist, though :) +eye on the channel after pushing a changeset is a simple way to get notified +that there is something you should look in to. + Some buildbots are much faster than others. Over time, you will learn which ones produce the quickest results after a build, and which ones take the longest time. I had not used the console view before, that's pretty nice! -- nosy: +zach.ware ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24437 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24175] Consistent test_utime() failures on FreeBSD
Changes by Zachary Ware zachary.w...@gmail.com: -- nosy: +zach.ware ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24175 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24303] OSError 17 due to _multiprocessing/semaphore.c assuming a one-to-one Pid - process mapping.
Charles-François Natali added the comment: Here's a patch against 2.7 using _PyOS_URandom(): it should apply as-is to 3.3. -- keywords: +patch nosy: +neologix versions: +Python 3.3 Added file: http://bugs.python.org/file39679/mp_sem_race.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24303 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24307] pip error on windows whose current user name contains non-ascii characters
Changes by Suzumizaki suzumiz...@free.japandesign.ne.jp: -- nosy: +Suzumizaki ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24307 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23391] Documentation of EnvironmentError (OSError) arguments disappeared
Serhiy Storchaka added the comment: It should be documented (if still not) that OSError() constructor can return an instance of OSError subclass, depending on errno value. OSError(errno.ENOENT, 'no such file') FileNotFoundError(2, 'no such file') -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23391 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23391] Documentation of EnvironmentError (OSError) arguments disappeared
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23391 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24420] Documentation regressions from adding subprocess.run()
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24420 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue24434] ItemsView.__contains__ does not mimic dict_items
Changes by Raymond Hettinger raymond.hettin...@gmail.com: -- assignee: - rhettinger ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue24434 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11245] Implementation of IMAP IDLE in imaplib?
R. David Murray added the comment: Are you volunteering to be maintainer, and/or is Piers? If he's changed his mind about the threading, that's good enough for me (and by now he has a lot more experience with the library in actual use). The biggest barrier to inclusion, IMO, is tests and backward compatibility. There have been enough changes that making sure we don't break backward compatibility will be important, and almost certainly requires more tests than we have now. Does imaplib2 have a test suite? We would need to get approval from python-dev, though. We have ongoing problems with packages that are maintained outside the stdlib...but updating to imaplib2 may be better than leaving it without a maintainer at all. Can we get Piers involved in this conversation directly? -- versions: +Python 3.6 -Python 3.4 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11245 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19176] DeprecationWarning for doctype() method when subclassing _elementtree.XMLParser
Martin Panter added the comment: Ideally I guess the Python native behaviour is better: only call target.doctype() if available. It might allow you to easily implement doctype() in both the old and new versions of the API, without worrying about the API being called twice, and without experiencing any DeprecationWarning. But I do not have a real-world use case to demonstrate this, and I don’t think this decision should hold up committing inherit-doctype.v2.patch. They are separate bugs. BTW: Another difference between the implementations is that the C version accepts my !DOCTYPE blaua test case, but the Python version ignores it. It only works with a more elaborate case like !DOCTYPE blaua SYSTEM dtd. I’m no expert, but I think my original XML should be allowed. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19176 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19176] DeprecationWarning for doctype() method when subclassing _elementtree.XMLParser
Changes by Martin Panter vadmium...@gmail.com: -- components: +Extension Modules ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19176 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue19176] DeprecationWarning for doctype() method when subclassing _elementtree.XMLParser
Changes by Martin Panter vadmium...@gmail.com: -- components: +XML -Extension Modules ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue19176 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
STINNER Victor added the comment: test_utime.patch: a much larger patch which rewrites all unit tests on os.utime(). Changes: * Use a fixed timestamp instead of copying timestamps from an existing file. If the timestamp of the original file can have a resolution of 1 nanosecond, os.utime() rounds to a resolution of 1 us on some platforms (when the C function uses a structure with a resolutionf of 1 us). * Use a fixed timestamp with a resolution of 1 us instead of a resolution of 1 ms. * Remove test_1565150(): it's now redundant with test_utime() and many other test_utime_*() tests * Use self.fname instead of __file__ to check if the filesystem supports subsecond resolution: these two files may be in two different filesystems * test_large_time() now checks the filesystem when it is executed, not when the class is defined. This change is to ensure that we are testing the right filesystem. * replace support.TESTFN with self.dirname for readability * move all os.utime() tests in a new dedicated class * _test_utime_current() now get the system clock using time.time() and tolerate a delta of 10 ms instead of 10 seconds: we may increase the delta because of slow buildbots, but I hope that we can find a value smaller than 10 seconds! * Avoid tricky getattr(), it's no more needed * Merge duplicated test_utime_*() and test_utime_subsecond_*() functions * Test also st_atime on when testing os.utime() on a directory * etc. -- Added file: http://bugs.python.org/file39689/test_utime.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue23391] Documentation of EnvironmentError (OSError) arguments disappeared
Martin Panter added the comment: New patch, clarifying that the constructor can raise a subclass. If you still think I need to add something about extra arguments, or how the “args” attribute is set, let me know. -- Added file: http://bugs.python.org/file39690/os-error-args.v3.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue23391 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS (update: and NetBSD w/ FFS, Solaris w/ UFS)
koobs added the comment: Can a test be made to show a message (similar to a skipIf reason=) mentioning that a reduced precision is being used for certain tests? It would be nice not to have to remember this issue as platform support changes (reads: improves) over time. Not withstanding, it's also apparent that there may be an underlying rounding bug or race condition that ultimately causes some of the assertions in this tests to be false, which is the premise behind Harrisons assertAlmostEqual patch (matching other tests) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15745 ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com