Skip to main content

multidict implementation

Project description

Multidicts are useful for working with HTTP headers, URL query args etc.

The code was extracted from aiohttp library.

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

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-2.1.5.tar.gz (101.4 kB view details)

Uploaded Source

Built Distributions

multidict-2.1.5-cp36-cp36m-win_amd64.whl (144.2 kB view details)

Uploaded CPython 3.6m Windows x86-64

multidict-2.1.5-cp36-cp36m-win32.whl (133.8 kB view details)

Uploaded CPython 3.6m Windows x86

multidict-2.1.5-cp36-cp36m-manylinux1_x86_64.whl (365.2 kB view details)

Uploaded CPython 3.6m

multidict-2.1.5-cp36-cp36m-manylinux1_i686.whl (336.8 kB view details)

Uploaded CPython 3.6m

multidict-2.1.5-cp35-cp35m-win_amd64.whl (142.9 kB view details)

Uploaded CPython 3.5m Windows x86-64

multidict-2.1.5-cp35-cp35m-win32.whl (132.7 kB view details)

Uploaded CPython 3.5m Windows x86

multidict-2.1.5-cp35-cp35m-manylinux1_x86_64.whl (357.6 kB view details)

Uploaded CPython 3.5m

multidict-2.1.5-cp35-cp35m-manylinux1_i686.whl (330.3 kB view details)

Uploaded CPython 3.5m

multidict-2.1.5-cp34-cp34m-win_amd64.whl (142.2 kB view details)

Uploaded CPython 3.4m Windows x86-64

multidict-2.1.5-cp34-cp34m-win32.whl (134.1 kB view details)

Uploaded CPython 3.4m Windows x86

multidict-2.1.5-cp34-cp34m-manylinux1_x86_64.whl (362.1 kB view details)

Uploaded CPython 3.4m

multidict-2.1.5-cp34-cp34m-manylinux1_i686.whl (334.0 kB view details)

Uploaded CPython 3.4m

File details

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

File metadata

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

File hashes

Hashes for multidict-2.1.5.tar.gz
Algorithm Hash digest
SHA256 20a30a474882ad174eb64873cfa7bae4604944105adf7f6847141bd7938c5ed1
MD5 8c13a780066bde25324fbeef9ffed934
BLAKE2b-256 93d22b7fbc28778b9efb39587fe12d69294f4e166908b760ccf2f788eee9cedf

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 a442c20683e52c7c77ebb2d07bfa01dd0407cd21a610ad563da5498b422d5f31
MD5 3ad11096a60706971c806f09a7df392f
BLAKE2b-256 65336916a797f1f4126061ed1d368b8b5a7925b0b6e425209ce0f5227fd5f64f

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 4c41326876f7dfb0eea78848e92ad678832d50344e80e03130629f48d22a1a17
MD5 50a2d3281c048d26c8a45eacf02acd50
BLAKE2b-256 39cce607da7e50d6c159b0c7ed480830aeebeac07695446d2bca88537f6ed6ee

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 aae75c32a41dddac64c9550a370ad0fad0266351792231d67e1149e4907f91e9
MD5 a1f8a5e34991390928f7189c0ad790b3
BLAKE2b-256 c54b8cd72d449f434e3d48797749f4747247985097ab1a8e3f872f993fcdddfe

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp36-cp36m-manylinux1_i686.whl
Algorithm Hash digest
SHA256 6847980ee684d7186c279c58d3231d59c48e19257b29a82f7e225a3f63bbe2d3
MD5 1f2ac90b765bcfd26083ad49271f7132
BLAKE2b-256 02d502d378a13155bb8a0b3264107028aa21b15bdcf15dd95f74bd5cc42aa716

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp35-cp35m-win_amd64.whl
Algorithm Hash digest
SHA256 499fbc73dd91219f00185a390d0279b404fde18c54e5e521830d755ee5fda2ff
MD5 cec58e37fed1982dc4da5dc87c9c78c9
BLAKE2b-256 511dd51d03636cd38cc85ac034b25ecde757cf0337a81433a7fb57261db22957

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp35-cp35m-win32.whl
Algorithm Hash digest
SHA256 feef4e2d880c2b6390eef2e6e85581092b5a7e9ed1e89b62b833dc4e57af2fd4
MD5 923a84bc9483d27e1e23cd37beca921b
BLAKE2b-256 b9e9b1d8d513434a0d7ed6f26b9777955d6dab22cbfec76176d29bca12928a44

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp35-cp35m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 7047094e996f20d1394aebaef1f1a1e24b71ad05e7e0f5aefcf92c6985a88b91
MD5 2329aa67e34cf15d9a58076a679426be
BLAKE2b-256 0f4864ecba44a126716ea9cafb024c45294eb55bd4eecd5fe39bdda8cce29f42

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp35-cp35m-manylinux1_i686.whl
Algorithm Hash digest
SHA256 3761984691e35e958ad31cc26af6626880abc1a657f62e04b012eb5c6fdb59ff
MD5 5e4840f161727de73f55f5f7e069a5ce
BLAKE2b-256 acaf36bb4c3ea30e6a33b2c5feef5522202180e915d3a8896713f6a7047e8ddf

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp34-cp34m-win_amd64.whl
Algorithm Hash digest
SHA256 91177087c50a17db624331f660c34f6e8fd403d92562bb4ac27b3fa863ef6925
MD5 2c2fb1122b96858c081f862861ed9e41
BLAKE2b-256 e11ecb18e0d8ff379fa94173de67501e18edd38e606f8e43b9deaf0a0e46066a

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp34-cp34m-win32.whl
Algorithm Hash digest
SHA256 12215341616c6763cffd24497cc923685b13f8e38d8aa62426f8fa1888e826d1
MD5 bb1ecaccd1916da6dad752f9bd897b1f
BLAKE2b-256 298bc3e1c7020dc47395efbccac675f6ec5c7708db3f086ac052242511f51440

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp34-cp34m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 390d53dfef270cc156b117a44af226c32510b3313b4a4e1c4eef1c1e39cac8c4
MD5 add787d49b7d035ee28e70b2b0e14862
BLAKE2b-256 025ad0ca86e63e08c9917f44d11880dcb608be355cdffd3b94e74091b9ee5039

See more details on using hashes here.

Provenance

File details

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

File metadata

File hashes

Hashes for multidict-2.1.5-cp34-cp34m-manylinux1_i686.whl
Algorithm Hash digest
SHA256 e02bd738f47bcab79befb37068099b366b0df37fb70e23c2a79e520b40525b56
MD5 44a0cf4fc58b0e5ee824dcf7dc472c1f
BLAKE2b-256 6f38161cdc227b5c104ce6974ccf8f770dfd1fd94ffd354602a76912fa173edd

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