Eric Smith e...@trueblade.com added the comment:
cStringIO.StringIO is a factory function, so those messages are correct. This
is mentioned in http://docs.python.org/library/stringio.html#module-cStringIO .
--
nosy: +eric.smith
resolution: - rejected
status: open - closed
Daniel Diniz aja...@gmail.com added the comment:
Hi Stephane,
I think you're seeing different buffering behavior, which I suspect is correct
according to docs.
codecs.open should default to line buffering[1], while open uses the system
default[2].
The read() where the assert fails is
Daniel Diniz aja...@gmail.com added the comment:
Nice buglet, please take a look at Lib/pydoc.py to follow :)
As you point out, this is issue 1700304.
'plainpager', which outputs the help in these cases, uses
'sys.stdout.write(plain(text))', but Helper.help has a
Daniel Diniz aja...@gmail.com added the comment:
From #8198:
I see a solution by turning Helper.output into a property, but it smells of
over-engineering :) Passing all output to pagers should work too, unless we
need Helper.output as a sort of sys.stderr.
--
keywords: +easy
nosy:
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
components: +Unicode
nosy: +ezio.melotti
priority: - normal
stage: - test needed
versions: +Python 3.2
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8271
Ezio Melotti ezio.melo...@gmail.com added the comment:
if you are referring to
http://docs.python.org/dev/py3k/c-api/unicode.html#PyUnicode_FromFormat the
return type is a PyObject.
See also http://docs.python.org/dev/py3k/c-api/structures.html#PyObject
--
nosy: +ezio.melotti
Arnaud Fontaine ar...@debian.org added the comment:
I meant whether it returns a new reference or not. For instance, documentation
for PyUnicode_FromObject() and PyUnicode_AsWideChar() states that a new
reference is returned, but this is most specified for most functions in Unicode
Object (at
Arnaud Fontaine ar...@debian.org added the comment:
I meant whether it returns a new reference or not. For instance, documentation
for PyUnicode_FromObject() and PyUnicode_AsWideChar() states that a new
reference is returned, but this is not specified for most functions in Unicode
Object (at
Changes by Yoann Aubineau yoann.aubin...@gmail.com:
--
nosy: +yaubi
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue3445
___
___
Python-bugs-list
Cyril c...@excellency.fr added the comment:
I had a look at how M2Crypto and pyOpenSSL handled this:
- M2Crypto has wrappers around SSL_set_mode that let you set the modes you
want. From their changelog [1], it was required to be able to operate with
Twisted. By default, though, they only
Amaury Forgeot d'Arc amaur...@gmail.com added the comment:
Buffering applies when writing, not when reading a file.
There is indeed a problem in codecs.py: after a readline(), read() will return
the content of the internal buffer, and not more.
The size parameter is a hint, and should not be
Marc-Andre Lemburg m...@egenix.com added the comment:
Amaury Forgeot d'Arc wrote:
Amaury Forgeot d'Arc amaur...@gmail.com added the comment:
Buffering applies when writing, not when reading a file.
There is indeed a problem in codecs.py: after a readline(), read() will
return the
Filip Gruszczyński grusz...@gmail.com added the comment:
Are you saying, that for example for this:
grusz...@gruszczy-laptop:~/Programs/logbuilder$ ./logbuilder --help
Usage: logbuilder [options] repo
Options:
--version show program's version number and exit
-h, --help
Amaury Forgeot d'Arc amaur...@gmail.com added the comment:
Updated patch.
[I also tried to avoid reading the underlying file if
len(self.bytebuffer)=size, but it does not work with multibytes chars when
size=1]
--
Added file: http://bugs.python.org/file16706/codecs_read-2.patch
New submission from Tarek Ziadé ziade.ta...@gmail.com:
Let's move test_support in unittest !
Then maybe, let's expose some of test_support functions into a new class on the
top of unittest.TestCase, so they can be used via methods.
The purpose is power up people when it comes to write test
Michael Foord mich...@voidspace.org.uk added the comment:
Hmmm... I'm not sure moving everything as is is a good idea. Any parts in
particular you want?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8273
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Basically, all the APIs in test_support could live in unittest and the test
package could only contain the test modules written for Python.
IOW, these tests helpers can help more people than the core devs
--
Michael Foord mich...@voidspace.org.uk added the comment:
Not all the APIs are appropriate though, for example TestFailed and TestSkipped
are not needed. Some of the APIs only make sense for the test_support runner
and unittest has its own runner now.
I think the proposal needs to be more
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Sure, no need to have the test runner parts.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8273
___
Michael Foord mich...@voidspace.org.uk added the comment:
So which parts, can you list the ones you think are most important?
At the moment we don't have to maintain backwards compatibility with
test.test_support as it isn't a 'public' API - so the cost in adding it to the
standard library is
R. David Murray rdmur...@bitdance.com added the comment:
Actually, the list Terek posted a link to is a public doc page, and as was made
clear in the recent issue about the check_warnings helper, we do have to
maintain backward compatibility.
There (should be) undocumented stuff in
Florent Xicluna florent.xicl...@gmail.com added the comment:
Maybe we could move the appropriate stuff and get rid of the
test_support doc page altogether. And when we move stuff to unittest
maybe we could take the opportunity to clean up any warts in the
interfaces.
+1
I don't like the
Michael Foord mich...@voidspace.org.uk added the comment:
Right - that is exactly why I want a specific proposal as to which APIs are
generally useful and should be considered for moving into unittest.
--
___
Python tracker rep...@bugs.python.org
R. David Murray rdmur...@bitdance.com added the comment:
Nick's point is that we should be testing both the value 0 and the value -1,
but that we should expect 0 to fail only if zlib.ZLIB_VERSION is less than
1.2.4. So you'll need to update your patch to keep the 0 test but put it
inside an
Michael Foord mich...@voidspace.org.uk added the comment:
Sorry, missed David's comment:
Maybe we could move the appropriate stuff and get rid of the
test_support doc page altogether. And when we move stuff to unittest
maybe we could take the opportunity to clean up any warts in the
Tarek Ziadé ziade.ta...@gmail.com added the comment:
Yes, let's make things explicit as David said:
- test package: tests for Python itself, with private stuff, undocumented.
- unittest package: the test framework that is used by the test package and
that is public
I'd add a support module
Changes by Matthias Klose d...@debian.org:
--
nosy: +doko
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8233
___
___
Python-bugs-list mailing list
Changes by Matthias Klose d...@debian.org:
--
keywords: +needs review -patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8233
___
___
Valerio turturici.vale...@gmail.com added the comment:
This was clear. Now i make a new patch and then upload it.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
___
Michael Foord mich...@voidspace.org.uk added the comment:
A 'support' sub-module in unittest is ok. I wonder if it is the best name?
- is_jython
This is too specific and ignores the other implementations. This information is
also available from sys / platform modules.
-1
- TESTFN
This is
Tim Golden m...@timgolden.me.uk added the comment:
On 31/03/2010 14:20, Michael Foord wrote:
- TESTFN
This is a global for setting the directory temporary files are created in?
Don't think I like the global approach. Which functions is it used by?
It's used *all over the place*. I started
Changes by Valerio turturici.vale...@gmail.com:
Removed file: http://bugs.python.org/file16691/8193.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
___
Miki Tebeka miki.teb...@gmail.com added the comment:
It's marked on 2.7 due to the following (this is svn 79528)
from datetime import timedelta
d = timedelta(1)
d / 2
datetime.timedelta(0, 43200)
d // 2
datetime.timedelta(0, 43200)
from __future__ import division
d / 2
Traceback (most
Tarek Ziadé ziade.ta...@gmail.com added the comment:
about : cpython_only / is_jython
I think the idea here is to mark some tests as being specific to some
implementations.
I remember a discussion where we said that we could add in sys or platform the
name of the implementation and make this
Michael Foord mich...@voidspace.org.uk added the comment:
Something like this was discussed at the language summit. Now we have the skip
decorators it is easy to skip tests on certain platforms or only run them on
certain platforms.
The cpython_only decorator is fine - but I'd prefer a
Valerio turturici.vale...@gmail.com added the comment:
Here's the new patch. It's ok?
--
Added file: http://bugs.python.org/file16707/8193.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
Michael Foord mich...@voidspace.org.uk added the comment:
Looks good to me.
--
nosy: +michael.foord
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
___
New submission from Zubin Mithra zubin.mit...@gmail.com:
==
FAIL: test_run (distutils2.tests.test_build_clib.BuildCLibTestCase)
--
Traceback (most recent call
Antoine Pitrou pit...@free.fr added the comment:
Shouldn't it be
zlib.ZLIB_VERSION '1.2.4'
rather than
zlib.ZLIB_VERSION = '1.2.4'
?
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
Changes by Daniel Graña dan...@gmail.com:
--
nosy: +dangra
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8271
___
___
Python-bugs-list mailing
Daniel Graña dan...@gmail.com added the comment:
Some background for this report at
http://stackoverflow.com/questions/2547262/why-is-python-decode-replacing-more-than-the-invalid-bytes-from-an-encoded-string/2548480
--
___
Python tracker
R. David Murray rdmur...@bitdance.com added the comment:
Are we safe using string comparison here? How likely is zlib to get into
double digit release numbers? (Too bad the version comparison stuff Tarek is
working on isn't already available.)
--
Amaury Forgeot d'Arc amaur...@gmail.com added the comment:
Note that the exact version which changed the behavior is 1.2.3.5, see
http://www.zlib.net/ChangeLog.txt
- Use zlib header window size if windowBits is 0 in inflateInit2()
--
___
Python
Changes by R. David Murray rdmur...@bitdance.com:
--
nosy: +lemburg
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8271
___
___
Python-bugs-list
R. David Murray rdmur...@bitdance.com added the comment:
The else branch of the test should also check that 0 does *not* raise an error.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
Antoine Pitrou pit...@free.fr added the comment:
Ok, actually Python is only echoing the error return from zlib here, so I don't
seen the point of the conditional. Just always test against -1 and we're done.
--
___
Python tracker
Éric Araujo mer...@netwok.org added the comment:
Hello
Is it ok that the code checks “object.__name__ not in ('xml.etree')”? Looks
like a failed single-item tuple to me. Besides, what about using a simple “!=”?
Regards
--
nosy: +merwok
___
Python
METAL XXX metal...@gmail.com added the comment:
I have a tree:
A
/ \
B C
/ \
D E
which is implemented as a dict
tree = {
'A': set(['B', 'C']),
'B': set(['D', 'E']),
'C': set(),
'D': set(),
'E': set(),
}
I want to sort the nodes.
and I don't know how to write a key
Valerio turturici.vale...@gmail.com added the comment:
@pitrou: because the op have the problem with 1.2.4 version of zlib. By the way
i had just always test against -1 in my first patch. Make i a new patch with a
simple correction with -1 in place of 0?
@david: i know, but i'm learning now
Brian Curtin cur...@acm.org added the comment:
Good catch. That was intended to be a single tuple because the other check
above is a tuple, but because this really only checks one thing it could be a
!= until its necessary to be a tuple. I'll fix it.
--
David Albert Torpey dt...@users.sourceforge.net added the comment:
sorted(tree, cmp=lambda x, y: 1 if x in tree[y] else -1 if y in tree[x] else
0)
and it gets ['A', 'C', 'B', 'E', 'D'].
That cmp function is nonsense and isn't even close to being correct:
from random import shuffle
for i
Brian Curtin cur...@acm.org added the comment:
Made the change in r79529 through 79532.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8225
___
Marc-Andre Lemburg m...@egenix.com added the comment:
I guess the term failing byte somewhat underdefined.
Page 95 of the standard PDF
(http://www.unicode.org/versions/Unicode5.2.0/ch03.pdf) suggests to Replace
each maximal subpart of an ill-formed subsequence by a single U+FFFD.
Marc-Andre Lemburg m...@egenix.com added the comment:
Arnaud Fontaine wrote:
Arnaud Fontaine ar...@debian.org added the comment:
I meant whether it returns a new reference or not. For instance,
documentation for PyUnicode_FromObject() and PyUnicode_AsWideChar() states
that a new
Brett Cannon br...@python.org added the comment:
I take the blame on documenting the handful of things in test.support; I
thought it was a good idea to expose the handful of things that had an actual
design to them. =)
But yes, we should probably shift to test.support to being private and
Changes by Guido van Rossum gu...@python.org:
--
nosy: -gvanrossum
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1771
___
___
Python-bugs-list
Michael Foord mich...@voidspace.org.uk added the comment:
I think namespacing utility functions / classes inside unittest is fine (even
good), but agree that there needs to be careful thinking about APIs that are
made public in this way. To a certain extent this code has already proved its
New submission from Jasmit jsi...@roguewave.com:
I am testing a wrapper on Windows 64 and it seems to result in an null pointer
access error ONLY when I insert a print statement in the C code. I have tested
the wrapper with Python 2.6 and Python 2.7a4. In addition, I have compiled
Python
Brian Curtin cur...@acm.org added the comment:
Gabriel, besides the *Ex naming, do you see anything wrong with the rest of the
patch? I'd like to try and get this into 2.7 before the upcoming beta.
--
___
Python tracker rep...@bugs.python.org
METAL XXX metal...@gmail.com added the comment:
Sorry I ripped the code from a mess and I forget the tree is leaflized as
tree = {
'A': set(['B', 'C', 'D', 'E']),
'B': set(['D', 'E']),
'C': set(),
'D': set(),
'E': set(),
}
I don't want to talk about the actual problem. I think
Changes by Jasmit jsi...@roguewave.com:
--
title: callback function on win64 results in bad behavior. mem leak? -
callback function on win64 results in bad behavior. mem corruption?
___
Python tracker rep...@bugs.python.org
R. David Murray rdmur...@bitdance.com added the comment:
cmp is gone. It's chances of coming back are close enough to zero that an
assertAlmostEqual test will pass :). The rest of the discussion should move to
one of the general python lists.
--
nosy: +r.david.murray
Barry A. Warsaw ba...@python.org added the comment:
Slightly modified, patch committed to trunk in r79533
--
keywords: +patch -needs review
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8233
Ezio Melotti ezio.melo...@gmail.com added the comment:
I agree that some things can be moved in unittest, however several of the
function in test_support are designed specifically for being used for the
python test suite. For example temp_cwd is something that could be really
useful in
Barry A. Warsaw ba...@python.org added the comment:
r79536 in py3k
--
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8233
___
Antoine Pitrou pit...@free.fr added the comment:
Fixed in r79535.
--
resolution: - fixed
stage: patch review - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8268
Antoine Pitrou pit...@free.fr added the comment:
Make old-style classes weak-referenceable
Now done (r79535).
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2521
___
Daniel Stutzbach dan...@stutzbachenterprises.com added the comment:
Cool! I will revise the patch based on your comments about my test case.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2521
New submission from Maciek Fijalkowski fi...@genesilico.pl:
In ceval.c there is such code:
PyObject *
PyEval_CallObject(PyObject *func, PyObject *arg)
{
return PyEval_CallObjectWithKeywords(func, arg, (PyObject *)NULL);
}
#define PyEval_CallObject(func,arg) \
Antoine Pitrou pit...@free.fr added the comment:
Well, #defines are not exported in shared libraries. I suppose
PyEval_CallObject() was part of an old definition of the Python C-API and it
was kept for compatibility.
--
nosy: +pitrou
___
Python
Antoine Pitrou pit...@free.fr added the comment:
The #define dates back from 2007, this changeset:
branch: trunk
user:guido
date:Sat Aug 30 17:02:50 1997 +0200
files: Include/ceval.h Python/ceval.c
description:
[svn r8683] Inline PyObject_CallObject (Marc-Andre
Marc-Andre Lemburg m...@egenix.com added the comment:
Antoine Pitrou wrote:
Antoine Pitrou pit...@free.fr added the comment:
The #define dates back from 2007, this changeset:
branch: trunk
user:guido
date:Sat Aug 30 17:02:50 1997 +0200
files:
Matthew Barnett pyt...@mrabarnett.plus.com added the comment:
issue2636-20100331.zip is a new version of the regex module.
It includes speed-ups and a minor bugfix.
--
Added file: http://bugs.python.org/file16709/issue2636-20100331.zip
___
Python
Changes by Nir Aides n...@winpdb.org:
Removed file: http://bugs.python.org/file16680/bfs.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7946
___
___
Nir Aides n...@winpdb.org added the comment:
I upload a new update to bfs.patch which improves scheduling and reduces
overhead.
--
Added file: http://bugs.python.org/file16710/bfs.patch
___
Python tracker rep...@bugs.python.org
Changes by Valerio turturici.vale...@gmail.com:
Removed file: http://bugs.python.org/file16707/8193.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8193
___
Valerio turturici.vale...@gmail.com added the comment:
While i wait for what i have to do, i corrected the patch. But there is a
problem: the version of zlib '1.2.3.3' raise an error on distutils.version
module. The problem is caused by the regex expression in the
distutils.version module:
Florent Xicluna florent.xicl...@gmail.com added the comment:
Now the -Wd and -3 flags are active on some buildbots.
And the first failures ...
Need to backport fixes from py3k branch for:
- cgitb SyntaxWarning: tuple parameter unpacking has been removed in 3.x
- idlelib reduce() not supported
Changes by anatoly techtonik techto...@gmail.com:
--
keywords: +patch
Added file: http://bugs.python.org/file16712/issue7583.doctest.tabs.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7583
Changes by anatoly techtonik techto...@gmail.com:
--
title: doctest should normalize tabs when comparing output - [patch] doctest
should normalize tabs when comparing output
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7583
anatoly techtonik techto...@gmail.com added the comment:
depends on issue #7583
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7585
___
___
Daniel Stutzbach dan...@stutzbachenterprises.com added the comment:
New patches uploaded. I separated out the patch to add the test case, to make
it easier to test before and after applying the fix.
--
Added file: http://bugs.python.org/file16714/leak_test.patch
Changes by Daniel Stutzbach dan...@stutzbachenterprises.com:
Removed file: http://bugs.python.org/file16690/abc_leak.patch
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue2521
___
anatoly techtonik techto...@gmail.com added the comment:
http://codereview.appspot.com/848043/show
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7583
___
anatoly techtonik techto...@gmail.com added the comment:
It would be nice to see standalone test case that illustrates the problem.
--
nosy: +techtonik
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7443
New submission from Patrick W. p...@borntolaugh.de:
When using xml.etree.ElementTree to parse external XML files, all XML comments
within that file are being stripped out. I guess that happens because there is
no comment handler in the expat parser.
Example:
test.xml
example
nodeA
Ezio Melotti ezio.melo...@gmail.com added the comment:
There's also an invalid link to an image just after the title The low-level
view:
-.. .. image:: http.png
+.. image:: http.png
The image is not there though, and in r66294 only the document has been added.
--
Éric Araujo mer...@netwok.org added the comment:
This is a reST comment.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8218
___
___
Ezio Melotti ezio.melo...@gmail.com added the comment:
If the image is missing, then the whole line can be removed.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8218
___
Éric Araujo mer...@netwok.org added the comment:
Is there a main author for this fileN? If so, they can say whether they left
the link as a reminder to put the image back later, or if they were just afraid
of real version control 0.4 wink
--
___
Ezio Melotti ezio.melo...@gmail.com added the comment:
The author is Marek Kubica, but he doesn't seem to be registered to this
tracker.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8218
Brian Curtin cur...@acm.org added the comment:
One last issue to solve before this goes in and I start the
backport...test_tarfile.test_extract_hardlink is intermittently failing for me,
which was an issue for Eric and I on an earlier version of Jason's patch.
Sometimes it fails when run as a
Dave Malcolm dmalc...@redhat.com added the comment:
I'm attaching a new version of the patch (v5), against svn trunk (r79517)
I've been testing these hooks by using gdb attach to attach to real-world
python programs.
When doing this with earlier versions of the hooks, gdb would pause for many
Dave Malcolm dmalc...@redhat.com added the comment:
Adding diff from v4 to v5, for ease of review.
For my reference, md5sum of v5's hooks:
d3e039bb1279e71e847cc7ade10d3272 python-gdb.py
--
Added file:
http://bugs.python.org/file16716/diff-of-gdb7-hooks-v5-relative-to-v4.diff
Dan Dever ded...@verizon.net added the comment:
Adding version 2.6
This fails for me with 2.6.5 in the same way.
--
nosy: +dedded
versions: +Python 2.6
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7885
John Machin sjmac...@users.sourceforge.net added the comment:
@lemburg: failing byte seems rather obvious: first byte that you meet that is
not valid in the current state. I don't understand your explanation, especially
does not have the high bit set. I think you mean is a valid starter byte.
Ezio Melotti ezio.melo...@gmail.com added the comment:
Having the 'high bit set' means that the first bit is set to 1.
All the continuation bytes (i.e. the 2nd, 3rd or 4th byte in a sequence) have
the first two bits set to 1 and 0 respectively, so if the first bit is not set
to 1 then the byte
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
assignee: - ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8271
___
___
98 matches
Mail list logo