Changes by Brett Cannon :
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Brett Cannon added the comment:
Thanks for the patch, Madison! Added you to the ACKS file.
--
resolution: -> fixed
stage: commit review -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
New submission from Brett Cannon:
While the dev FAQ mentions it under null merges
(http://docs.python.org/devguide/faq.html#how-do-i-make-a-null-merge), it
probably should mention it under the merging section of
http://docs.python.org/devguide/committing.html#merging-between-different
Brett Cannon added the comment:
So first thing is that you can't relocate a venv. The --upgrade option is only
for when you upgrade a Python installation in-place (e.g. go from 3.3 to 3.4
but otherwise all other details stay the same). The --clear option empties out
the directories so no
New submission from Brett Cannon:
Importlib has ended up with a mixed use of single and double quotes. Should
clean it up to be consistent.
--
assignee: brett.cannon
components: Library (Lib)
keywords: easy
messages: 192771
nosy: brett.cannon
priority: low
severity: normal
stage: needs
New submission from Brett Cannon:
$ touch blah.py; ./python -c "import blah; print(blah.__file__)"
./blah.py
Should really change that to be an absolute path since the file's location is
not accurate if you call os.chdir().
--
components: Interpreter Core
messag
Changes by Brett Cannon :
--
nosy: +ncoghlan
___
Python tracker
<http://bugs.python.org/issue18416>
___
___
Python-bugs-list mailing list
Unsubscribe:
Brett Cannon added the comment:
String constants in importlib/_bootstrap.py; pylint noticed the discrepancy.
--
___
Python tracker
<http://bugs.python.org/issue18
Brett Cannon added the comment:
The solution from issue #18058 can't be backported because it would expose a
new public API on the NamespaceLoader class. It would also introduce new
functionality which would differ between Python 3.3.2 and Python 3.3.3 which
can't really be class
Changes by Brett Cannon :
--
keywords: +easy
stage: -> needs patch
versions: +Python 3.3
___
Python tracker
<http://bugs.python.org/issue18423>
___
___
Python-
Brett Cannon added the comment:
That's exactly why it currently happens. What I would do is change importlib to
just associate '' with os.getcwd() in FileFinder. That locks down where the
module was found to an absolute path while still allowing '' to function as th
Brett Cannon added the comment:
I prefer single quotes (easier to type =) and yes, using double quotes instead
of escaping is preferred.
When I have a chance I will take a look at the patch.
--
stage: needs patch -> commit review
___
Python trac
Brett Cannon added the comment:
Why the stage change? I set it to commit review on purpose as I already did a
cursory check and it was fine. I have only have one more paranoid check before
do the commit myself. I purposely didn't set patch review as I didn't want
anyone wasting
New submission from Brett Cannon:
E.g. setup_python and create_directories both check that the paths they will
create pre-exist, but the docs don't mention this.
--
assignee: docs@python
components: Documentation
messages: 192938
nosy: brett.cannon, carljm, docs@python
priority: n
New submission from Brett Cannon:
Now that Distribute is just a shell for setuptools 0.8, the example in the venv
docs for installing pip and setuptools in a venv should be updated to use
setuptools (in case anyone uses that code as a script themselves).
--
assignee: docs@python
Changes by Brett Cannon :
--
assignee: -> brett.cannon
___
Python tracker
<http://bugs.python.org/issue18362>
___
___
Python-bugs-list mailing list
Unsubscri
Brett Cannon added the comment:
changeset fe1c35cbc9a0
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
New submission from Brett Cannon:
changeset 3446dee09265
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by Brett Cannon :
--
title: Use the repr of a module name for ModuleNotFoundError in ceval.c -> Use
the repr of a module name for ImportError in ceval.c
___
Python tracker
<http://bugs.python.org/issu
Brett Cannon added the comment:
changeset fae104051a63
--
resolution: -> fixed
stage: -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Brett Cannon added the comment:
Thanks for the path, Madison! I also cleaned up the instances using double
quotes since it was because I was faking the use of a string's repr instead of
explicitly using {!r}.
--
resolution: -> fixed
stage: commit review -> committed/reje
New submission from Brett Cannon:
changeset 28294583a9c9
--
resolution: -> fixed
stage: -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Brett Cannon added the comment:
Patch is in (only moved the tests to a different class) and added Tomasz to the
ACKS file.
Thanks for the patch!
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
_
Changes by Brett Cannon :
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by Brett Cannon :
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Changes by Brett Cannon :
--
components: Library (Lib)
nosy: brett.cannon, carljm, eric.snow
priority: normal
severity: normal
stage: needs patch
status: open
title: Move venv from a custom Context class to types.SimpleNamespace
versions: Python 3.4
New submission from Brett Cannon:
The venv module has a Context class purely to hold attributes of data. This
happens to be exactly what types.SimpleNamespace was created for, so it should
probably replace Context. Luckily the class is not documented (nor what gets
set on it for that matter
Changes by Brett Cannon :
--
nosy: +vinay.sajip
___
Python tracker
<http://bugs.python.org/issue18435>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Brett Cannon :
--
nosy: +vinay.sajip
___
Python tracker
<http://bugs.python.org/issue18434>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Brett Cannon :
--
nosy: +vinay.sajip
___
Python tracker
<http://bugs.python.org/issue18433>
___
___
Python-bugs-list mailing list
Unsubscribe:
Brett Cannon added the comment:
LGTM
On Fri, Jul 12, 2013 at 3:42 PM, Vinay Sajip wrote:
>
> Vinay Sajip added the comment:
>
> I noticed that create_directories is now ensure_directories in the code,
> but the docs don't reflect this. I've posted changes, do they
Brett Cannon added the comment:
So this actually works out very nicely. The basic steps are:
1. Download ez_setup.py for setuptools
2. Create a venv
3. Install coverage.py (build actually works as expected which was a pleasant
surprise)
4. Run coverage.py with PYTHONPATH set to fullcoverage as
Brett Cannon added the comment:
Thanks for the info, Févry.
--
___
Python tracker
<http://bugs.python.org/issue9893>
___
___
Python-bugs-list mailing list
Unsub
Brett Cannon added the comment:
Setuptools 0.8 will work fine. See issue #18367 for its planned use.
--
resolution: -> fixed
status: open -> closed
___
Python tracker
<http://bugs.python.org/i
Brett Cannon added the comment:
I think getting set up for coverage.py is going to change to:
1. Download the latest setuptools
2. Download the latest coverage
-- full_coverage.py build --
3. Create a venv
4. Extract setuptools and coverage into a src/ directory in the venv
5. Install
New submission from Brett Cannon:
Devinabox's full_coverage.py run should omit test files. Probably need to put
the path in quotes for proper escaping (same for report).
--
assignee: brett.cannon
keywords: easy
messages: 193056
nosy: brett.cannon
priority: normal
severity: normal
Brett Cannon added the comment:
What version of Python is this and did you assign the lambda to an instance or
class (and if this is Python 2, new-style or classic class)?
--
nosy: +brett.cannon
___
Python tracker
<http://bugs.python.org/issue18
Changes by Brett Cannon :
--
nosy: +zach.ware
___
Python tracker
<http://bugs.python.org/issue18475>
___
___
Python-bugs-list mailing list
Unsubscribe:
Brett Cannon added the comment:
The key problem with keeping them is that beginners might mistake that a test
didn't run simply because some resource wasn't available when the tests were
run (e.g. I forget to run the coverage report so I do it on an airport to the
conference a
Brett Cannon added the comment:
The problem is confusing new contributors.
"Why wasn't this test run?"
"Because you're not on OS X."
"Why wasn't this run?"
"I didn't have internet at the time."
It's noise that's unneces
Changes by Brett Cannon :
--
nosy: -brett.cannon
___
Python tracker
<http://bugs.python.org/issue15805>
___
___
Python-bugs-list mailing list
Unsubscribe:
Brett Cannon added the comment:
Thanks for the check, Matthew, but if you look at the other *_set() methods
they do not necessarily DECREF their 'value' argument. Plus if
PyUnicode_AsWideChar() fails it means memory is full or a fatal error has
triggered, so there are bigg
New submission from Brett Cannon:
As of right now, to run the benchmark suite you need to use make_perf3.sh to
generate a Python 3 compatible version of the benchmarks. That was fine when
the benchmark suite didn't have much support for Python 3 and thus was just
used for Python 3 very
Brett Cannon added the comment:
I agree with Antoine that the time has come to drop make_perf3.sh and make it
so that Python 3 doesn't require a separate build of the benchmark directory.
Created http://bugs.python.org/issue18586 to track this
Brett Cannon added the comment:
How much slower is the execution of Python under the coverage? And can you run
it with regrtest's -j (I assume not, but I thought I would ask)?
I'm asking because this would be interesting to try and tie into devinabox, but
having to run two multi-ho
Brett Cannon added the comment:
And I should part of the reason I would love a daily report is it currently
takes a couple of hours to run a full coverage report and that's without branch
coverage.
--
___
Python tracker
<http://bugs.py
Brett Cannon added the comment:
My long term hope is something exactly like that. I'm about to rewrite the
instructions for handling coverage.py to use a venv for devinabox, but it's
definitely something that can be entirely automated for a da
Brett Cannon added the comment:
It's actually slower even with tracer.c. You actually can't use the full
coverage script without using the tracer extension module.
--
___
Python tracker
<http://bugs.python.o
Brett Cannon added the comment:
It could be changed to something like "the 'package' argument is required to
perform a relative import for {!r}".format(name) . Would that have made it more
clear?
--
assignee: -> brett.cannon
nosy: +brett.cannon
priori
Brett Cannon added the comment:
Sorry, I can't backport this change as it's not a bugfix but an enhancement and
it could break someone's code who relies on the specific format of the
exception message.
--
___
Python tracker
<http
Brett Cannon added the comment:
This is actually expected because that is just how floating point works in
programming (see http://en.wikipedia.org/wiki/Floating_point for all the gnarly
details).
If you want exact decimal arithmetic, use the decimal module (which got
significantly faster in
Brett Cannon added the comment:
I actually meant FileFinder but PathFinder is a good point.
In FileFinder you need to change ``self.path = path or '.'`` to use the cwd.
--
___
Python tracker
<http://bugs.python.o
Brett Cannon added the comment:
Won't that change to PyState_FindModule() break code? And is it part of the
stable ABI?
--
___
Python tracker
<http://bugs.python.org/is
Brett Cannon added the comment:
Sounds like it needs to be changed with a notice in What's New.
--
___
Python tracker
<http://bugs.python.org/issue18674>
___
___
Brett Cannon added the comment:
So this is bringing up a sticky situation that I ran across when initially
implementing all of this: what should sys.path_importer_cache use as a key? ''
would be what happens with Madison's option 3, and with option 1 it would be
os.getcw
Brett Cannon added the comment:
I'm sure it's an oversight.
--
___
Python tracker
<http://bugs.python.org/issue18698>
___
___
Python-bugs-list mailing
Brett Cannon added the comment:
I'm currently leaning towards having sys.path_importer_cache store the actual
directory name.
--
___
Python tracker
<http://bugs.python.org/is
Brett Cannon added the comment:
To answer Eric's question: yes.
Since no one seems to be screaming that sys.path be the only place to have the
concept of a relative path, then let's use only absolute paths except in
sys.path for ''.
--
__
Changes by Brett Cannon :
--
resolution: -> fixed
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue18367>
___
___
Python-bugs-list
Changes by Brett Cannon :
--
resolution: -> wont fix
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue18451>
___
___
Python-bugs-list
Changes by Brett Cannon :
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Brett Cannon added the comment:
This is still a warning and so I'm still looking for a solution.
--
___
Python tracker
<http://bugs.python.org/issue12837>
___
___
New submission from Brett Cannon:
Turns out the formatter module isn't really used by anyone. Pydoc uses it, but
it could easily use textwrap. Searching on Github shows a usage by someone who
simply re-exposes it as part of their own public API but has no actual usage
themselves
(
Changes by Brett Cannon :
--
assignee: -> brett.cannon
___
Python tracker
<http://bugs.python.org/issue18716>
___
___
Python-bugs-list mailing list
Unsubscri
Brett Cannon added the comment:
I think you mean in 3.3 and yes. =) Patch LGTM so I say fix in 3.3 and merge
into default.
--
assignee: -> eric.snow
___
Python tracker
<http://bugs.python.org/issu
Brett Cannon added the comment:
Ned is right, everything is working as documented and intended: as a way to
avoid using a regex to test a simple case instead of trying to do anything
fancy like identify a number.
--
nosy: +brett.cannon
resolution: -> rejected
status: open ->
Brett Cannon added the comment:
Feel free to submit an issue suggesting better docstrings as that sounds like
it could stand to get some TLC.
--
___
Python tracker
<http://bugs.python.org/issue18
New submission from Brett Cannon:
imp._HackedGetData doesn't check if the file it cached from its constructor is
still open or not. Since the path had previously been stored it would make
sense to try re-opening the file if the file object has already been closed.
--
ass
Brett Cannon added the comment:
Haven't looked at the patch but the motivation behind it sounds good to me.
--
nosy: +brett.cannon
___
Python tracker
<http://bugs.python.org/is
Changes by Brett Cannon :
--
resolution: -> invalid
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue18770>
___
___
Python-bugs-list
New submission from Brett Cannon:
If you have enough control over your environment you really don't need to waste
a stat call checking if the directory has been modified. That makes the idea of
having the check of whether the directory has changed be exposed publicly a
useful idea
Changes by Brett Cannon :
--
stage: -> test needed
type: -> enhancement
___
Python tracker
<http://bugs.python.org/issue18809>
___
___
Python-bugs-list
New submission from Brett Cannon:
If the check was done based on simply the format what was being searched for
(e.g. just assume it's a file if "module.py" exists in the directory) then a
couple of stat calls per search could be saved.
If that is deemed to dangerous d
Brett Cannon added the comment:
Because that is how it has always been:
http://hg.python.org/cpython/file/b9b521efeba3/Python/import.c#l3164 . It could
be changed but someone out there is relying on those semantics and it's a minor
thing to leave in so I don't want to me
Brett Cannon added the comment:
If I were to change this code in any way it would be to stop passing in a dummy
value for fromlist, not stop pulling from sys.modules. The official idiom for
directly calling __import__() is::
__import__(module_name)
return sys.modules[module_name]
It just
Changes by Brett Cannon :
--
resolution: -> fixed
status: open -> closed
___
Python tracker
<http://bugs.python.org/issue18755>
___
___
Python-bugs-list
Changes by Brett Cannon :
--
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Brett Cannon added the comment:
I managed to write a similar patch to Vajrasky independently, so at least I
know the approach is reasonable. =)
I'm not backporting since it really isn't that critical; I fixed it just to
turn off the ResourceWarning while running the
Brett Cannon added the comment:
I don't think it's related to the test_imp bug, but since it was never fully
diagnosed I couldn't tell you.
--
___
Python tracker
<http://bugs.pyt
Brett Cannon added the comment:
I did a quick check and at least stripping out the two stat calls for a
directory or module file (left in package __init__.py) didn't make a
significant difference.
--
___
Python tracker
<http://bugs.py
New submission from Brett Cannon:
Not sure if anyone really cares about this (I don't, but I figured I should at
least let it be known), but I realized that importlib.import_module() bypasses
builtins.__import__ by calling directly into the innards of importlib
(specifically _gcd_i
Brett Cannon added the comment:
Please upload the patches as files to the issue, that way our review tool can
be used.
--
nosy: +brett.cannon
___
Python tracker
<http://bugs.python.org/issue18
Changes by Brett Cannon :
--
nosy: +brett.cannon
___
Python tracker
<http://bugs.python.org/issue18864>
___
___
Python-bugs-list mailing list
Unsubscribe:
Brett Cannon added the comment:
There should actually be a test to catch the inconsistencies.
--
nosy: +brett.cannon
stage: -> test needed
___
Python tracker
<http://bugs.python.org/issu
Brett Cannon added the comment:
I also just tried using os.listdir() for a package before searching for
__init__ and it didn't speed anything up either (actually timeit suggests that
os.listdir() is worse than an isdir + 3 * isfile checks). Nor did caching
directory stuff at the class
Brett Cannon added the comment:
Not sure what doc discrepancy you are talking about, Terry. The docs for
importlib are totally accurate which means no one has been accidentally mislead
by them. This bug is about whether importlib.import_module() bypassing
builtins.__import__ is a big enough
Brett Cannon added the comment:
builtins.__import__ and importlib.__import__ are different objects.
This isn't about whether this is whole situation is a bug per-se, but whether
users expect that overriding builtins.__import__ will affect all import-related
code in the stdlib and if t
Brett Cannon added the comment:
help(__import__) doesn't mention anything about overriding the function. I
already touched up the stdlib docs for builtins.__import__ to strongly advise
you don't override the function.
As for overriding importlib.__import__, it won't do anythin
Changes by Brett Cannon :
--
dependencies: +Move to absolute file paths for module.__file__
___
Python tracker
<http://bugs.python.org/issue12317>
___
___
Pytho
Brett Cannon added the comment:
It technically doesn't need to be a dependency, but if __file__ goes absolute
then the point of the function becomes moot and thus shouldn't get documented
as it is then pointless (and honestly I don't trust any code that tries to
guess at what t
Changes by Brett Cannon :
--
resolution: -> fixed
stage: test needed -> committed/rejected
status: open -> closed
___
Python tracker
<http://bugs.python.or
Brett Cannon added the comment:
I honestly don't care enough to argue over this one (I was trying to save a
dict lookup but unfortunately too many people have codified the behaviour
already). Just revert http://hg.python.org/cpython/rev/005fd1fe31ab to get back
the original beha
Brett Cannon added the comment:
You could change Lib/imp.py to have ``import _frozen_importlib as _bootstrap``
if you want the same modules coming from imp, but I would argue against
changing importlib itself being changed as that complicates development since
if you screw up importlib
Brett Cannon added the comment:
So PyState_FindModule() is an (undocumented) part of the public API, which
means that it has to somehow be supported to keep ABI compatibility (unless I
am reading PEP 384 incorrectly).
--
___
Python tracker
<h
Brett Cannon added the comment:
Right, so the question is why wasn't that done in the first place? Who decided
this modules_by_index concept was even worth it?
--
___
Python tracker
<http://bugs.python.org/is
Brett Cannon added the comment:
Eric put this in the bug tracker because I asked him to; I'm getting more
emails about stuff about importlib that it's a little hard to keep track of
everything.
But originally this was about exposing what is left of the C-level APIs so it
no
Brett Cannon added the comment:
Should we limit ourselves to bound errors? Couldn't we make the macros aliases
for their full-fledged function equivalents (e.g. PyTuple_SetItem()) which
trigger Py_FatalError() on error so we also get argument type checking?
--
nosy: +brett.c
Brett Cannon added the comment:
OK, so what's your point? =) I mean you stopped the interpreter while in the
middle of starting up. Do you want to trigger a fatal error if the exception
raised was KeyboardInterrupt?
--
___
Python tracker
Brett Cannon added the comment:
So I think the sentence is saying exactly what is going on, but you want
clarification that the module object is originating from sys.modules
specifically. So you could change the sentence to "The first form of import
statement binds the module name i
Brett Cannon added the comment:
Welcome to Python code running during startup. =) As I said, the only thing I
can think of is raising the exception instead of catching it and immediately
triggering the fatal exception, but that specific fatal error was not
introduced by me so this is just a
3101 - 3200 of 5934 matches
Mail list logo