Skip to main content

A list-like structure which implements collections.abc.MutableSequence

Project description

frozenlist

Azure Pipelines status for master branch codecov.io status for master branch Latest PyPI package version Latest Read The Docs Discourse group for io-libs Chat on Gitter

Introduction

frozenlist.FrozenList is a list-like structure which implements collections.abc.MutableSequence. The list is mutable until FrozenList.freeze is called, after which list modifications raise RuntimeError:

>>> from frozenlist import FrozenList
>>> fl = FrozenList([17, 42])
>>> fl
<FrozenList(frozen=False, [17, 42, 'spam', 'Vikings'])>
>>> fl.freeze()
>>> fl
<FrozenList(frozen=True, [17, 42, 'spam', 'Vikings'])>
>>> fl.frozen
True
>>> fl.append("Monty")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "frozenlist/_frozenlist.pyx", line 97, in frozenlist._frozenlist.FrozenList.append
    self._check_frozen()
  File "frozenlist/_frozenlist.pyx", line 19, in frozenlist._frozenlist.FrozenList._check_frozen
    raise RuntimeError("Cannot modify frozen list.")
RuntimeError: Cannot modify frozen list.

Installation

$ pip install frozenlist

The library requires Python 3.6 or newer.

Documentation

https://frozenlist.readthedocs.io/

Communication channels

aio-libs discourse group: https://aio-libs.discourse.group

Feel free to post your questions and ideas here.

gitter chat https://gitter.im/aio-libs/Lobby

Requirements

  • Python >= 3.6

License

frozenlist is offered under the Apache 2 license.

Source code

The project is hosted on GitHub

Please file an issue in the bug tracker if you have found a bug or have some suggestions to improve the library.

Changelog

1.0.0 (2019-11-09)

Deprecations and Removals

  • Dropped support for Python 3.5; only 3.6, 3.7 and 3.8 are supported going forward. #24

Project details


Download files

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

Source Distribution

frozenlist-1.0.0.tar.gz (60.0 kB view details)

Uploaded Source

Built Distributions

frozenlist-1.0.0-cp38-cp38-win_amd64.whl (80.6 kB view details)

Uploaded CPython 3.8 Windows x86-64

frozenlist-1.0.0-cp38-cp38-win32.whl (75.4 kB view details)

Uploaded CPython 3.8 Windows x86

frozenlist-1.0.0-cp38-cp38-manylinux1_x86_64.whl (159.0 kB view details)

Uploaded CPython 3.8

frozenlist-1.0.0-cp38-cp38-macosx_10_13_x86_64.whl (77.4 kB view details)

Uploaded CPython 3.8 macOS 10.13+ x86-64

frozenlist-1.0.0-cp37-cp37m-win_amd64.whl (80.1 kB view details)

Uploaded CPython 3.7m Windows x86-64

frozenlist-1.0.0-cp37-cp37m-win32.whl (74.9 kB view details)

Uploaded CPython 3.7m Windows x86

frozenlist-1.0.0-cp37-cp37m-manylinux1_x86_64.whl (153.2 kB view details)

Uploaded CPython 3.7m

frozenlist-1.0.0-cp37-cp37m-macosx_10_13_x86_64.whl (77.1 kB view details)

Uploaded CPython 3.7m macOS 10.13+ x86-64

frozenlist-1.0.0-cp36-cp36m-win_amd64.whl (84.5 kB view details)

Uploaded CPython 3.6m Windows x86-64

frozenlist-1.0.0-cp36-cp36m-win32.whl (79.7 kB view details)

Uploaded CPython 3.6m Windows x86

frozenlist-1.0.0-cp36-cp36m-manylinux1_x86_64.whl (153.2 kB view details)

Uploaded CPython 3.6m

frozenlist-1.0.0-cp36-cp36m-macosx_10_13_x86_64.whl (77.9 kB view details)

Uploaded CPython 3.6m macOS 10.13+ x86-64

File details

Details for the file frozenlist-1.0.0.tar.gz.

File metadata

  • Download URL: frozenlist-1.0.0.tar.gz
  • Upload date:
  • Size: 60.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0.tar.gz
Algorithm Hash digest
SHA256 d1076a40cd1bef6edf148cc05aecce52a11c9bbd2a3d60ce37cc07e03c8dc6c7
MD5 7d493070a7fe12b6be753585c1995abe
BLAKE2b-256 853212f1247bf4915b74a00264aa0033745ee871759daee47499641bd13aeee7

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 80.6 kB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 85b5e98aff043e2276ef0656744992fffaf73bb12ae96e1e071023efa7f3ec12
MD5 eb35beedaaaff4aebd887d4183da3c26
BLAKE2b-256 a4be1d11c5a9df613b8c50d66b38689202172970e4228185fb927a8bf30fe49f

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp38-cp38-win32.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp38-cp38-win32.whl
  • Upload date:
  • Size: 75.4 kB
  • Tags: CPython 3.8, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp38-cp38-win32.whl
Algorithm Hash digest
SHA256 21b9123eeed3b4506843649cb51ad5cd2dd0568687c8439744c846a64314ece8
MD5 f4dc2936ac9b43fb39cfd16ce6220308
BLAKE2b-256 0242da7f20dc8975234ed47a79ff462d004f02dc9e3fd3f288fc2ded86652a29

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp38-cp38-manylinux1_x86_64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp38-cp38-manylinux1_x86_64.whl
  • Upload date:
  • Size: 159.0 kB
  • Tags: CPython 3.8
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp38-cp38-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 81c08c2dd95a5dbe3be17b0bdd32e1062f7b295645d5fa409472439b1aa3a008
MD5 892113d67f6ce18744964ff755958cd8
BLAKE2b-256 547bbdad50f714117150e0a762c14d78d2193d66731eca06fccc63c101fe4a2c

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp38-cp38-macosx_10_13_x86_64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp38-cp38-macosx_10_13_x86_64.whl
  • Upload date:
  • Size: 77.4 kB
  • Tags: CPython 3.8, macOS 10.13+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp38-cp38-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 cbdd0515c711101d6115989989a6cbd9e2222045f55e35708726874db2c2278c
MD5 07a806a5d965195c1d44b37a09bca1a8
BLAKE2b-256 2722e2599dbc7941987f2663fd00bcedd97f710351450d168b8d64bed991b451

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 80.1 kB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 f1ea2e4aa95cccaf9a8ec44b48fb98b5bd1d8bc33a2a907697ff3e0395e1ff5f
MD5 ebdd0932408ccbf8db8d11cf7e0cc12a
BLAKE2b-256 c30ea34a73e8de033a09216cae5917a32ce30f5b250f1a82a7905cd3be564178

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp37-cp37m-win32.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp37-cp37m-win32.whl
  • Upload date:
  • Size: 74.9 kB
  • Tags: CPython 3.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp37-cp37m-win32.whl
Algorithm Hash digest
SHA256 f28e979fb37202b81de3c495ff358d1b6510629dca17d1c4a7b6ffe05b0f2fe7
MD5 8a126364719f3b57998742239174073d
BLAKE2b-256 6a9506fe4e4438818b188f0b17023542a585be8deee646a86184e504de0262b5

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp37-cp37m-manylinux1_x86_64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp37-cp37m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 153.2 kB
  • Tags: CPython 3.7m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp37-cp37m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 9c2ffe402c7c476610853e054c711186811fe42fe7333d8b29ac3bf823e43cf6
MD5 7ab3b1df6eea15b907d99e1b580b40ac
BLAKE2b-256 eb3c11cbaafcb1b8d8376f531d9c6e47b8d6d4894bd6fe5af8d07a81c78c5e18

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp37-cp37m-macosx_10_13_x86_64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp37-cp37m-macosx_10_13_x86_64.whl
  • Upload date:
  • Size: 77.1 kB
  • Tags: CPython 3.7m, macOS 10.13+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp37-cp37m-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 dee95741a275f26b50dc1bad68608ceed564216be7259627aef5b6161b023282
MD5 edf93b03088fa7e259ecc16d7deba6db
BLAKE2b-256 b4ab09c310cc613aee48e3a641dfff2217542f89da827e583ffda995ed1341d1

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 84.5 kB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 7c9eed7094ecffd5963de7b124586608bfb0d87bbad0750d3f2443bde1968ba9
MD5 a0f576f2a955f80fc3d75aa3251fb5a5
BLAKE2b-256 28ba77f7ab10c2e439ed1d597ebd2e696ab4245b4a68f851e91644b57f0bd37b

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp36-cp36m-win32.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp36-cp36m-win32.whl
  • Upload date:
  • Size: 79.7 kB
  • Tags: CPython 3.6m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 3e18973689c15de890d4eaf4e364a167fd62759fcc77e37dc526ab2585c25863
MD5 6c0b48aa29c9e99985425296e52f80de
BLAKE2b-256 f19afc5b8ded015d0cb0bf255c77318d9ad7be7b379ce568276a7de8a8fb8948

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp36-cp36m-manylinux1_x86_64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp36-cp36m-manylinux1_x86_64.whl
  • Upload date:
  • Size: 153.2 kB
  • Tags: CPython 3.6m
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp36-cp36m-manylinux1_x86_64.whl
Algorithm Hash digest
SHA256 0e758c8d9504fcb26a9292176e49c4ca4834eaf09e47a371ed9eb0d5bc5f4c40
MD5 05ace07809a5b78f8e68d69c5cb62862
BLAKE2b-256 74f064ad9e124bca0ddf17813b1ae307ed3841c431c1df439d0138b3ee6237c5

See more details on using hashes here.

File details

Details for the file frozenlist-1.0.0-cp36-cp36m-macosx_10_13_x86_64.whl.

File metadata

  • Download URL: frozenlist-1.0.0-cp36-cp36m-macosx_10_13_x86_64.whl
  • Upload date:
  • Size: 77.9 kB
  • Tags: CPython 3.6m, macOS 10.13+ x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/2.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.5

File hashes

Hashes for frozenlist-1.0.0-cp36-cp36m-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 94e75920c6ccadd48e6c11667679ddc423a51950ff491f4333004d6eb5937786
MD5 78f0b80b0da97223de4221aedd96cafb
BLAKE2b-256 1b00c74d7ed46ccd43b8bd79de74fce233aba4e5149af96f4c1fe9ffa513ebf7

See more details on using hashes here.

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