sebastian added the comment:
thank you very much...
but: [...] the class and arguments are evaluated using the
logging package's namespace. [...]
does this mean, it is not possible to use user-defined handlers,
naturally residing outside python's class library (and logging pack
New submission from Sebastian :
Hi all,
I found a bug in the exception handler. When I
start the app without any arguments I get an
output I expect:
__main__:2:DeprecationWarning: Deprecated function.
When I run the app with arguments, the arguments
are printed somehow in the exception output
Sebastian added the comment:
Could anyone please correct the title? Thx :)
--
___
Python tracker
<http://bugs.python.org/issue8787>
___
___
Python-bugs-list m
Sebastian added the comment:
Oh, damn. I really forgot the argv filename thing. Nevermind :)
But back to topic. __file__ might be not the best solution for that. What does
Python when embedded, and __file__ is not set? That can happen when the source
of your code is not a file (multiline
Sebastian added the comment:
attached a patch for this issue now.
Now it first uses the name of the script,
instead of __file__.
--
keywords: +patch
Added file: http://bugs.python.org/file17461/_warnings.c.patch
___
Python tracker
<h
Sebastian added the comment:
any news on this?
--
___
Python tracker
<http://bugs.python.org/issue8787>
___
___
Python-bugs-list mailing list
Unsubscribe:
Sebastian added the comment:
Yes, it is. I encountered it at Solaris9 with python 2.7.1.
--
nosy: +SebaM6
___
Python tracker
<http://bugs.python.org/issue4
Changes by Sebastian Rittau :
--
nosy: -srittau
___
Python tracker
<http://bugs.python.org/issue2736>
___
___
Python-bugs-list mailing list
Unsubscribe:
Sebastian Ramacher added the comment:
Any news on that?
--
___
Python tracker
<http://bugs.python.org/issue1699259>
___
___
Python-bugs-list mailing list
Unsub
Sebastian Ramacher added the comment:
Since the patches are not applicable to Py 3.x and Py 2.7 is stable I'm closing
this bug.
--
resolution: -> out of date
status: open -> closed
___
Python tracker
<http://bugs.python.or
Sebastian Ramacher added the comment:
That is definitely not python's job. That is the duty of your shell and python
should never expand that.
And it would lead to platform specific behavior as one can see with the
following script:
import sys
import subprocess
if __name__ == &quo
Sebastian M added the comment:
One more thing, as I tried to rebuild whole python I've encountered on
following problem:
building '_multiprocessing' extension
gcc -fPIC -fno-strict-aliasing -g -O2 -DNDEBUG -DHAVE_SEM_OPEN=1
-DHAVE_FD_TRANSFER=1 -DHAVE_SEM_TIMEDW
New submission from Sebastian Hagen :
io.BytesIO().readinto() does not correctly handle the case of being called on a
BytesIO object that has been seeked past the end of its data. It consequently
ends up reading into unallocated memory, and (typically?) segfaulting if used
in this manner
New submission from Sebastian Spaeth :
imaplib's Time2Internaldate returns invalid (as localized) INTERNALDATE
strings. Appending a message with such a time string leads to a:
19 BAD Command Argument Error. 11 (for MS Exchange IMAP servers)
it returned "26-led-2011 18:23:44 +0100
Sebastian Spaeth added the comment:
P.S. To replicate this in ipython:
import locale, imaplib
locale.setlocale(locale.LC_ALL,'de_CH.utf8')
imaplib.Time2Internaldate(220254431)
Out[1]: '"24-Dez-1976 06:47:11 +0100"'
(Note the
Sebastian Spaeth added the comment:
CC'ing lavajoe as he seemed to be busy with some of imaplib's Date stuff the
last couple of days.
--
nosy: +lavajoe
___
Python tracker
<http://bugs.python.o
Sebastian Spaeth added the comment:
I think I found the issue he mentioned, however it was about the functions
taking the local time (rather than UTC), which is fine.
The problem is that Time2Internaldate is used for every .append() operation
internally, producing invalid dates which are
Sebastian Spaeth added the comment:
> Added file: imaplib_Time2Internaldate_locale_fix.patch
The patch looks very good to me and works. I agree that we should be
returning a bytearray but this is should not be part of this issue.
For all that it's worth:
Signed-off-by: Sebastia
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
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
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
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.
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
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
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
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
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
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
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
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
Changes by Sebastian Wiesner :
--
nosy: +lunar
___
Python tracker
<http://bugs.python.org/issue12873>
___
___
Python-bugs-list mailing list
Unsubscribe:
Sebastian Wiesner added the comment:
More precisely, the bug is, that 2to3 refactors the "print()" invocation in
"test1.py" though it shouldn't because a "print_function" future import is
present at the beginning of "test1.py". The cross-check w
Changes by Sebastian Ramacher :
--
nosy: +sebastinas
___
Python tracker
<http://bugs.python.org/issue12844>
___
___
Python-bugs-list mailing list
Unsubscribe:
Sebastian Wiesner added the comment:
Why should it? After all, you're sort of abusing ctypes by repeatedly creating
Struture types over and over again. C structures that you might want to wrap
with these types are fixed and known at the time of programming, so there is
never a ne
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
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
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
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
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
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
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
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
Sebastian Kraft added the comment:
Any news or feedback regarding my patch?
--
___
Python tracker
<http://bugs.python.org/issue16525>
___
___
Python-bugs-list m
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
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
Changes by Sebastian Kraft :
Removed file: http://bugs.python.org/file28122/wave_float_issue16525.patch
___
Python tracker
<http://bugs.python.org/issue16525>
___
___
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
Changes by Sebastian Ramacher :
--
nosy: +sebastinas
___
Python tracker
<http://bugs.python.org/issue6243>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Sebastian Ramacher :
--
nosy: +sebastinas
___
Python tracker
<http://bugs.python.org/issue6952>
___
___
Python-bugs-list mailing list
Unsubscribe:
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
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
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
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
Changes by Sebastian Hagen :
--
type: -> behavior
___
Python tracker
<http://bugs.python.org/issue7560>
___
___
Python-bugs-list mailing list
Unsubscri
Changes by Sebastian Hagen :
Removed file: http://bugs.python.org/file15659/posix_fn_bytes_01.patch
___
Python tracker
<http://bugs.python.org/issue7560>
___
___
Pytho
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.
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
Changes by Sebastian Hagen :
--
status: open -> closed
versions: -Python 3.2
___
Python tracker
<http://bugs.python.org/issue7560>
___
___
Python-bugs-list mai
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
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 "
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
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
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.
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
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
sebastian serrano <[EMAIL PROTECTED]> added the comment:
Running with python -O the timing gets a little closer between Lock and
RLock. This code won't be easy to improve in performance.
The heaviest call is current_thread(), used at lines:
117:me = current_thread()
137:if s
New submission from Sebastian Kirsche <[EMAIL PROTECTED]>:
The attached patch makes textwrap work with strings containing dashes
and Unicode alphabetic characters. In addition, it fixes the test case
for issue 1149508, which no longer failed after temporarily undoing the
corresponding
Sebastian Ramacher <[EMAIL PROTECTED]> added the comment:
At least a response, finally.
> * Any reason why PySys_SetPath(char *) is left out?
I guess it I just missed it.
> * Same for PySys_SetArgv(int, char **)
That one is non-trivial and requires some rewriting of PySys_Se
New submission from Sebastian Wiesner <[EMAIL PROTECTED]>:
The documentation of Python 2.6 and 2.7 only mentions the class
attribute "__mro__" in ABC documentation and in Data model documentation
when explaining description invocation (see search results:
http://docs.python.org/d
New submission from Sebastian Rittau <[EMAIL PROTECTED]>:
The attached patch removes all instances of the deprecated "apply"
function from distutils and thereby fixes warnings when run with -3.
--
components: Distutils
files: distutils.diff
keywords: patch
messages: 772
Sebastian Rittau <[EMAIL PROTECTED]> added the comment:
Oops, missed a closing parenthesis.
Added file: http://bugs.python.org/file12264/distutils.diff
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
Changes by Sebastian Rittau <[EMAIL PROTECTED]>:
Removed file: http://bugs.python.org/file12263/distutils.diff
___
Python tracker <[EMAIL PROTECTED]>
<http://bugs.pytho
New submission from Sebastian Rittau <[EMAIL PROTECTED]>:
The attached patch replaces all instances of "x.has_key(k)" method calls
by "k in x". It also replaces one call to parser.ast2tuple by
parser.st2tuple. This removes deprecation warnings when running in -3 mo
Sebastian Rittau <[EMAIL PROTECTED]> added the comment:
I'd like to see this fixed, just to decrease the amount of warning spam
I get when testing my own packages. It seems that one of my dependecies
that I have no control over is pulling this in. Adding a warning when
this module i
Sebastian Rittau added the comment:
A timedelta.toseconds method (or equivalent) makes no sense. The number
of seconds in a day is not fixed (due to leap seconds) and relying on
such a method would introduce subtle bugs. The only way to find out the
number of seconds in a range of dates is if
Sebastian Rittau added the comment:
This API is too "magical" to my liking and doesn't really reflect what
context manager's are supposed to do, i.e. handling resources. Also, I
don't see much advantage over:
group = OptionGroup(parser, "
Sebastian Rittau added the comment:
Leap second handling is usually configurable. Default on Debian Linux
(but similar on RHEL and SuSE):
>>> int(date(1994,1,1).strftime("%s")) - int(date(1993,1,1).strftime("%s"))
31536000
After doing "cp /usr/share/zoneinfo/
Changes by Sebastian Ramacher :
--
nosy: +sebastinas
___
Python tracker
<http://bugs.python.org/issue4949>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Sebastian Ramacher :
--
nosy: +sebastinas
___
Python tracker
<http://bugs.python.org/issue5322>
___
___
Python-bugs-list mailing list
Unsubscribe:
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
Sebastian Ortiz Vasquez added the comment:
I have been working with this in order to generate an RSS feed using web2py.
I found, XMLGenerator method does not validate if is an unicode or string type,
and it does not encode accord the encoding parameter of the XMLGenerator.
I added changed the
New submission from Sebastian Ortiz Vasquez:
The XMLGenerator character method is unable to detect and encode using the
encoding defined in the constructor.
This yields to an UnicodeEncode exception, because always tries to encode using
'ascii' as default in python 2
--
Sebastian Ortiz Vasquez added the comment:
Added new test and patch generated following the python development directions
found on http://docs.python.org/devguide/patch.html
--
type: -> crash
Added file: http://bugs.python.org/file29655/XMLGenerator.pa
Changes by Sebastian Ortiz Vasquez :
Removed file: http://bugs.python.org/file29655/XMLGenerator.patch
___
Python tracker
<http://bugs.python.org/issue17606>
___
___
Pytho
Changes by Sebastian Ortiz Vasquez :
Added file: http://bugs.python.org/file29656/XMLGenerator.patch
___
Python tracker
<http://bugs.python.org/issue17606>
___
___
Pytho
85 matches
Mail list logo