[issue30545] Enum equality across modules: comparing objects instead of values

2018-11-16 Thread Sebastian Höfer
Sebastian Höfer added the comment: I ran into the same issue and while I see that this is not a bug I would suggest that this behaviour at least deserves a warning in the documentation under https://docs.python.org/3/library/enum.html#comparisons This unexpected behaviour can not only occur

[issue15566] tarfile.TarInfo.frombuf documentation is out of date

2012-08-06 Thread Sebastian Ramacher
New submission from Sebastian Ramacher: tarfile.TarInfo.frombuf has gained two more parameters: encoding and errors. The documentation of frombuf claims that the only parameter is buf, which is not true anymore. -- assignee: docs@python components: Documentation messages: 167553 nosy

[issue8800] add threading.RWLock

2012-09-29 Thread Sebastian Noack
Sebastian Noack added the comment: I would love to see a reader/writer lock implementation shipped with Python's threading (and multiprocessing) module. But I have some issues with the patch: 1. I would avoid the terms 'read' and 'write' as those terms are referring

[issue8800] add threading.RWLock

2012-09-29 Thread Sebastian Noack
Sebastian Noack added the comment: Using a lock as context manager is the same as calling lock.acquire(blocking=True) and it will in fact block while waiting for an other thread to release the lock. In your code, the internal lock is indeed just hold for a very short period of time while

[issue8800] add threading.RWLock

2012-09-29 Thread Sebastian Noack
Sebastian Noack added the comment: I've added a new patch, that implements a shared/exclusive lock as described in my comments above, for the threading and multiprocessing module. -- Added file: http://bugs.python.org/file27350/Added-ShrdExclLock-to-threading-and-multiprocessing.

[issue8800] add threading.RWLock

2012-09-30 Thread Sebastian Noack
Sebastian Noack added the comment: I was just waiting for a comment pointing out, that my patch comes without tests. :) Note that we are still discussing the implementation and this patch is just a proof of concept. And since the way it is implemented and the API it provides could still

[issue8800] add threading.RWLock

2012-10-01 Thread Sebastian Noack
Sebastian Noack added the comment: Yes, you could also look at the shared/exclusive lock as one lock with different states. But this approach is neither more common, have a look at Java's ReadWriteLock [1] for example, which works just like my patch does, except that a factory is ret

[issue8800] add threading.RWLock

2012-10-01 Thread Sebastian Noack
Sebastian Noack added the comment: @richard: I'm sorry, but both of my patches contain changes to 'Lib/threading.py' and can be applied on top of Python 3.3.0. So can you explain what do you mean, by missing the changes

[issue8800] add threading.RWLock

2012-10-01 Thread Sebastian Noack
Sebastian Noack added the comment: > If you want to argue it this way, I counter that the attributes > "shared" and "exclusive" apply to the type of "access to the > protected object" you are talking about, and yet, the name suggest > that they are att

[issue8800] add threading.RWLock

2012-10-01 Thread Sebastian Noack
Sebastian Noack added the comment: I would love to see how other people would implement a shared/exclusive lock that can be acquired from different processes. However it really seems that nobody did it before. If you know a reference implementation I would be more than happy. There are

[issue8800] add threading.RWLock

2012-10-01 Thread Sebastian Noack
Sebastian Noack added the comment: Thanks, but as I already said there are a lot of implementations for shared/exclusive lock that can be acquired from different threads. But we need with threading as well as with multiprocessing. And by the way POSIX is the standard for implementing UNIX

[issue8800] add threading.RWLock

2012-10-02 Thread Sebastian Noack
Sebastian Noack added the comment: Exactly, with my implemantation "the lock acquired first will be granted first". There is no way that either shared nor exclusive locks can starve, and therefore it should satisfy all use cases. Since you can only share simple datastructures lik

[issue8800] add threading.RWLock

2012-10-02 Thread Sebastian Noack
Sebastian Noack added the comment: @Kristján: Uhh, that is a huge amount of code, more than twice as much (don't counting tests) as my implementation, to accomplish the same. And it seems that there is not much code shared between the threading and multiprocessing implementation. And for

[issue21281] DEBUGGING: Simultaneous stopping of all threads on breakpoint and switching between threads

2014-04-17 Thread Sebastian Jylanki
New submission from Sebastian Jylanki: When debugging with some of the other very popular tools like GDB all the threads are halted when a breakpoint is hit on any of the threads. Then threads can be switched and analyzed separately at the current state of execution. When debugging with PDB

[issue21436] bring back importlib.load_source() et al.

2014-05-05 Thread Sebastian Rittau
New submission from Sebastian Rittau: It was very easy to load plugin files in Python 2: import imp my_module = imp.load_source("what.ever", "foo.py") Unfortunately, this became much more obscure in Python 3.3: import importlib.machinery loader = importlib.machin

[issue21594] asyncio.create_subprocess_exec raises OSError

2014-05-28 Thread Sebastian Kreft
New submission from Sebastian Kreft: In some cases asyncio.create_subprocess_exec raises an OSError because there are no file descriptors available. I don't know if that is expected, but IMO I think it would be better to just block until the required numbers of fds are available. Othe

[issue21595] Creating many subprocess generates lots of internal BlockingIOError

2014-05-28 Thread Sebastian Kreft
New submission from Sebastian Kreft: Using the asyncio.create_subprocess_exec, generates lost of internal error messages. These messages are: Exception ignored when trying to write to the signal wakeup fd: BlockingIOError: [Errno 11] Resource temporarily unavailable Getting the messages

[issue21596] asyncio.wait fails when futures list is empty

2014-05-28 Thread Sebastian Kreft
New submission from Sebastian Kreft: Passing an empty list/set of futures to asyncio.wait raises an Exception, which is a little annoying in some use cases. Probably this was the intended behavior as I see there's a test case for that. If such, then I would propose to document that beh

[issue21594] asyncio.create_subprocess_exec raises OSError

2014-06-02 Thread Sebastian Kreft
Sebastian Kreft added the comment: I agree that blocking is not ideal, however there are already some other methods that can eventually block forever, and for such cases a timeout is provided. A similar approach could be used here. I think this method should retry until it can actually access

[issue21637] Add a warning section exaplaining that tempfiles are opened in binary mode

2014-06-02 Thread Sebastian Kreft
New submission from Sebastian Kreft: Although it is already explained that the default mode of the opened tempfiles is 'w+b' a warning/notice section should be included to make it clearer. I think this is important as the default for the open function is to return strings and not

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-03 Thread Sebastian Kreft
Sebastian Kreft added the comment: I'm using the Python 3.4.1 compiled from source and I'm may be hitting this issue. My workload is launching two subprocess in parallel, and whenever one is ready, launches another one. In one of the runs, the whole process got stuck after launchin

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-04 Thread Sebastian Kreft
Sebastian Kreft added the comment: @haypo: I've reproduced the issue with both 2 and 3 processes in parallel. @glangford: the wait is actually returning after the 15 seconds, although nothing is reported as finished. So, it's getting stuck in the while loop. However, I imagine th

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-05 Thread Sebastian Kreft
Sebastian Kreft added the comment: The Executor is still working (but I'm using a ThreadPoolExcutor). I can dynamically change the number of max tasks allowed, which successfully fires the new tasks. After 2 days running, five tasks are in this weird state. I will change the co

[issue21596] asyncio.wait fails when futures list is empty

2014-06-06 Thread Sebastian Kreft
Sebastian Kreft added the comment: LGTM. -- ___ Python tracker <http://bugs.python.org/issue21596> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-10 Thread Sebastian Kreft
Sebastian Kreft added the comment: I was able to recreate the issue again, and now i have some info about the offending futures: State: RUNNING, Result: None, Exception: None, Waiters: 0, Cancelled: False, Running: True, Done: False The information does not seem very relevant. However, I can

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-16 Thread Sebastian Kreft
Sebastian Kreft added the comment: Any ideas how to debug this further? In order to overcome this issue I have an awful workaround that tracks the maximum running time of a successful task, and if any task has been running more than x times that maximum I consider it defunct, and increase the

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-16 Thread Sebastian Kreft
Sebastian Kreft added the comment: I'm running actually millions of tasks, so sending them all at once will consume much more resources than needed. The issue happens no only with 2 tasks in parallel but with higher numbers as well. Also your proposed solution, has the problem that whe

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-06-18 Thread Sebastian Kreft
Sebastian Kreft added the comment: @glangford: Is that really your recommendation, to switch to celery? Python 3.4.1 should be production quality and issues like this should be addressed. Note that I've successfully run millions of tasks using the same method, the only difference being

[issue16525] wave file module does not support 32bit float format

2012-11-21 Thread Sebastian Kraft
New submission from Sebastian Kraft: The wave module cannot read audio WAV files containing 32bit float values. This is a very common file type for professional audio! There has already been a patch some years ago which works fine but was finally not applied. I can confirm that it does not

[issue16525] wave file module does not support 32bit float format

2012-11-24 Thread Sebastian Kraft
Sebastian Kraft added the comment: Write support is no problem, I will add this. >From reading the spec in the link you provided I think the implementation in >general is OK. Everything apart WAVE_FORMAT_PCM should have an extension size cbSize, that's right. But only WAVE_FORMAT

[issue16525] wave file module does not support 32bit float format

2012-11-24 Thread Sebastian Kraft
Sebastian Kraft added the comment: I will create a patch together with a testset of example files and also fill out the agreement. BTW: readframes() returns bad data for 24bit PCM if big_endian==True. Furthermore IMO it doesn't make sense to return a byte stream in little endian order

[issue16525] wave file module does not support 32bit float format

2012-11-25 Thread Sebastian Kraft
Sebastian Kraft added the comment: Attached to this mail you find my patch for the implementation of support for 8, 16, 24, 32 bit signed int PCM and 32, 64 bit float. 24bit on big endian systems is buggy, but this will be reported in another ticket. The modified test checks all number

[issue16525] wave file module does not support 32bit float format

2012-12-01 Thread Sebastian Kraft
Sebastian Kraft added the comment: Contribution agreement is now attached to my account. So the review can start ;) -- ___ Python tracker <http://bugs.python.org/issue16

[issue16664] [PATCH] Test Glob: files starting with .

2012-12-11 Thread Sebastian Kreft
New submission from Sebastian Kreft: Please find attached a patch to improve the test cases for the glob module. It adds test cases for files starting with '.'. -- components: Tests files: python.patch keywords: patch messages: 177345 nosy: Sebastian.Kreft priority: norma

[issue16664] [PATCH] Test Glob: files starting with .

2012-12-13 Thread Sebastian Kreft
Sebastian Kreft added the comment: The docs don't say anything about it. However the code is there (docs bug probably). See the following lines in glob.py: 57 if pattern[0] != '.': 58 names = [x for x in names if x[0] != '.'] 59 return fnma

[issue16845] warnings.simplefilter should validate input

2013-01-02 Thread Sebastian Berg
New submission from Sebastian Berg: `warnings.simplefilter` does not validate that the category passed in is actually a class. This means that an invalid category leads to a `TypeError` whenever a warning would otherwise occur due to `issubclass` check failing. It is a very small thing, but

[issue16525] wave file module does not support 32bit float format

2013-01-17 Thread Sebastian Kraft
Sebastian Kraft added the comment: Any news or feedback regarding my patch? -- ___ Python tracker <http://bugs.python.org/issue16525> ___ ___ Python-bugs-list m

[issue21899] Futures are not marked as completed

2014-07-01 Thread Sebastian Kreft
New submission from Sebastian Kreft: With Python 3.4.1 compiled from source, I'm having an issue in which every now and then some Futures are not marked as completed even though the underlying workload is done. My workload is launching two subprocess in parallel, and whenever one is

[issue21899] Futures are not marked as completed

2014-07-16 Thread Sebastian Kreft
Sebastian Kreft added the comment: After more testing I finally found that in fact the process is not being killed. That means that there is no problem with the futures. But instead it is probably related with subprocess deadlocking, as the problematic process does not consume any CPU. Sorry

[issue20319] concurrent.futures.wait() can block forever even if Futures have completed

2014-07-16 Thread Sebastian Kreft
Sebastian Kreft added the comment: Disregard the last messages, It seems to be a deadblocking due to subprocess. -- ___ Python tracker <http://bugs.python.org/issue20

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-19 Thread Sebastian Berg
New submission from Sebastian Berg: In NumPy we decided some time ago that if you have a multi dimensional buffer, shaped for example 1x10, then this buffer should be considered both C- and F-contiguous. Currently, some buffers which can be used validly in a contiguous fashion are rejected

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-19 Thread Sebastian Berg
Sebastian Berg added the comment: #12845 should be closed, seems like a bug in some old version. The definition now is simply that the array is contiguous if you can legally access it in a contiguous fashion. Which means first stride is itemsize, second is itemsize*shape[0] for Fortran

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-19 Thread Sebastian Berg
Sebastian Berg added the comment: To be clear, the important part here, is that to me all elements *can* be accessed using that scheme. It is not correct to assume that `stride[-1]` or `stride[0]` is actually equal to `itemsize`. In other words, you have to be able to pass the pointer to the

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-19 Thread Sebastian Berg
Sebastian Berg added the comment: Well, the 9223372036854775807 is certainly no good for production code and we would never have it in a release version, it is just there currently to expose if there are more problems. However I don't care what happens on overflow (as long as it is n

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-20 Thread Sebastian Berg
Sebastian Berg added the comment: An extra dimension is certainly not irrelevant! The strides *are* valid and numpy currently actually commonly creates such arrays when slicing. The question is whether or not we want to ignore them for contiguity checks even if they have no effect on the memory

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-21 Thread Sebastian Berg
Sebastian Berg added the comment: I am very sorry. The attached patch fixes this (not sure if quite right, but if anything should be more general then necessary). One test fails, but it looks like exactly the intended change. -- Added file: http://bugs.python.org/file36676/relaxed

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-21 Thread Sebastian Berg
Changes by Sebastian Berg : Added file: http://bugs.python.org/file36677/relaxed-strides-checking.patch ___ Python tracker <http://bugs.python.org/issue22445> ___ ___

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-21 Thread Sebastian Berg
Changes by Sebastian Berg : Added file: http://bugs.python.org/file36678/contiguous.py ___ Python tracker <http://bugs.python.org/issue22445> ___ ___ Python-bugs-list m

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-21 Thread Sebastian Berg
Changes by Sebastian Berg : Added file: http://bugs.python.org/file36680/contiguous.py ___ Python tracker <http://bugs.python.org/issue22445> ___ ___ Python-bugs-list m

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-09-22 Thread Sebastian Berg
Sebastian Berg added the comment: Yeah, the code does much the same as the old numpy code (at least most of the same funny little things, though I seem to remember the old numpy code had something yet a bit weirder, would have to check). To be honest, I do not know. It isn't implausible

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-10-02 Thread Sebastian Berg
Sebastian Berg added the comment: Numpy 1.9. was only released recently, so 1.10. might be a while. If no problems show up during release or until then, we will likely switch it by then. But that could end up being a year from now, so I am not sure if 3.6 might not fit better. The problems

[issue17140] Provide a more obvious public ThreadPool API

2014-01-14 Thread Sebastian Rodriguez
Changes by Sebastian Rodriguez : -- nosy: +srodriguez ___ Python tracker <http://bugs.python.org/issue17140> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue20504] cgi.FieldStorage, multipart, missing Content-Length

2014-02-03 Thread Sebastian Rittau
New submission from Sebastian Rittau: Consider the attached test case. This test will run fine with Python 2.7, but will fail with Python 3.3. If cgi.FieldStorage() tries to parse a multipart request without a Content-Length header in the main section, segments will have a length of 0

[issue20504] cgi.FieldStorage, multipart, missing Content-Length

2014-02-26 Thread Sebastian Rittau
Changes by Sebastian Rittau : -- type: -> behavior ___ Python tracker <http://bugs.python.org/issue20504> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue16525] wave file module does not support 32bit float format

2014-03-02 Thread Sebastian Kraft
Sebastian Kraft added the comment: After the last changes in the development version of python 3.4 the patch cannot be applied anymore. As the the other audio file readers and the wave module share a common API it may be not desireable to simply enhance the wave module with support for

[issue6952] deprecated conversion from string constant to char *

2009-09-21 Thread Sebastian Ramacher
Changes by Sebastian Ramacher : -- nosy: +sebastinas ___ Python tracker <http://bugs.python.org/issue6952> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7036] Doc/reference/datamodel: Slots description needs update

2009-10-02 Thread Sebastian Thiel
New submission from Sebastian Thiel : The section starting with: "If a class defines a slot also defined in a base class, the instance variable defined by the base class slot is inaccessible rendering the meaning of the program undefined. [...]" would need to be revisited as it c

[issue7036] Doc/reference/datamodel: Slots description needs update

2009-10-02 Thread Sebastian Thiel
Sebastian Thiel added the comment: Additional Information: "multiple bases have instance lay-out conflict" This happens only if I add __slots__ to the bases so that there is no dict. I can reproduce this easily by indirectly deriving a class from two bases that both define the same

[issue7382] bytes.__getnewargs__ is broken; copy.copy() therefore doesn't work on bytes, and bytes subclasses can't be pickled by default

2009-11-23 Thread Sebastian Hagen
New submission from Sebastian Hagen : In either python 3.0, bytes instances cannot be copied, and (even trivial) bytes subclasses cannot be unpickled unless they explicitly override __getnewargs__() or __reduce_ex__(). Copy problem: >>> import copy; copy.copy(b'foo') Tracebac

[issue7560] Various filename-taking posix methods don't like bytes / buffer objects.

2009-12-21 Thread Sebastian Hagen
New submission from Sebastian Hagen : Most of the functions in Python's stdlib that take filename parameters allow for those parameters to be buffer (such as bytes, bytearray, memoryview) objects. This is useful for various reasons, among them that on Posix-likes, file- and pathnames ultim

[issue7560] Various filename-taking posix methods don't like bytes / buffer objects.

2009-12-21 Thread Sebastian Hagen
Changes by Sebastian Hagen : -- type: -> behavior ___ Python tracker <http://bugs.python.org/issue7560> ___ ___ Python-bugs-list mailing list Unsubscri

[issue7560] Various filename-taking posix methods don't like bytes / buffer objects.

2009-12-21 Thread Sebastian Hagen
Changes by Sebastian Hagen : Removed file: http://bugs.python.org/file15659/posix_fn_bytes_01.patch ___ Python tracker <http://bugs.python.org/issue7560> ___ ___ Pytho

[issue7560] Various filename-taking posix methods don't like bytes / buffer objects.

2009-12-21 Thread Sebastian Hagen
Sebastian Hagen added the comment: I'm taking that patch back. More testing would have been in order before posting; sorry for that, will repost once I've got the obvious problems worked out. -- ___ Python tracker <http://bugs.python.

[issue7560] Various filename-taking posix methods don't like bytes / buffer objects.

2009-12-21 Thread Sebastian Hagen
Sebastian Hagen added the comment: And further testing reveals that all of this has in fact already been fixed in trunk. I assumed it hadn't been, because the code for at least some of the relevant functions in Modules/_posixmodule.c is the same as in 3.1.1; I didn't know that the sam

[issue7560] Various filename-taking posix methods don't like bytes / buffer objects.

2009-12-21 Thread Sebastian Hagen
Changes by Sebastian Hagen : -- status: open -> closed versions: -Python 3.2 ___ Python tracker <http://bugs.python.org/issue7560> ___ ___ Python-bugs-list mai

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-21 Thread Sebastian Hagen
New submission from Sebastian Hagen : Various functions in the 'posix' module that take filename arguments accept bytearray values for those arguments, and mishandle those objects in a way that leads to segfaults. Python 3.1 (r31:73572, Jul 23 2009, 23:41:26) [GCC 4.3.3] on linux2

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-22 Thread Sebastian Hagen
Sebastian Hagen added the comment: Not exactly. The last part fixes the second problem, which you get for non-zero-length bytearrays. But without the first fix, zero-length bytearrays still lead to a crash: Python 3.2a0 (py3k:77001M, Dec 22 2009, 18:17:08) [GCC 4.3.4] on linux2 Type "

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-22 Thread Sebastian Hagen
Sebastian Hagen added the comment: You're correct about PyUnicode_FSConverter(), which is why the very first part of my patch fixes that function. Only fixing that one will get rid of the segfaults, but also lead to incorrect error reporting for the zero-length bytearray case; the byte

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-22 Thread Sebastian Hagen
Sebastian Hagen added the comment: Correction: "Only fixing that one will get rid of the segfaults" ... well, for mkdir() on GNU/Linux, anyway. POSIX.1-2008 doesn't specify what happens if you call mkdir() with a NULL pointer, so I guess other conforming implementations migh

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-22 Thread Sebastian Hagen
Sebastian Hagen added the comment: I've glanced at some of the other PyByteArray_AS_STRING() (and PyByteArray_AsStr(), which inherits this behaviour) uses in the stdlib. By far the heaviest user is bytearrayobject.c; aside from that, there's by my count only 24 uses in current trunk.

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-22 Thread Sebastian Hagen
Sebastian Hagen added the comment: Well, it doesn't *need* to accept them ... but it would certainly be nice to have. If you've already got the filename in a bytearray object for some reason, being able to pass it through directly saves you both a copy and the explicit conversion code

[issue7561] Filename-taking functions in posix segfault when called with a bytearray arg.

2009-12-22 Thread Sebastian Hagen
Sebastian Hagen added the comment: Oh, and *forcing* use of the PEP 383 hack for such interfaces would really be the Wrong Thing. Byte sequences are the natural (and most efficient, and least prone to misunderstandings) way to store filenames on a posix-like. Storing them as unicode-except-not

[issue5322] Python 2.6 object.__new__ argument calling autodetection faulty

2009-03-24 Thread Sebastian Ramacher
Changes by Sebastian Ramacher : -- nosy: +sebastinas ___ Python tracker <http://bugs.python.org/issue5322> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue5589] Wrong dump of floats

2009-03-28 Thread Sebastian Billaudelle
New submission from Sebastian Billaudelle : Hi there, I just recognized a weird behaviour of the json module... Dumpig a float like 0.1 I get some crazy output. Here is an example: >>> import json >>> json.dumps([.1]) '[0.10001]' Very simple

[issue6243] getkey() can segfault in combination with curses.ungetch()

2009-06-08 Thread Sebastian Ramacher
Changes by Sebastian Ramacher : -- nosy: +sebastinas ___ Python tracker <http://bugs.python.org/issue6243> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue2736] datetime needs an "epoch" method

2010-05-22 Thread Sebastian Rittau
Changes by Sebastian Rittau : -- nosy: -srittau ___ Python tracker <http://bugs.python.org/issue2736> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue7279] decimal.py: == and != comparisons involving NaNs

2013-02-13 Thread Sebastian Berg
Sebastian Berg added the comment: This is closed, and maybe I am missing something. But from a general point of view, why does hashing of NaN not raise an error as it did for decimals, i.e. why was this not resolved exactly the other way around? I am mostly just wondering about this it is not

[issue7279] decimal.py: == and != comparisons involving NaNs

2013-02-13 Thread Sebastian Berg
Sebastian Berg added the comment: Thanks, yes, you are right, should have googled a bit more anyway. Though I did not find much on the hashable vs unhashable itself, so if I ever stumble across it again, I will write a mail... -- ___ Python tracker

[issue16525] wave file module does not support 32bit float format

2013-02-16 Thread Sebastian Kraft
Changes by Sebastian Kraft : Removed file: http://bugs.python.org/file28122/wave_float_issue16525.patch ___ Python tracker <http://bugs.python.org/issue16525> ___ ___

[issue16525] wave file module does not support 32bit float format

2013-02-16 Thread Sebastian Kraft
Sebastian Kraft added the comment: Thanks for the hint Harvey! I have updated my patch to include your changes, but only applied the second hunk for the following reasons: Wave_read should not assume any wave format, as it is expected to open a file during initialization. So actually the only

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-10-15 Thread Sebastian Berg
Sebastian Berg added the comment: @pitrou, yes of course. This would make python do the same thing as numpy does (currently only with that compile flag given). About the time schedule, I think I will try to see if some other numpy dev has an opinion. Plus, should look into documenting it for

[issue22445] Memoryviews require more strict contiguous checks then necessary

2014-10-20 Thread Sebastian Berg
Sebastian Berg added the comment: Antoine, sounds good to me, I don't mind this being in python rather sooner then later, for NumPy itself it does not matter I think. I just wanted to warn that there were problems when we first tried to switch in NumPy, which, if I remember correctly, i

[issue23301] ConfigParser does not handle square brackets in section name

2015-01-22 Thread Sebastian Bank
New submission from Sebastian Bank: ConfigParser parses section lines containing square brackets like '[spam [eggs] spam]' up to the first instead of the last occurrence of ']' preventing roundtrips: >>> s = StringIO() >>> c1 = ConfigParser() >>&g

[issue20923] ConfigParser should nested [] in section names.

2015-01-29 Thread Sebastian Bank
Sebastian Bank added the comment: If this is the intended behaviuour, I guess ConfigParser should warn the user if he supplies a section name with a ']' (prevent failed roundtrips). See http://bugs.python.org/issue23301 The current behaviour looks like the opposite of Po

[issue23352] PyBuffer_IsContiguous() sometimes returns wrong result if suboffsets != NULL

2015-01-30 Thread Sebastian Berg
Sebastian Berg added the comment: Numpy does not understand suboffsets. The buffers we create will always have them NULL. The other way around To be honest, think it is probably ignoring the whole fact that they might exist at all :/, really needs to be fixed if it is the case

[issue23352] PyBuffer_IsContiguous() sometimes returns wrong result if suboffsets != NULL

2015-02-01 Thread Sebastian Berg
Sebastian Berg added the comment: I do not have an opinion either way, but I do think there is a small difference here compared to the other issue. With the other issue, there are cases where we cannot set the strides correctly. If you ask numpy directly whether the array is contiguous (or

[issue24527] The MimeTypes class cannot ignore global files per instance

2015-06-29 Thread Sebastian Noack
New submission from Sebastian Noack: In order to prevent the mimetypes module from considering global files and registry entries, you have to call mimetypes.init([]). However, this will enforce that behavior globally, and only works if the module wasn't initialized yet. There is a

[issue24797] email.header.decode_header return type is not consistent

2015-08-05 Thread Sebastian Kreft
New submission from Sebastian Kreft: The return type of email.header.decode_header is not consistent. When there are encoded parts the return type is a list of (bytes, charset or None) (Note that the documentation says it is a list of (str, charset)). However, when there are no encoded parts

[issue24797] email.header.decode_header return type is not consistent

2015-08-17 Thread Sebastian Kreft
Sebastian Kreft added the comment: And what would the new API be? There is nothing pointing to it either in the documentation https://docs.python.org/3.4/library/email.header.html or source code. -- ___ Python tracker <http://bugs.python.

[issue25142] Misleading error when initing ImportError

2015-09-16 Thread Sebastian Kreft
New submission from Sebastian Kreft: ImportError now supports the keyword arguments name and path. However, when passing invalid keyword arguments, the reported error is misleading, as shown below. In [1]: ImportError('lib', name='lib') Out[1]: ImportError('lib&#x

[issue20504] cgi.FieldStorage, multipart, missing Content-Length

2015-10-08 Thread Sebastian Rittau
Sebastian Rittau added the comment: Is there any progress on this? The fix seems trivial. -- ___ Python tracker <http://bugs.python.org/issue20504> ___ ___ Pytho

[issue20923] ConfigParser should nested [] in section names.

2015-11-24 Thread Sebastian Bank
Sebastian Bank added the comment: Terry: I am not so sure about that interpretation. Do we agree that the INI-files are the data/message? ConfigParser refuses to accept dirty INI-Files (with ']' in section names) but will produce this kind of files. I we see the arguments given to Co

[issue25898] Check for subsequence inside a sequence

2015-12-17 Thread Sebastian Linke
New submission from Sebastian Linke: With the attached patch I propose to add a new function to the "collections" module. It is meant to be used for determining whether a given subsequence is part of a particular sequence (with respect to the ordering of the subsequence). Doing th

[issue25898] Check for subsequence inside a sequence

2015-12-18 Thread Sebastian Linke
Sebastian Linke added the comment: @Josh What is the point of using iterators here? If the user wants an iterator to be checked then he can throw that iterator right away because it was exhausted by the function. I think that in most cases the user wants to do some postprocessing on a

[issue25898] Check for subsequence inside a sequence

2015-12-20 Thread Sebastian Linke
Sebastian Linke added the comment: Slightly modified the implementation to return the index rather than a boolean. -- Added file: http://bugs.python.org/file41374/subseq_index.patch ___ Python tracker <http://bugs.python.org/issue25

[issue26123] http.client status code constants incompatible with Python 3.4

2016-01-15 Thread Sebastian Rittau
New submission from Sebastian Rittau: The HTTP status code constants in Python 3.5 http.client are not compatible with the constants in Python 3.4, since the str() behaviour is different. This breaks code: srittau@moby:~$ python3.5 Python 3.5.1+ (default, Jan 13 2016, 15:09:18) [GCC 5.3.1

[issue26123] http.client status code constants incompatible with Python 3.4

2016-01-15 Thread Sebastian Rittau
Sebastian Rittau added the comment: It is no doubt that is easy to work around. Once I found the problem it took about five minutes to fix it and roll a new release. And of course for Python 3.5+ code it is better to use the enum http.HTTPStatus directly (I actually like that enum a lot). But

[issue26327] File > Save in IDLE shell window not working

2016-02-10 Thread Sebastian Bank
New submission from Sebastian Bank: Under Python 2.7.11 (Win 7), saving of the IDLE shell output produces no file if the output contains non-ASCII characters, e.g. after doing (before this, it does work): >>> print u'sp\xe4m' späm >>> When saving (generally),

[issue28375] cgi.py spam in Apache server logs

2016-10-06 Thread Sebastian Rittau
New submission from Sebastian Rittau: I am using cgi.py in WSGI applications, using Apache and mod_wsgi. Unfortunately cgi.py keeps spamming the error log with messages like the following: Exception ignored in: Traceback (most recent call last): File "/usr/lib/python3.5/cgi.py"

[issue28387] double free in io.TextIOWrapper

2016-10-07 Thread Sebastian Cufre
New submission from Sebastian Cufre: We have found that you can produce a crash when an instance of _io.TextIOWrapper is being deallocated while there's another thread invoking the garbage collector. I've attached a simple script that should reproduce the issue (textiowrappe

<    1   2   3   4   >