Changes by Brett Cannon br...@python.org:
--
dependencies: +Restore empty string special casing in
importlib.machinery.FileFinder
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
___
Changes by Brett Cannon br...@python.org:
--
resolution: - fixed
stage: test needed - committed/rejected
status: open - closed
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
___
Brett Cannon added the comment:
Wrong issue
--
dependencies: -Restore empty string special casing in
importlib.machinery.FileFinder
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
___
Brett Cannon added the comment:
I'm going to go ahead and close this. I think the optimistic change is the only
one worth making since it's backwards-compatible.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
Brett Cannon added the comment:
Nick pointed out that the change to FileFinder is possibly going to break
subclasses since the os module code doesn't treat '' as the cwd (which is
unfortunate) and so people may have been relying on that never being the case.
Really shouldn't matter all that
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com:
--
nosy: +Arfrever
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
___
Changes by Brett Cannon br...@python.org:
--
assignee: - brett.cannon
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
___
___
Roundup Robot added the comment:
New changeset 11f2f4af1979 by Brett Cannon in branch 'default':
Issue #18810: Be optimistic with stat calls when seeing if a directory
http://hg.python.org/cpython/rev/11f2f4af1979
--
nosy: +python-dev
___
Python
Brett Cannon added the comment:
The directory savings has actually been handled w/o semantics changes; in the
last commit for this issue.
The possibility of leaning on file extensions has been asked on python-dev.
Once that is resolved then this issue will either get another commit or simply
Roundup Robot added the comment:
New changeset 9895a9c20e8a by Brett Cannon in branch 'default':
Add NEWS entry for issue #18810
http://hg.python.org/cpython/rev/9895a9c20e8a
--
___
Python tracker rep...@bugs.python.org
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 level
Eric Snow added the comment:
Isn't this related somewhat to #7732?
--
nosy: +eric.snow
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue18810
___
___
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 rep...@bugs.python.org
http://bugs.python.org/issue18810
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 rep...@bugs.python.org
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 due to
15 matches
Mail list logo