Larry Hastings la...@hastings.org added the comment:
That patch from Victor looks pretty good. I'll try to get it in for beta 2,
however I'm on the road right now. I'm back Sunday night and will try to do it
then.
If someone else wants to jump in that's fine with me.
--
assignee:
Nick Coghlan ncogh...@gmail.com added the comment:
While you're right about that, the docs shouldn't be claiming they're available
as long as that is the case.
Updated the issue to make it clear this is a problem with the current docs and
the change in the nature of the encode() and decode()
Nick Coghlan ncogh...@gmail.com added the comment:
FWIW it's, I've been thinking further about this recently and I think
implementing this feature as builtin methods is the wrong way to approach it.
Instead, I propose the addition of codecs.encode and codecs.decode methods that
are type
Nick Coghlan ncogh...@gmail.com added the comment:
Given the scope of the issue, a concurrent programming howto that lists some of
the available options and the caveats associated with each of them seems
worthwhile.
--
nosy: +ncoghlan
___
Python
New submission from Ztatik Light ztatik.li...@gmail.com:
SyntaxError: import * is not allowed in function '__init__' because it is
contains a nested function with free variables
^ /s/because it is contains/because it contains
--
components: Interpreter Core
messages: 165437
d9pouces pyt...@19pouces.net added the comment:
The plutil (Apple's command-line tool to convert plist files from a format to
another) returns an error if you try to convert a XML plist with dates to JSON.
--
___
Python tracker
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7475
___
___
Python-bugs-list
samwyse samw...@gmail.com added the comment:
Since no one else seems willing to do it, here's a patch that adds a
'quote_via' keyword parameter to the urlencode function.
import urllib.parse
query={foo: + }
urllib.parse.urlencode(query)
'foo=%2B+'
urllib.parse.urlencode(query,
New submission from samwyse samw...@gmail.com:
The doc string for url encode states:
The query arg may be either a string or a bytes type. When query arg is a
string, the safe, encoding and error parameters are sent to the quote_via
function for encoding
IMHO, this implies that the
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
stage: - needs patch
type: behavior - enhancement
versions: -Python 2.6, Python 3.1
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15350
samwyse samw...@gmail.com added the comment:
The Namespace object contains a combined list of all of the arguments, from
both the main parser and the subparser. I don't see any way to resolve
identically name augments without breaking a lot of code that relies on the
current behavior. I
Éric Araujo mer...@netwok.org added the comment:
We don’t do code cleanups for their own sake, but rather as part of a bug fix
or feature addition. Please see #15137 for a longer explanation.
--
nosy: +eric.araujo, r.david.murray, terry.reedy
___
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15311
___
___
Python-bugs-list
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15314
___
___
Python-bugs-list
Éric Araujo mer...@netwok.org added the comment:
How did you configure and build? If you ran make as root it may explain this.
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15317
Brian Brazil brian.bra...@gmail.com added the comment:
This patch is a result of frustration encountered when debugging #15002.
Not being able to use 'type' directly is rather annoying, so after figuring
that bug out I set some time aside to make it easier for the next person.
This could be
Éric Araujo mer...@netwok.org added the comment:
Nice idea! A small question: Why print 'time' in the message and not
'time.time'?
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15323
Changes by Éric Araujo mer...@netwok.org:
--
components: +Extension Modules -None
versions: +Python 3.4 -Python 2.7
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15328
___
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15336
___
___
Python-bugs-list
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +eric.araujo
title: The cmd module incorrectly lists help as an undocument command - The
cmd module incorrectly lists help as an undocumented command
___
Python tracker rep...@bugs.python.org
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +brett.cannon, ncoghlan
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15343
___
___
Éric Araujo mer...@netwok.org added the comment:
Sounds like a pkgutil-related issue to me.
--
nosy: +eric.araujo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15343
___
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +brett.cannon, eric.araujo, ncoghlan
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15299
___
Serhiy Storchaka storch...@gmail.com added the comment:
Here is yet some inconsistency:
$ LANG=uk_ua.microsoftcp1251 ./python -c import locale;
print(locale.getdefaultlocale())
('uk_UA', 'CP1251')
$ LANG=uk_ua.microsoft-cp1251 ./python -c import locale;
print(locale.getdefaultlocale())
Serhiy Storchaka storch...@gmail.com added the comment:
Here is a complex patch for more careful locale parsing.
--
Added file: http://bugs.python.org/file26380/locale_parse.patch
___
Python tracker rep...@bugs.python.org
samwyse samw...@gmail.com added the comment:
One change and one minor problem with my suggestion.
First, you don't need the second alias, since it's a prefix of the argument
name. Also, HelpFormatter._format_actions_usage ends with a bit of code
labeled clean up separators for mutually
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 3b05cf877124 by Nick Coghlan in branch '3.2':
Close #15230: runpy.run_path now sets __package__ correctly. Also refactored
the runpy tests to use a more systematic approach
Robin Schreiber robin.schrei...@me.com added the comment:
Added missing INCREF and DECREF inside the dealloc, and new methods of the
types.
--
Added file: http://bugs.python.org/file26381/csv_pep384_v1.patch
___
Python tracker rep...@bugs.python.org
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 4880aac5c665 by Nick Coghlan in branch '3.2':
Issue #15230: Update runpy docs to clarify a couple of points that came up in
this issue
http://hg.python.org/cpython/rev/4880aac5c665
New changeset 416cd57d38cf by
Nick Coghlan ncogh...@gmail.com added the comment:
Indeed, pydoc relies on pkgutil.walk_packages to work out what to document, and
that's broken currently due to the reliance on a non-standard importer API that
isn't in PEP 302 (not even as an optional extension, like the get_filename()
used
New submission from Chris Jerdonek chris.jerdo...@gmail.com:
The setUp() and tearDown() methods of unittest.TestCase are of course extremely
useful. But sometimes one has set up and tear down functionality that one
would like to apply in the form of an existing context manager (and that may
Chris Jerdonek chris.jerdo...@gmail.com added the comment:
In addition, before changing ImpImporter.iter_modules(), we should probably
also add some tests of the method for values of self.path that do work (i.e.
for when self.path is not None). The method is currently untested.
I can work on
Changes by Brett Cannon br...@python.org:
--
nosy: -brett.cannon
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15299
___
___
Python-bugs-list
Brett Cannon br...@python.org added the comment:
Ugh, I don't exactly love the idea of adding a method to any of importlib's
finders simply because PJE didn't try to make this non-standard API part of PEP
302 or something. But basically pkgutil is worthless without doing something
about this
Larry Hastings la...@hastings.org added the comment:
I don't think this needs clarifying. If you think the reference to touch
currently only muddles the issue, let's remove it entirely.
--
___
Python tracker rep...@bugs.python.org
Georg Brandl ge...@python.org added the comment:
Not great, but that sounds reasonable.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15343
___
Roger Serwy roger.se...@gmail.com added the comment:
On 3.3.0b1 and 3.2 I get:
(Cmd) help
Documented commands (type help topic):
help
I only see help under Undocumented with 2.7.
It looks like this changeset f8c896ad787f never got backported to
Chris Jerdonek chris.jerdo...@gmail.com added the comment:
I agree pkgutil is pretty much useless right now and deprecation worth
considering. But isn't another option simply to change pkgutil's internals to
provide its own iter_modules whenever it finds that method missing? This seems
to
Éric Araujo mer...@netwok.org added the comment:
Not being able to use 'type' directly is rather annoying, so after figuring
that bug out I set
some time aside to make it easier for the next person.
If you make a patch for #15002 then by all means rename “type” to “filetype” so
that you can
Chris Jerdonek chris.jerdo...@gmail.com added the comment:
In Python 2.7, I just did this test:
import sys, pkgutil
for path in sys.path:
... print pkgutil.get_importer(path)
And got only pkgutil.ImpImporter instances and imp.NullImporter objects.
So even before, at least in the most
Brett Cannon br...@python.org added the comment:
Right, you aren't getting ImpImporters because they are only used when a module
doesn't define __loader__. But in Python 3.3, by default *all* modules get that
attribute defined.
And yes, we could either tweak pkgutil to recognize FileFinder
Changes by Serhiy Storchaka storch...@gmail.com:
--
nosy: +storchaka
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9522
___
___
Python-bugs-list
New submission from Meador Inge mead...@gmail.com:
Today I was hacking on a patch that changes the marshaling format for Code
objects. When building the patch I was met with:
ValueError: bad marshal data (unknown type code)
make: *** [Lib/_sysconfigdata.py] Abort trap: 6
This is
Meador Inge mead...@gmail.com added the comment:
Patch attached.
--
keywords: +patch
stage: needs patch - patch review
Added file: http://bugs.python.org/file26382/issue15352-v0.patch
___
Python tracker rep...@bugs.python.org
R. David Murray rdmur...@bitdance.com added the comment:
Well, if you want to invoke the context in setup/teardown for some reason (as
opposed to in the test methods themselves), you can do this:
def setUp(self):
self.foo = MyContextManager.__enter__()
R. David Murray rdmur...@bitdance.com added the comment:
That should have been
self.addCleanup(MyContextManager.__exit__)
You could alternatively call __exit__() explicitly in tearDown, of course, but
I believe addCleanup is a more reliable cleanup than tearDown.
--
Antoine Pitrou pit...@free.fr added the comment:
Looks good to me. It probably won't cover all cases (such as e.g. changing the
bytecode format), but it's a good step forward.
--
nosy: +pitrou
___
Python tracker rep...@bugs.python.org
New submission from Jerry Jacobs je...@xor-gate.org:
Dear all,
I'm using python in a application (sigrok.org) and want to ship it as a
framework with a .app folder.
I'm building python-3.3b1 from source to a .framework. It is correctly compiled
and installed in the given directory. Only the
Changes by Antoine Pitrou pit...@free.fr:
--
nosy: +hynek, ned.deily
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15353
___
___
Python-bugs-list
Changes by Ned Deily n...@acm.org:
--
assignee: ronaldoussoren - ned.deily
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15353
___
___
Chris Jerdonek chris.jerdo...@gmail.com added the comment:
Thanks for the interesting background and feedback. I was aware of the
__enter__/__exit__ option but not the other information. And yes, I agree on
the importance of trying and discussing any API before settling on it. The one
I
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset e4dc8be9a72f by Gregory P. Smith in branch 'default':
Update the embedded copy of the expat XML parser to 2.1.0. It brings
http://hg.python.org/cpython/rev/e4dc8be9a72f
--
nosy: +python-dev
Gregory P. Smith g...@krypto.org added the comment:
Updated in 3.3 for beta2.
I'll leave it up to release managers to decide if they want to apply these
updates for future 2.7 and 3.2 releases (trivial, just be sure to keep our one
local modification adding the #define XML_HAS_SET_HASH_SALT
Gregory P. Smith g...@krypto.org added the comment:
Reasons why it is a good idea to apply this change to 2.7.4 and 3.2.4:
* Memory leak in poolGrow (CVE-2012-1148)
* Resource leak in readfilemap.c (CVE-2012-1147)
* Buffer over-read and crash in big2_toUtf8 (CVE-2009-3560)
* Parser crash with
New submission from Philip Jenvey pjen...@underboss.org:
The __length_hint__ optimization was broken a while ago for many iterators due
to a bug introduced in 44c090c74202. It only accepts longs as valid hints, not
ints
This affects 2.6 too (but that's in security-only fix mode), but not 3.x
Philip Jenvey pjen...@underboss.org added the comment:
attached a fix for review
--
keywords: +patch
Added file: http://bugs.python.org/file26383/lengthhint-fix.diff
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15354
New submission from Chris Jerdonek chris.jerdo...@gmail.com:
I think the generator.__next__() documentation should say that it raises an
exception if the generator is already executing:
http://docs.python.org/dev/reference/expressions.html#generator.__next__
I don't think this is currently
Larry Hastings la...@hastings.org added the comment:
It looks like #1747858 is another duplicate. Though arguably all these dups
aren't really dups because I rewrote chown's argument parsing for 3.3.
--
___
Python tracker rep...@bugs.python.org
Benjamin Peterson benja...@python.org added the comment:
It's probably easier just to use PyNumber_Check.
--
nosy: +benjamin.peterson
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15354
___
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 5f62c317c202 by Larry Hastings in branch 'default':
- Issue #15238: shutil.copystat now copies Linux extended attributes.
http://hg.python.org/cpython/rev/5f62c317c202
--
nosy: +python-dev
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 872afada51b0 by Benjamin Peterson in branch '2.7':
allow any number to be returned from __length_hint__ (closes #15354)
http://hg.python.org/cpython/rev/872afada51b0
--
nosy: +python-dev
resolution: - fixed
Changes by Larry Hastings la...@hastings.org:
--
resolution: - fixed
stage: needs patch - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15238
___
Larry Hastings la...@hastings.org added the comment:
Here's a first cut at a patch. It's really just an update of Victor's patch to
#4591 (done with his blessing). I tweaked it slightly; the parsing functions
are now O converter functions.
I also added a reasonable unit test. Note however
Larry Hastings la...@hastings.org added the comment:
Okay, I'll remove the .. note. Checking in shortly.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15233
___
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset f8b520b6f654 by Larry Hastings in branch 'default':
- Issue #15233: Python now guarantees that callables registered with
http://hg.python.org/cpython/rev/f8b520b6f654
--
Larry Hastings la...@hastings.org added the comment:
So, it's checked in to trunk. Shall I also backport to 2.7 and 3.2 as the
issue suggests?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15233
Larry Hastings la...@hastings.org added the comment:
The .4 patches both LGTM, please commit!
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15202
___
New submission from zoupl zoupen...@gmail.com:
Compile python (from 2.4.6 to version 2.6.8) on solaris 5.10 sparc using gcc
3.4.6. When using UTf-8, the \xa0 is a space. Howeve this is wrong. Version 2.7
is OK.
s = '\xa0'
assert s.strip() == s
import locale
locale.setlocale(locale.LC_ALL,
Nick Coghlan ncogh...@gmail.com added the comment:
*sigh* And, of course, there's no meaningful regression test defined for
pkgutil.walk_packages, which is why the test suite didn't pick this up :(
Oh well, at least I have a clear place to start.
--
assignee: - ncoghlan
New submission from Nick Coghlan ncogh...@gmail.com:
To set the stage for fixing the regression reported in #15343, I'm going
through and clearly marking the parts of pkgutil which should no longer be used
now that the default import system is PEP 302 compliant.
--
assignee: ncoghlan
Nick Coghlan ncogh...@gmail.com added the comment:
Unassigning for the moment - I'm busy fighting fires in pkgutil (which is
actually broken due to the import changes). If someone else has time to flesh
out the method and data attribute documentation for the ipaddress classes, that
would be
R. David Murray rdmur...@bitdance.com added the comment:
2.6 only gets security fixes at this point, which this is not.
--
nosy: +r.david.murray
resolution: - out of date
stage: - committed/rejected
status: open - closed
type: - behavior
___
zoupl zoupen...@gmail.com added the comment:
Could you please tell me the way to deal with this is version 2.7?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15356
___
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:
--
nosy: +Arfrever
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12978
___
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 6120cf695574 by Eli Bendersky in branch 'default':
Close #1767933: Badly formed XML using etree and utf-16. Patch by Serhiy
Storchaka, with some minor fixes by me
http://hg.python.org/cpython/rev/6120cf695574
Roundup Robot devn...@psf.upfronthosting.co.za added the comment:
New changeset 51b5ee7cfa3b by Eli Bendersky in branch 'default':
Issue #9458: clarify the documentation of ElementTree.write with regards to the
type of the stream expected for a given encoding
Eli Bendersky eli...@gmail.com added the comment:
I agree with Serhiy that this is more of a documentation/understanding issue
than a real bug. I've clarified the doc of ElementTree.write a bit to make it
explicit what stream is expected for 'write'.
--
assignee: - docs@python
Eli Bendersky eli...@gmail.com added the comment:
About (1):
It's customary for Python to accept truthful values (like non-empty strings)
as True. I see no harm in that. Strict type-checking to boolean True in each
and every place is not necessary.
About (2):
Similarly, this isn't
Eli Bendersky eli...@gmail.com added the comment:
I'm changing the issue name to reflect the direction it's taken. Florent, once
3.3 is branched, could you please refresh the patch vs. head for 3.4 (don't
forget the what's new) and I'll review it for commit.
--
title: Change the
Eli Bendersky eli...@gmail.com added the comment:
I'd also expand the doc of register_namespace to note what it should and
shouldn't be used for (once this feature is added).
--
___
Python tracker rep...@bugs.python.org
Nick Coghlan ncogh...@gmail.com added the comment:
The pkgutil import emulation is being deprecated in 3.3
However, I'll use this as useful input for any new walk_packages tests added
while resolving #15343
--
resolution: - wont fix
stage: needs patch - committed/rejected
status:
Nick Coghlan ncogh...@gmail.com added the comment:
I'll add a regression test for this as part of my purge of any internal usage
of the pkgutil import emulation.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15272
Eli Bendersky eli...@gmail.com added the comment:
I agree, but this will now be delayed to 3.4, since it's not a bug-fixing
change in functionality.
P.S. is there any way to create a test for it?
--
assignee: - eli.bendersky
priority: normal - low
type: - behavior
versions: -Python
Changes by Eli Bendersky eli...@gmail.com:
--
versions: -Python 3.3
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15083
___
___
Python-bugs-list
Eric Snow ericsnowcurren...@gmail.com added the comment:
FYI: the .pyc magic number is now built/kept in Lib/importlib/_bootstrap.py, so
updates to it will trigger a rebuild of frozen importlib during make.
--
nosy: +eric.snow
___
Python tracker
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:
--
nosy: +Arfrever
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15343
___
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10908
___
___
Python-bugs-list
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9914
___
___
Python-bugs-list
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10342
___
___
Python-bugs-list
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9325
___
___
Python-bugs-list
Eli Bendersky eli...@gmail.com added the comment:
ping
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14332
___
___
Python-bugs-list mailing
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13386
___
___
Python-bugs-list
Eric Snow ericsnowcurren...@gmail.com added the comment:
What I mean is, shouldn't changes to marshal have an accompanying bump to the
pyc magic number?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15352
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10685
___
___
Python-bugs-list
Changes by Eli Bendersky eli...@gmail.com:
--
nosy: -eli.bendersky
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13997
___
___
Python-bugs-list
Nick Coghlan ncogh...@gmail.com added the comment:
OK, the way I plan to tackle this is to actually redirect the pkgutil APIs to
importlib (rather than using the private import emulation).
The reason I'm going to tackle it like this is that there are some assumptions
pkgutil deals with that
Nick Coghlan ncogh...@gmail.com added the comment:
Oh, special - importlib.find_loader() currently expects every module to have a
__loader__ attribute, but there's at least one that doesn't: __main__.
Guess I'll be tweaking it to handle that case more gracefully after all :)
--
Terry J. Reedy tjre...@udel.edu added the comment:
I guess I should try to come up with something that is an improvement, even if
not perfect.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14332
Nick Coghlan ncogh...@gmail.com added the comment:
Ah, __main__, thou art such a special beast.
Here's my current plan:
1. __main__ will be initialised with __loader__ set to BuiltinImporter. This
covers cases like the interactive prompt or execution of stdin where there is
no source code
99 matches
Mail list logo