Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | return NotImplemented from Mapping when comparing to a non-mapping #8729 | Benjamin Peterson | 2010-05-21 | 1 | -1/+48 |
| | |||||
* | Add subtract() method to collections.Counter() objects. | Raymond Hettinger | 2010-04-03 | 1 | -0/+11 |
| | |||||
* | #7624: Fix isinstance(foo(), collections.Callable) for old-style classes. | Florent Xicluna | 2010-03-08 | 1 | -2/+30 |
| | |||||
* | Issue 6292: for the moment at least, the test suite passes if run | R. David Murray | 2010-02-23 | 1 | -1/+7 |
| | | | | | | with -OO. Tests requiring docstrings are skipped. Patch by Brian Curtin, thanks to Matias Torchinsky for helping review and improve the patch. | ||||
* | Remove unused imports in test modules. | Georg Brandl | 2010-02-07 | 1 | -2/+1 |
| | |||||
* | use assert[Not]IsInstance where appropriate | Ezio Melotti | 2010-01-24 | 1 | -24/+24 |
| | |||||
* | use assert[Not]In where appropriate | Ezio Melotti | 2010-01-23 | 1 | -7/+8 |
| | |||||
* | Reverting the Revision: 77368. I committed Flox's big patch for tests by | Senthil Kumaran | 2010-01-08 | 1 | -4/+2 |
| | | | | mistake. ( It may come in for sure tough) | ||||
* | Fixing - Issue7026 - RuntimeError: dictionary changed size during iteration. ↵ | Senthil Kumaran | 2010-01-08 | 1 | -2/+4 |
| | | | | Patch by flox | ||||
* | convert usage of fail* to assert* | Benjamin Peterson | 2009-06-30 | 1 | -67/+67 |
| | |||||
* | Revert r73401 per Raymond Hettinger's request. | Alexandre Vassalotti | 2009-06-12 | 1 | -2/+2 |
| | | | | | | The rational is the change might cause imcompatiblity problems with PyYAML. In addition, Raymond wants to kept the different versions of collections synchronized across Python versions. | ||||
* | Make pickling of OrderedDict instances more efficient. | Alexandre Vassalotti | 2009-06-12 | 1 | -2/+2 |
| | |||||
* | Fix field name conflicts for named tuples. | Raymond Hettinger | 2009-05-27 | 1 | -0/+40 |
| | |||||
* | Have namedtuple's field renamer assign names that | Raymond Hettinger | 2009-04-02 | 1 | -6/+6 |
| | | | | are consistent with the corresponding tuple index. | ||||
* | Issue #5647: MutableSet.__iand__() no longer mutates self during iteration. | Raymond Hettinger | 2009-04-01 | 1 | -0/+25 |
| | |||||
* | * Add clearer comment to initialization code. | Raymond Hettinger | 2009-03-19 | 1 | -0/+7 |
| | | | | | | * Add optional argument to popitem() -- modeled after Anthon van der Neut's C version. * Fix method markup in docs. | ||||
* | Backport 70140, 70141, 70143, and 70144. | Raymond Hettinger | 2009-03-03 | 1 | -0/+17 |
| | | | | | Adds tests, switches from list to deque, fixes __reduce__ which was unnecessarily copying __keys. | ||||
* | Beef-up tests. | Raymond Hettinger | 2009-03-03 | 1 | -3/+6 |
| | |||||
* | Backport PEP 372: OrderedDict() | Raymond Hettinger | 2009-03-03 | 1 | -3/+192 |
| | |||||
* | Backport 69934: Register xrange() as a Sequence. | Raymond Hettinger | 2009-02-24 | 1 | -0/+3 |
| | |||||
* | Issue 1818: collections.namedtuple() to support automatic renaming of ↵ | Raymond Hettinger | 2009-02-10 | 1 | -0/+11 |
| | | | | invalid fieldnames. | ||||
* | Issue 4920: Fixed next() vs __next__() issues in the ABCs | Raymond Hettinger | 2009-01-28 | 1 | -2/+63 |
| | | | | | for Iterator and MutableSet. Also added thorough test for required abstractmethods. | ||||
* | Tighten-up the docs for Counter(). | Raymond Hettinger | 2009-01-21 | 1 | -0/+5 |
| | |||||
* | Simplify explanation of multiset operations by removing restrictions on ↵ | Raymond Hettinger | 2009-01-21 | 1 | -8/+9 |
| | | | | negative inputs. | ||||
* | Build-outs for Counter() class: | Raymond Hettinger | 2009-01-20 | 1 | -1/+44 |
| | | | | | | * Constructor and update() support keyword args (like their dict counterparts). * The 'del' statement no longer raises KeyError for missing values. * Add multiset operations: __add__, __sub__, __and__, __or__. | ||||
* | Add tests for __init__() and update() with no args. | Raymond Hettinger | 2009-01-14 | 1 | -0/+2 |
| | |||||
* | Simplify Counter() API. Replace items keyword argument | Raymond Hettinger | 2009-01-13 | 1 | -4/+4 |
| | | | | | | | with a mapping. Makes Counter() idempotent, makes update() API the same as Counter.__init__(), makes a more readable repr, makes the API more dict-like, and allows Steven Bethard's update() example to work. | ||||
* | Issue 1696199: Add collections.Counter(). | Raymond Hettinger | 2009-01-12 | 1 | -2/+98 |
| | |||||
* | Fix namedtuple bug reported by Glenn Linderman. Template did not form ↵ | Raymond Hettinger | 2008-09-25 | 1 | -0/+5 |
| | | | | correctly if the field names were input in Unicode. | ||||
* | Issue 2235: Py3k warnings are now emitted for classes that will no longer ↵ | Nick Coghlan | 2008-08-11 | 1 | -0/+1 |
| | | | | inherit a__hash__ implementation from a parent class in Python 3.x. The standard library and test suite have been updated to not emit these warnings. | ||||
* | Issue 3161: Missing import and test. | Raymond Hettinger | 2008-06-23 | 1 | -0/+15 |
| | |||||
* | Issue3065: Fixed pickling of named tuples. Added tests. | Raymond Hettinger | 2008-06-09 | 1 | -1/+20 |
| | |||||
* | Take namedtuple item names only from ascii_letters (this blew up on OSX), | Georg Brandl | 2008-05-18 | 1 | -1/+3 |
| | | | | and make sure there are no duplicate names. | ||||
* | A DocTestSuite cannot run multiple times: it clears its globals dictionary ↵ | Amaury Forgeot d'Arc | 2008-04-02 | 1 | -3/+2 |
| | | | | | | after the first run. Rebuild the DocTestSuite on each iteration. | ||||
* | Run doctests on the collections module | Raymond Hettinger | 2008-01-11 | 1 | -2/+4 |
| | |||||
* | Add error-checking to namedtuple's _replace() method. | Raymond Hettinger | 2008-01-05 | 1 | -0/+7 |
| | |||||
* | Improve namedtuple's _cast() method with a docstring, new name, and ↵ | Raymond Hettinger | 2008-01-05 | 1 | -4/+7 |
| | | | | error-checking. | ||||
* | Minor fix-ups to named tuples: | Raymond Hettinger | 2008-01-04 | 1 | -8/+1 |
| | | | | | | | | | * Make the _replace() method respect subclassing. * Using property() to make _fields read-only wasn't a good idea. It caused len(Point._fields) to fail. * Add note to _cast() about length checking and alternative with the star-operator. | ||||
* | Users demand iterable input for named tuples. The author capitulates. | Raymond Hettinger | 2007-12-18 | 1 | -0/+4 |
| | |||||
* | Add more namedtuple() test cases. Neaten the code and comments. | Raymond Hettinger | 2007-12-18 | 1 | -1/+28 |
| | |||||
* | Cleaner method naming convention | Raymond Hettinger | 2007-12-14 | 1 | -8/+8 |
| | |||||
* | Error checking was too aggressive (reported by Chris Tismer) | Raymond Hettinger | 2007-12-05 | 1 | -0/+1 |
| | |||||
* | Backport of _abccoll.py by Benjamin Arangueren, issue 1383. | Guido van Rossum | 2007-11-22 | 1 | -1/+185 |
| | | | | With some changes of my own thrown in (e.g. backport of r58107). | ||||
* | Accept Issac Morland's suggestion for __replace__ to allow multiple replacements | Raymond Hettinger | 2007-11-15 | 1 | -1/+1 |
| | | | | | | (suprisingly, this simplifies the signature, improves clarity, and is comparably fast). Update the docs to reflect a previous change to the function name. Add an example to the docs showing how to override the default __repr__ method. | ||||
* | Add test for __fields__ being read-only | Raymond Hettinger | 2007-11-14 | 1 | -0/+8 |
| | |||||
* | Shorter name for namedtuple() | Raymond Hettinger | 2007-10-23 | 1 | -17/+17 |
| | |||||
* | More docs, error messages, and tests | Raymond Hettinger | 2007-10-16 | 1 | -6/+11 |
| | |||||
* | Eliminate camelcase function name | Raymond Hettinger | 2007-10-08 | 1 | -12/+14 |
| | |||||
* | Add comments to NamedTuple code. | Raymond Hettinger | 2007-10-08 | 1 | -0/+5 |
| | | | | | Let the field spec be either a string or a non-string sequence (suggested by Martin Blais with use cases). Improve the error message in the case of a SyntaxError (caused by a duplicate field name). | ||||
* | Add __asdict__() to NamedTuple and refine the docs. | Raymond Hettinger | 2007-10-05 | 1 | -0/+2 |
| | | | | | | Add maxlen support to deque() and fixup docs. Partially fix __reduce__(). The None as a third arg was no longer supported. Still needs work on __reduce__() to handle recursive inputs. |