New submission from Ben Longbons:
Background:
I have a data hierarchy with a lot of "sibling" symlinked directories/files. I
want to glob only the non-symlink files, because it's a *huge* performance
increase.
Before `os.scandir`, I was using a local copy of `glob.
Ben Longbons added the comment:
This is a duplicate of bug 25596, which is now fixed.
--
nosy: +o11c
___
Python tracker
<http://bugs.python.org/issue19
Ben Longbons added the comment:
I made a minimal gist of my motivating code:
https://gist.github.com/o11c/ce0c2ff74b87ea71ad46
--
___
Python tracker
<http://bugs.python.org/issue2
Ben Longbons added the comment:
Code objects currently have no mutable fields.
So what are you planning to do about things like:
Foo = namedtuple('Foo', 'x y')
def frob(self):
return self.x + self.y
# probably actually done via a @member(Foo) decorator
# so adding mor
Ben Longbons added the comment:
Also consider:
*() or (), *() or ()
[*() or (), *() or ()]
{*() or (), *() or ()}
{**{} or {}, **{} or {}}
Note that the second-or-later argument is a separate part of the grammar so
that's why I wrote it twice.
Actually, I think `star_expr` will probab
Ben Longbons added the comment:
Related: bug 24176 fixed this for the `**` case.
--
___
Python tracker
<http://bugs.python.org/issue24791>
___
___
Python-bug
New submission from Ben Longbons:
The following code is allowed by the grammar of Python 3.4, but not Python 3.5:
`def f(): g(*a or b)`
where unary `*` has the lowest precedence, i.e. it is equivalent to:
`def f(): g(*(a or b))`
The cause of the regression that the 3.4 grammar for `arglist
Ben Longbons added the comment:
This kind of "debug your code" is the kind of thing I've gotten used to from
the Clang C/C++ compiler. Granted, compiled languages have an advantage here,
but enough residual information remains for the interpreter at runtime.
And I am in no
New submission from Ben Longbons :
I frequently construct lists of tuples, such as:
[
(1, 2, 3) # oops, missing comma!
(4, 5, 6)
]
It would be nice if the error message gave a hint on what was *actually* wrong.
Although I always use homogeneous containers, the type that's not cal
Ben Longbons added the comment:
After filing a duplicate, issue 15196, I analyzed this:
What happens:
test/one/that_dir
test/one/../two/this_dir/this_dir/this_dir/this_dir
test/two/this_dir/this_dir/this_dir/this_dir
test/two/this_dir/this_dir/this_dir/../two
test/two/this_dir/this_dir/two
Ben Longbons added the comment:
Yeah, this is a duplicate of issue 6975.
Sorry also about the version thing.
Although I can set this as closed: duplicate, I don't seem to be able to set
what bug this is a duplicate of.
--
resolution: -> duplicate
status: open ->
New submission from Ben Longbons :
I encountered this bug with the following filesystem layout
project/build/bin/main-gdb.py -> ../src/main-gdb.py
project/build/src -> ../src/
project/src/main-gdb.py -> ../py/main-gdb.py
project/py/main-gdb.py
where root/py/main-gdb.py contains
import
12 matches
Mail list logo