Skip to main content

multidict implementation

Project description

https://img.shields.io/pypi/v/multidict.svg https://readthedocs.org/projects/multidict/badge/?version=latest https://img.shields.io/travis/aio-libs/multidict/master.svg?label=Linux%20build%20%40%20Travis%20CI https://img.shields.io/appveyor/ci/asvetlov/multidict/master.svg?label=Windows%20build%20%40%20Appveyor https://img.shields.io/pypi/pyversions/multidict.svg Coverage metrics Chat on Gitter

Multidict is dict-like collection of key-value pairs where key might be occurred more than once in the container.

Introduction

HTTP Headers and URL query string require specific data structure: multidict. It behaves mostly like a regular dict but it may have several values for the same key and preserves insertion ordering.

The key is str (or istr for case-insensitive dictionaries).

multidict has four multidict classes: MultiDict, MultiDictProxy, CIMultiDict and CIMultiDictProxy.

Immutable proxies (MultiDictProxy and CIMultiDictProxy) provide a dynamic view for the proxied multidict, the view reflects underlying collection changes. They implement the collections.abc.Mapping interface.

Regular mutable (MultiDict and CIMultiDict) classes implement collections.abc.MutableMapping and allows to change their own content.

Case insensitive (CIMultiDict and CIMultiDictProxy) ones assume the keys are case insensitive, e.g.:

>>> dct = CIMultiDict(key='val')
>>> 'Key' in dct
True
>>> dct['Key']
'val'

Keys should be str or istr instances.

The library has optional Cython optimization for sake of speed.

License

Apache 2

3.3.0 (2017-10-15)

  • Introduce abstract base classes (#102)

  • Publish OSX binary wheels (#153)

3.2.0 (2017-09-17)

  • Fix pickling (#134)

  • Fix equality check when other contains more keys (#124)

  • Fix CIMultiDict copy (#107)

3.1.3 (2017-07-14)

  • Fix build

3.1.2 (2017-07-14)

  • Fix type annotations

3.1.1 (2017-07-09)

  • Remove memory leak in istr implementation (#105)

3.1.0 (2017-06-25)

  • Raise RuntimeError on dict iterations if the dict was changed (#99)

  • Update __init__.pyi signatures

3.0.0 (2017-06-21)

  • Refactor internal data structures: main dict operations are about 100% faster now.

  • Preserve order on multidict updates (#68)

    Updates are md[key] = val and md.update(…) calls.

    Now the last entry is replaced with new key/value pair, all previous occurrences are removed.

    If key is not present in dictionary the pair is added to the end

  • Force keys to str instances (#88)

  • Implement .popall(key[, default]) (#84)

  • .pop() removes only first occurence, .popone() added (#92)

  • Implement dict’s version (#86)

  • Proxies are not pickable anymore (#77)

2.1.7 (2017-05-29)

  • Fix import warning on Python 3.6 (#79)

2.1.6 (2017-05-27)

  • Rebuild the library for fixning missing __spec__ attribute (#79)

2.1.5 (2017-05-13)

  • Build Python 3.6 binary wheels

2.1.4 (2016-12-1)

  • Remove LICENSE filename extension @ MANIFEST.in file (#31)

2.1.3 (2016-11-26)

  • Add a fastpath for multidict extending by multidict

2.1.2 (2016-09-25)

  • Fix CIMultiDict.update() for case of accepting istr

2.1.1 (2016-09-22)

  • Fix CIMultiDict constructor for case of accepting istr (#11)

2.1.0 (2016-09-18)

  • Allow to create proxy from proxy

  • Add type hints (PEP-484)

2.0.1 (2016-08-02)

  • Don’t crash on {} - MultiDict().keys() and similar operations (#6)

2.0.0 (2016-07-28)

  • Switch from uppercase approach for case-insensitive string to str.title() (#5)

  • Deprecase upstr class in favor of istr alias.

1.2.2 (2016-08-02)

  • Don’t crash on {} - MultiDict().keys() and similar operations (#6)

1.2.1 (2016-07-21)

  • Don’t expose multidict.__version__

1.2.0 (2016-07-16)

  • Make upstr(upstr(‘abc’)) much faster

1.1.0 (2016-07-06)

  • Don’t double-iterate during MultiDict initialization (#3)

  • Fix CIMultiDict.pop: it is case insensitive now (#1)

  • Provide manylinux wheels as well as Windows ones

1.0.3 (2016-03-24)

  • Add missing MANIFEST.in

1.0.2 (2016-03-24)

  • Fix setup build

1.0.0 (2016-02-19)

  • Initial implementation

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

multidict-3.3.0.tar.gz (34.9 kB view details)

Uploaded Source

Built Distributions

multidict-3.3.0-cp36-cp36m-win_amd64.whl (185.2 kB view details)

Uploaded CPython 3.6m Windows x86-64

multidict-3.3.0-cp36-cp36m-win32.whl (171.6 kB view details)

Uploaded CPython 3.6m Windows x86

multidict-3.3.0-cp36-cp36m-manylinux1_x86_64.whl (449.7 kB view details)

Uploaded CPython 3.6m

multidict-3.3.0-cp36-cp36m-manylinux1_i686.whl (418.6 kB view details)

Uploaded CPython 3.6m

multidict-3.3.0-cp36-cp36m-macosx_10_12_x86_64.whl (193.0 kB view details)

Uploaded CPython 3.6m macOS 10.12+ x86-64

multidict-3.3.0-cp36-cp36m-macosx_10_11_x86_64.whl (200.0 kB view details)

Uploaded CPython 3.6m macOS 10.11+ x86-64

multidict-3.3.0-cp36-cp36m-macosx_10_10_x86_64.whl (200.6 kB view details)

Uploaded CPython 3.6m macOS 10.10+ x86-64

multidict-3.3.0-cp35-cp35m-win_amd64.whl (183.8 kB view details)

Uploaded CPython 3.5m Windows x86-64

multidict-3.3.0-cp35-cp35m-win32.whl (170.6 kB view details)

Uploaded CPython 3.5m Windows x86

multidict-3.3.0-cp35-cp35m-manylinux1_x86_64.whl (440.2 kB view details)

Uploaded CPython 3.5m

multidict-3.3.0-cp35-cp35m-manylinux1_i686.whl (410.8 kB view details)

Uploaded CPython 3.5m

multidict-3.3.0-cp35-cp35m-macosx_10_12_x86_64.whl (193.1 kB view details)

Uploaded CPython 3.5m macOS 10.12+ x86-64

multidict-3.3.0-cp35-cp35m-macosx_10_11_x86_64.whl (198.4 kB view details)

Uploaded CPython 3.5m macOS 10.11+ x86-64

multidict-3.3.0-cp35-cp35m-macosx_10_10_x86_64.whl (198.9 kB view details)

Uploaded CPython 3.5m macOS 10.10+ x86-64

multidict-3.3.0-cp34-cp34m-win_amd64.whl (180.3 kB view details)

Uploaded CPython 3.4m Windows x86-64

multidict-3.3.0-cp34-cp34m-win32.whl (171.0 kB view details)

Uploaded CPython 3.4m Windows x86

multidict-3.3.0-cp34-cp34m-manylinux1_x86_64.whl (445.5 kB view details)

Uploaded CPython 3.4m

multidict-3.3.0-cp34-cp34m-manylinux1_i686.whl (416.7 kB view details)

Uploaded CPython 3.4m

multidict-3.3.0-cp34-cp34m-macosx_10_12_x86_64.whl (197.5 kB view details)

Uploaded CPython 3.4m macOS 10.12+ x86-64

multidict-3.3.0-cp34-cp34m-macosx_10_11_x86_64.whl (198.3 kB view details)

Uploaded CPython 3.4m macOS 10.11+ x86-64

multidict-3.3.0-cp34-cp34m-macosx_10_10_x86_64.whl (199.2 kB view details)

Uploaded CPython 3.4m macOS 10.10+ x86-64

File details

Details for the file multidict-3.3.0.tar.gz.

File metadata

  • Download URL: multidict-3.3.0.tar.gz
  • Upload date:
  • Size: 34.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for multidict-3.3.0.tar.gz
Algorithm Hash digest
SHA256 e76909da2fad6966281d4e0e4ccfd3c3025699ebcc30806afa09fa1384c3532b
MD5 7ecd7c2807fd76ba7ca83e4e0c7fdf5f
BLAKE2b-256 a46ed4ccf1845b03b5d47b2cc206cf8371cef80d4253a477d969607649629dd1

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-win_amd64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 7328bc54a2c793c48c70f2c5c627b65227ae610383b8fdfd8908f24e806dbdd3
MD5 d714612a7f8a7abc88463d1358911910
BLAKE2b-256 8eef7e65bad5e62ad291844404f3725fcc62981095594e5f5690e5020d486684

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-win32.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 cf196c70b77a93603d1794fe3a92477c98c6c317c047a25c51ff360d49de798f
MD5 357cb2dc3e1dab9d04c3b1b9d11c5451
BLAKE2b-256 e9095c290db8ac7fdf010384048b0ea4ce08a51a3a912fa163a1d40939d54a94

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 2bc8350500970bfdca618e3c82e65ee5ff54af2acbefa55640b7daa9c3bf18da
MD5 a4f7a3a66dcc83f945b17c9e45c36bc4
BLAKE2b-256 6d69562a0644ec1a9b16707ab2e052ead756d3c63dac101db484b8f8e69fb1dd

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-manylinux1_i686.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-manylinux1_i686.whl
Algorithm Hash digest
SHA256 feefa7557ba49b15625043745d99ba1793645e16853c4b143d2e3ff5140c1fde
MD5 251dd5f3bb4ff44918e84efac6f2e147
BLAKE2b-256 a184e197269d15f84bb137aefa0621032b2a399429824e7eb3a0ffdcd4189def

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 438d2a27fd2db0539e7a093286396a53fca953f3a3521aa0abf57a2e40820044
MD5 e799f6b34a43717e9eef55e638562197
BLAKE2b-256 fdae94982daf48063d85cbb3ddfeacf85a4d1f86c114b1c535a65edcab565e56

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-macosx_10_11_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-macosx_10_11_x86_64.whl
Algorithm Hash digest
SHA256 bd1ae0758dc27c07c3618a65c1ebd3274f60e8a0d8cf9eac09f4b078a53b972e
MD5 778fbe9eb5334fb862a47d0d60db84ea
BLAKE2b-256 37546e603d911360279fb62f3225e5c7b61b55737e2ab5a52328e8d13213fa9f

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp36-cp36m-macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp36-cp36m-macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 eb2575713f0ecff4decbfee89f0991d2120c85b0f9401b100bb8c2e279e1aa20
MD5 8a6c53cb04e172ddf249ca34df0329d6
BLAKE2b-256 f7a65a296ae4a1f49d1c5a512c1eaafd81b56a92cfe8991a12321672baec6868

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-win_amd64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-win_amd64.whl
Algorithm Hash digest
SHA256 24f9d4440bd61d4a84a3b0bca8b904e6f25e34e728a69173b3ab4340f733855a
MD5 2cf61ce6e319093753c2341ed40b2c4c
BLAKE2b-256 2974c85b296102ce9a067a6e88a20cd5abafd78ec84b44ab4411dbcfa414c09f

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-win32.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-win32.whl
Algorithm Hash digest
SHA256 912556eeae51bdc4ed411e6a6e2fdbc6bba77aac1c6caca737c788383c98e882
MD5 5fe4465e57f5aaeb086cda757d38e1f6
BLAKE2b-256 de0e09e5760f15b41a0aafc786fd628a98ba44039b5d0dbbc1d8ccc6d33bb4eb

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 0d7f532b6dc0e8714ffc735492558070fdd411414c0a03c007a703175c7da415
MD5 b8ee99a3d047e2cf93b6a6e81295b0ab
BLAKE2b-256 1bdf5ae5bb11ec254bf80af9368c3bc2ed4b9e06a9f553bb419f5323707999f1

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-manylinux1_i686.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-manylinux1_i686.whl
Algorithm Hash digest
SHA256 a7a1921373737464ed34f6bb1e3681c41c2332d9a1c40e2319e01951af788efa
MD5 e4a9b30465e948e523efd9d367ca203e
BLAKE2b-256 cfe7b2a4d8e367c6186850c5f4eeae1836db80c1ad83f0d9b92128dc2a0ff288

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 ec86cbcf11676fabc9e8f5e5aef74686a6fa97c57638690311696b28cbe19f5e
MD5 4ddc7daf0e8ea43443ea285b6d70c91d
BLAKE2b-256 a44435387d30f528b817ef562a0bca5f01626244afa61ea187d3eb5be5721efb

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-macosx_10_11_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-macosx_10_11_x86_64.whl
Algorithm Hash digest
SHA256 1b685d2b60858640ba539586cded370c222e4d8005f45508a2d64c19e7a0933e
MD5 46daf06157c7a8106e072c424af495a3
BLAKE2b-256 78603f6f55da8c638f5c47780dd06171e2f564e29ccf8bcf7b28ad0447fd909c

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp35-cp35m-macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp35-cp35m-macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 240d312195386c8bdb4006a3839d4e0bdac5b36ed5edbe2cbf36ae74da7c13f2
MD5 3c16d2f7bdfe0b191433b0ea053e00d1
BLAKE2b-256 fd3308536ac291965bf1b99e625889cf8368fb4ccb5511845a41734852b3d09c

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-win_amd64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-win_amd64.whl
Algorithm Hash digest
SHA256 f0954db3abc8143c9428785e5a1754110e1503ae6491ef6f672d09603e858e02
MD5 dc4baf4e7ee3cf87cc6b73257a132be0
BLAKE2b-256 1d3dd7c49bd75ea6a3474a50674351416a1e49cbfc9f88c6610913acbe941c8e

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-win32.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-win32.whl
Algorithm Hash digest
SHA256 3a68db44bc7c6c1587e6467c1e475b9f247a5b4894eb1e3b6a92c62599658108
MD5 59ef2b0cc636d55c11e868de66d5f538
BLAKE2b-256 31b0daf27efca140cfa3205df597d665a44aa8e0b87e4a64d5930e3f8d258517

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-manylinux1_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 0da3b09079356c169b2e81eb18b5c784738cb2129a0bf912f6b7ec81211f9902
MD5 c16633f34e8422e3acb3ceb7e1f106f4
BLAKE2b-256 8cdf0622c296a25126d9f9551e179fc92905099f7a69512a44defdb4ab11a85c

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-manylinux1_i686.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-manylinux1_i686.whl
Algorithm Hash digest
SHA256 fe7101b129ed478022b6211375b64e7b4bbdb78c344002a2b74fbbe759767f9b
MD5 c311ce5395e505bdf5cef819a54473b5
BLAKE2b-256 d161347bf8a632ffeb87925ed5eaf0dc5c259f383bfb9428807f56da98b268ab

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 8bcbcb00d05cbb9b85f2dcce36e6c6a2fdf4fe4969331305d8857bc5211a1136
MD5 26084c56109eac3bc0edde8c1cad3159
BLAKE2b-256 3e9b4200897ced243668e2cfa6c6c8ea99150c2f64a95518e5dec2c3f16ace84

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-macosx_10_11_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-macosx_10_11_x86_64.whl
Algorithm Hash digest
SHA256 da9449d1d78cd0451e27d93c121b20d3f3ac0188c1a87bf2e5982c28c031681e
MD5 a49fdf6c170a94f14979a431b95e2199
BLAKE2b-256 63feaabbfcbbc3b108d10960d7b4bef084d886bb42cba399be1210aadd11033f

See more details on using hashes here.

Provenance

File details

Details for the file multidict-3.3.0-cp34-cp34m-macosx_10_10_x86_64.whl.

File metadata

File hashes

Hashes for multidict-3.3.0-cp34-cp34m-macosx_10_10_x86_64.whl
Algorithm Hash digest
SHA256 408adc42a58e19cd5e55ddbb907b817673c64904ff51bd397723b31b7cce0757
MD5 f723934de4fdaf5383f245d4cd31e61f
BLAKE2b-256 967861c7bb9b3bcd36d04925d844f2be027223649f6c56ad4bdd198e340a61c8

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page