Changelog

Changes in Version 1.4

Perhaps the most important change in version 1.4 is that we have decided to no longer support Python 2.3. The most immediate reason for this is to allow some improvements to connection pooling. This will also allow us to use some new (as in Python 2.4 ;) idioms and will help begin the path towards supporting Python 3.0. If you need to use Python 2.3 you should consider using version 1.3 of this driver, although that will no longer be actively supported.

Other changes:

  • move "_id" to front only for top-level documents (fixes some corner cases).
  • update() and remove() return the entire response to the lastError command when safe is True.
  • completed removal of things that were deprecated in version 1.2 or earlier.
  • enforce that collection names do not contain the NULL byte.
  • fix to allow using UTF-8 collection names with the C extension.
  • added PyMongoError as base exception class for all errors. this changes the exception hierarchy somewhat, and is a BREAKING change if you depend on ConnectionFailure being a IOError or InvalidBSON being a ValueError, for example.
  • added DuplicateKeyError for calls to insert() or update() with safe set to True.
  • removed thread_util
  • added add_user() and remove_user() helpers.
  • fix for authenticate() when using non-UTF-8 names or passwords.
  • minor fixes for MasterSlaveConnection.
  • clean up all cases where ConnectionFailure is raised.
  • simplification of connection pooling - makes driver ~2x faster for simple benchmarks. see How does connection pooling work in PyMongo? for more information.
  • DEPRECATED pool_size, auto_start_request and timeout parameters to Connection. DEPRECATED start_request().
  • use socket.sendall().
  • removed from_xml() as it was only being used for some internal testing - also eliminates dependency on elementtree.
  • implementation of update() in C.
  • deprecate _command() in favor of command().
  • send all commands without wrapping as {"query": ...}.
  • support string as key argument to group() (keyf) and run all groups as commands.
  • support for equality testing for Code instances.
  • allow the NULL byte in strings and disallow it in key names or regex patterns

Changes in Version 1.3

Changes in Version 1.2.1

  • added Changelog to docs
  • added setup.py doc --test to run doctests for tutorial, examples
  • moved most examples to Sphinx docs (and remove from examples/ directory)
  • raise InvalidId instead of TypeError when passing a 24 character string to ObjectId that contains non-hexadecimal characters
  • allow unicode instances for ObjectId init

Changes in Version 1.2

  • spec parameter for remove() is now optional to allow for deleting all documents in a Collection
  • always wrap queries with {query: ...} even when no special options - get around some issues with queries on fields named query
  • enforce 4MB document limit on the client side
  • added map_reduce() helper - see example
  • added distinct() method on Cursor instances to allow distinct with queries
  • fix for __getitem__() after skip()
  • allow any UTF-8 string in BSON encoder, not just ASCII subset
  • added generation_time
  • removed support for legacy ObjectId format - pretty sure this was never used, and is just confusing
  • DEPRECATED url_encode() and url_decode() in favor of str() and ObjectId(), respectively
  • allow oplog.$main as a valid collection name
  • some minor fixes for installation process
  • added support for datetime and regex in json_util

Changes in Version 1.1.2

  • improvements to insert() speed (using C for insert message creation)
  • use random number for request_id
  • fix some race conditions with AutoReconnect

Changes in Version 1.1.1

  • added multi parameter for update()
  • fix unicode regex patterns with C extension
  • added distinct()
  • added database support for DBRef
  • added json_util with helpers for encoding / decoding special types to JSON
  • DEPRECATED pymongo.cursor.Cursor.__len__() in favor of count() with with_limit_and_skip set to True due to performance regression
  • switch documentation to Sphinx

Changes in Version 1.1

  • added __hash__() for DBRef and ObjectId
  • bulk insert() works with any iterable
  • fix ObjectId generation when using multiprocessing
  • added collection
  • added network_timeout parameter for Connection()
  • DEPRECATED slave_okay parameter for individual queries
  • fix for safe mode when multi-threaded
  • added safe parameter for remove()
  • added tailable parameter for find()

Changes in Version 1.0

Changes in Version 0.16

  • support for encoding/decoding uuid.UUID instances
  • fix for explain() with limits

Changes in Version 0.15.2

  • documentation changes only

Changes in Version 0.15.1

  • various performance improvements
  • API CHANGE no longer need to specify direction for create_index() and ensure_index() when indexing a single key
  • support for encoding tuple instances as list instances

Changes in Version 0.15

  • fix string representation of ObjectId instances
  • added timeout parameter for find()
  • allow scope for reduce function in group()

Changes in Version 0.14.2

  • minor bugfixes

Changes in Version 0.14.1

Changes in Version 0.14

Changes in Version 0.13

Changes in Version 0.12

Changes in Version 0.11.3

  • don’t allow NULL bytes in string encoder
  • fixes for Python 2.3

Changes in Version 0.11.2

  • PEP 8
  • updates for group()
  • VS build

Changes in Version 0.11.1

  • fix for connection pooling under Python 2.5

Changes in Version 0.11

  • better build failure detection
  • driver support for selecting fields in sub-documents
  • disallow insertion of invalid key names
  • added timeout parameter for Connection()

Changes in Version 0.10.3

  • fix bug with large limit()
  • better exception when modules get reloaded out from underneath the C extension
  • better exception messages when calling a Collection or Database instance

Changes in Version 0.10.2

  • support subclasses of dict in C encoder

Changes in Version 0.10.1

Changes in Version 0.10

Changes in Version 0.9.7

  • allow sub-collections of $cmd as valid Collection names
  • add version as pymongo.version
  • add --no_ext command line option to setup.py