Simon Cross hodges...@gmail.com added the comment:
I'm attaching a patch to relax the check in PyModule_Create2 as suggested by
the Amaury (http://bugs.python.org/issue4236#msg75409).
The patch uses PyThreadState_Get()-interp-modules == NULL to determine
whether the import machinery has been
Simon Cross hodges...@gmail.com added the comment:
I made the minor changes needed to get Eli Bendersky's patch to apply against
3.2. Diff attached.
--
nosy: +hodgestar
Added file: http://bugs.python.org/file19675/issue2986.fix32.5.patch
___
Python
Simon Cross hodges...@gmail.com added the comment:
This issue is subsumed by #10435 and can probably be closed as a duplicated.
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8647
Simon Cross hodges...@gmail.com added the comment:
This issue is subsumed by #10435 and can probably be closed as a duplicated.
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8646
Simon Cross hodges...@gmail.com added the comment:
This issue is subsumed by #10435 and can probably be closed as a duplicated.
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8645
Simon Cross hodges...@gmail.com added the comment:
My vote is that this bug be closed and a new feature request be opened. Failing
that, it would be good to have a concise description of what else we would like
done (and the priority should be downgraded, I guess
Simon Cross hodges...@gmail.com added the comment:
I can confirm that I see the ('debian', 'squeeze/sid', '') on py3k and trunk
but that the Python 2.6 under Ubuntu reports ('Ubuntu', '10.04', 'lucid').
--
___
Python tracker rep...@bugs.python.org
Simon Cross hodges...@gmail.com added the comment:
I think the problem might be that linux_distribution() reads
/etc/debian_version first. The contents of the relevant files in /etc look like:
$ cat /etc/debian_version
squeeze/sid
$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE
Simon Cross hodges...@gmail.com added the comment:
Patch attached to check /etc/lsb-release before checking other files. Taken
from Ubuntu Python 2.6 copy of platform.py. Applies against trunk (r83728) with
a small offset against py3k (r83728).
--
keywords: +patch
Added file: http
Simon Cross hodges...@gmail.com added the comment:
I think the intended means of accessing this information is via the lsb_release
command
(http://refspecs.freestandards.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/lsbrelease.html).
That said, I don't know if the file format will change
Simon Cross [EMAIL PROTECTED] added the comment:
I can't reproduce this on current trunk (r66633, 27 Sep 2008). I checked
sys.getdefaultencoding() but that returned 'ascii' as expected and I
even tried language Python with LANG=C ./python but that didn't fail
either. Perhaps this has been fixed
Simon Cross [EMAIL PROTECTED] added the comment:
I've tracked down the cause to the .unescape(...) method in HTMLParser.
The replaceEntities function passed to re.sub() always returns a unicode
character, even when matching string s is a byte string. Changing line
383 to:
return
New submission from Simon Cross [EMAIL PROTECTED]:
The section on Additional meta-data in Doc/distutils/setupscript.rst is
missing any reference to the setup() platforms keyword. I've attached
a patch which fills in the basics but there are some outstanding questions:
- Does note (4) about
Changes by Simon Cross [EMAIL PROTECTED]:
--
nosy: +hodgestar
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue4336
___
___
Python-bugs-list mailing list
Simon Cross [EMAIL PROTECTED] added the comment:
This also affects Python 2.4 and 2.6 on Linux systems. Bug
http://bugs.python.org/issue2763 is a duplicate of this one.
The issue is that socketmodule.c doesn't convert empty strings to NULLs
before passing hptr through to the underlying system
Simon Cross [EMAIL PROTECTED] added the comment:
Attached a patch to correct the getaddrinfo(...) documentation and the
code example in socket.rst.
--
keywords: +patch
Added file:
http://bugs.python.org/file10237/getaddrinfo-doesnt-treat-empty-string-as-none.diff
Simon Cross [EMAIL PROTECTED] added the comment:
cElementTree.ElementTree is a copy of ElementTree.ElementTree with the
.parse(...) method replaced, so the original patch for ElementTree
should fix cElementTree too.
The copying of the ElementTree class into cElementTree happens in the
call
Simon Cross [EMAIL PROTECTED] added the comment:
Attached a patch which adds a .totimetuple(...) method to
datetime.datetime and tests for it.
The intention is that the dt.totimetuple(...) method is equivalent to:
mktime(dt.timetuple()) + (dt.microsecond / 100.0)
--
keywords
Simon Cross [EMAIL PROTECTED] added the comment:
Patch adding documentation for datetime.totimestamp(...).
Added file:
http://bugs.python.org/file10256/add-datetime-totimestamp-method-docs.diff
__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue2736
Changes by Simon Cross [EMAIL PROTECTED]:
--
nosy: +hodgestar
__
Tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1491
__
___
Python-bugs-list mailing list
Unsubscribe
Simon Cross [EMAIL PROTECTED] added the comment:
Some quick digging in the code on trunk has revealed that by the time
the base reaches PyInt_FromString in intobject.c, -909 has become 10.
Surrounding numbers seem to come through fine.
--
nosy: +hodgestar
Simon Cross [EMAIL PROTECTED] added the comment:
In int_new in intobject.c the base -909 is used to indicate that no base
has been passed through (presumably because NULL / 0 is a more common
pitfall that -909). Thus -909 is equivalent to base 10.
__
Tracker
Simon Cross [EMAIL PROTECTED] added the comment:
One of the examples Christoph tried was
unicode(Exception(u'\xe1'))
which fails quite oddly with:
UnicodeEncodeError: 'ascii' codec can't encode character u'\xe1' in
position 0: ordinal not in range(128)
The reason for this is Exception
Simon Cross [EMAIL PROTECTED] added the comment:
Concerning http://bugs.python.org/issue1551432:
I'd much rather have working unicode(e) than working unicode(Exception).
Calling unicode(C) on any class C which overrides __unicode__ is broken
without tp_unicode anyway
Simon Cross [EMAIL PROTECTED] added the comment:
Benjamin Peterson wrote:
What version are you using? In Py3k, str is unicode so __str__ can
return a unicode string.
I'm sorry it wasn't clear. I'm aware that this issue doesn't apply to
Python 3.0. I'm testing on both Python 2.5 and Python 2.6
Simon Cross [EMAIL PROTECTED] added the comment:
Attached a patch which implements Nick Coghlan's suggestion. All
existing tests in test_exceptions.py and test_unicode.py pass as does
the new unicode(Exception(u\xe1)) test.
Added file:
http://bugs.python.org/file10580/exception-unicode
Simon Cross [EMAIL PROTECTED] added the comment:
Re msg67974:
Minor cleanup of Simon's patch attached - aside from a couple of
unneeded whitespace changes, it all looks good to me.
Not checking it in yet, since it isn't critical for this week's beta
release - I'd prefer to leave it until
Simon Cross [EMAIL PROTECTED] added the comment:
Justing prodding the issue again now that the betas are out. What's the
next step?
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue2517
New submission from Simon Cross [EMAIL PROTECTED]:
The _hash method of the Set ABC uses sys.maxsize but doesn't import sys.
The attached patch (against trunk) imports sys and adds a test to show
the problem. There are also still some other _abcoll.py cleanups waiting
in issue 2226
Simon Cross [EMAIL PROTECTED] added the comment:
One could also make a case for simply removing the _hash method since it
doesn't look like anything is using it? And anything that was using it
would already be broken?
___
Python tracker [EMAIL PROTECTED]
http
New submission from Simon Cross [EMAIL PROTECTED]:
It appears that ssl.SSLSocket attempts to override some of the methods
socket.socket delegates to the underlying _socket.socket methods.
However, this overriding fails because socket.socket.__init__ replaces
all the methods mentioned
Simon Cross [EMAIL PROTECTED] added the comment:
I've just checked that the patch still applies cleanly to 2.6 and it
does and the tests still passes. It looks like the patch has already
been applied to 3.0 but without the test. The test part of the part
applies cleanly to 3.0 too
Simon Cross [EMAIL PROTECTED] added the comment:
Poking the issue.
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue1923
___
___
Python-bugs-list mailing list
Simon Cross [EMAIL PROTECTED] added the comment:
I've attached a patch for trunk / 2.6 that adds recv_into and
recvfrom_into methods to ssl.SSLSocket and does a minor re-ordering of
the nasty lambdas in __init__. The recv_into method is a port of the one
from 3.0. The recvfrom_into method
Simon Cross [EMAIL PROTECTED] added the comment:
Attach recvfrom_into method patch for 3.0.
Added file: http://bugs.python.org/file11390/3k-ssl-methods.patch
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3162
Simon Cross [EMAIL PROTECTED] added the comment:
Tests for recv* and send* methods in 3.0 (2.6 tests coming shortly).
Added file: http://bugs.python.org/file11392/3k-ssl-tests.patch
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3162
Simon Cross [EMAIL PROTECTED] added the comment:
Test for recv* and send* in 2.6.
The tests revealed some bugs so this patch fixes those and supercedes
trunk-ssl-methods.patch.
Of particular note is that recv_into called self.read(buf, nbytes) which
isn't supported in _ssl.c in 2.6. I've
Simon Cross [EMAIL PROTECTED] added the comment:
self.read(buf, nbytes)
Shouldn't this function be named readinto()?
There is no readinto function (and I suspect one is unlikely to be added
now). In Py3k SSLSocket.read takes both len and buffer as optional
arguments
Simon Cross [EMAIL PROTECTED] added the comment:
@Bill Janssen:
There are currently two patch sets which I think should be applied. For
2.6 it's just trunk-ssl-tests.patch. For 3.0 it's 3k-ssl-methods.patch
and 3k-ssl-tests.patch.
@Amaury Forgeot d'Arc
I agree it's not great nomenclature
Simon Cross [EMAIL PROTECTED] added the comment:
And thanks for looking at them and applying! :)
___
Python tracker [EMAIL PROTECTED]
http://bugs.python.org/issue3162
Simon Cross [EMAIL PROTECTED] added the comment:
I've dug around in the code a bit and the keyfile, certfile and ca_certs
filename arguments to SSLSocket.__init__ are passed down into
newPySSLObject in _ssl.c and from there directly to SSL_CTX_* function
from OpenSSL so making these arguments
Changes by Simon Cross hodges...@gmail.com:
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6280
___
___
Python-bugs-list
Simon Cross hodges...@gmail.com added the comment:
The attached patch adds a simple implementation of time.timegm that
calls calendar.timegm. It includes a short test to show that
time.timegm(time.gmtime(ts)) == ts for various timestamps.
I implemented a pure C version by pulling
Changes by Simon Cross hodges...@gmail.com:
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue17423
___
___
Python-bugs-list
Changes by Simon Cross hodges...@gmail.com:
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6230
___
___
Python-bugs-list
Changes by Simon Cross hodges...@gmail.com:
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue6232
___
___
Python-bugs-list
Simon Cross added the comment:
Genshi is affected by the 3.4 regression too (it has a class that defines
__getnewargs__ and __getattr__).
--
nosy: +hodgestar
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16251
Simon Cross added the comment:
I have an ugly work-around for those affected:
def __getattr__(self, name):
# work around for pickle bug in Python 3.4
# see http://bugs.python.org/issue16251
if name == __getnewargs_ex__:
raise AttributeError(%r has
Changes by Simon Cross <hodges...@gmail.com>:
--
nosy: +hodgestar
___
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue26252>
___
__
Simon Cross added the comment:
The documentation for __ipow__ [4] suggests that the intention was to support
the modulus argument, so perhaps that argues for fixing the behaviour of
PyNumber_InPlacePower.
[4] https://docs.python.org/3/reference/datamodel.html#object.__ipow__
New submission from Simon Cross :
The documentation for PyNumber_InPlacePower [1] reads:
This is the equivalent of the Python statement o1 **= o2 when o3 is Py_None, or
an in-place variant of pow(o1, o2, o3) otherwise. If o3 is to be ignored, pass
Py_None in its place (passing NULL for o3
Change by Simon Cross :
--
nosy: +hodgestar
___
Python tracker
<https://bugs.python.org/issue42262>
___
___
Python-bugs-list mailing list
Unsubscribe:
52 matches
Mail list logo