New submission from Alex Jurkiewicz:
The typing.AnyStr documentation:
https://docs.python.org/3/library/typing.html#typing.AnyStr
It gives some examples using u-strings (u'foo') but doesn't make explicit some
subtleties about behaviour with Python 2. Specifically, with Python 2
Alex Jurkiewicz added the comment:
OK, thanks for the feedback. For future searchers I am using the pylru module
instead:
https://pypi.python.org/pypi/pylru
--
___
Python tracker
<http://bugs.python.org/issue28
New submission from Alex Jurkiewicz:
I'd like to add support for functools.lru_cache to have a callback parameter
that runs every time an item is evicted from the cache. I've written a small
prototype here:
https://github.com/alexjurkiewicz/cpyt
New submission from Alex Jurkiewicz:
Sample code:
#!/usr/bin/env python
import argparse
print("\n\narg=foo, nargs=+")
parser =
argparse.ArgumentParser(formatter_class=argparse.ArgumentDefaultsHelpFormatter)
parser.add_argument('foo', nargs='+', help=