$npx skillfedfor your agent

immutables

Immutable Collections

With conditionsPyPI LibrariesReleased Oct 20242.9M downloads / moApache License, Version 2.0Platform wheel

Decision gist · record as of 2026-08-14

platform wheels — immutables-0.21-cp310-cp310-macosx_10_9_x86_64.whl · immutables-0.21-cp310-cp310-macosx_11_0_arm64.whl · immutables-0.21-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
v0.21 · released 2024-10-10 · Python >=3.8.0

Yes, if you need immutable mappings for functional patterns, concurrent code, or as hashable dictionary keys. The HAMT implementation offers solid performance and is battle-tested in CPython itself. Install friction is moderate due to compiled extensions, but wheels cover all major platforms. Maintenance is aging (no release in 9+ months), so not suitable for projects requiring active upstream support, but stable for established use.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Medium install friction due to compiled C extensions across multiple platforms (macOS x86/arm, Linux x86/aarch64, Windows).
  • No runtime dependencies.
  • Last commit May 2025 but no release since October 2024; maintenance status is aging.

License · maintenance · safety

Apache License, Version 2.0 (permissive) — Apache 2.0 permissive license allows commercial and private use with minimal restrictions; suitable for most projects.

last release 2024-10-10 (673 days) · last repo commit 2025-05-20 · 1,204 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 2,948,816 downloads/mo, #2,811 on PyPI

Verify before relying

pip install immutables

import immutables

map1 = immutables.Map(a=1, b=2)
map2 = map1.set('a', 10)
print(map1['a'], map2['a'])  # 1 10
  • Whether the HAMT implementation matches CPython 3.7+ contextvars performance characteristics in practice
  • Specific use-case performance gains over dict copy-on-write approaches beyond the referenced benchmark
Same gist for agents: .md · .json

What it is and what it does

immutables provides a Hash Array Mapped Trie–based immutable mapping for Python, implementing the collections.abc.Mapping interface. It's the same data structure used in CPython's contextvars module (PEP 567). The Map type is hashable and pickleable, making it suitable for use as dictionary keys or in concurrent contexts where mutability is a liability.

Since Maps are immutable, mutations return new derived Maps rather than modifying in place. The package offers both single-operation methods (set, delete) and a MapMutation context manager for batching changes efficiently before finalizing a new Map. It has no runtime dependencies and supports Python 3.8 and later across CPython implementations on macOS, Linux, and Windows.

Use it for

  • Use it for context variables and thread-local state where immutability prevents accidental mutations across async tasks
  • Use it as keys in dictionaries or set members where hashability and immutability are required
  • Use it in functional programming patterns where data transformations produce new collections without side effects
  • Use it in concurrent or multi-threaded code to avoid synchronization overhead on shared data structures
  • Use it for configuration objects that must remain unchanged after creation

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

With conditions

Yes, if you need immutable mappings for functional patterns, concurrent code, or as hashable dictionary keys.

The HAMT implementation offers solid performance and is battle-tested in CPython itself. Install friction is moderate due to compiled extensions, but wheels cover all major platforms. Maintenance is aging (no release in 9+ months), so not suitable for projects requiring active upstream support, but stable for established use.

Install

immutables on PyPI

Before you install

Medium install friction due to compiled C extensions across multiple platforms (macOS x86/arm, Linux x86/aarch64, Windows). No runtime dependencies. Last commit May 2025 but no release since October 2024; maintenance status is aging.

License in practice

Apache 2.0 permissive license allows commercial and private use with minimal restrictions; suitable for most projects.

Quickstart

pip install immutables

import immutables

map1 = immutables.Map(a=1, b=2)
map2 = map1.set('a', 10)
print(map1['a'], map2['a'])  # 1 10

Verify before relying

  • Whether the HAMT implementation matches CPython 3.7+ contextvars performance characteristics in practice
  • Specific use-case performance gains over dict copy-on-write approaches beyond the referenced benchmark

Package facts

LicenseApache License, Version 2.0 permissive
Python supportSupports the current Python release >=3.8.0
Install frictionMedium. Platform-specific wheel
Runtime dependenciesNone
MaintenanceAging 673 days since the last release
Last repo commit
First released
Downloads2,948,816 / month, #2,811 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Intended Audience :: DevelopersLicense :: OSI Approved :: Apache Software LicenseOperating System :: MacOS :: MacOS XOperating System :: Microsoft :: WindowsOperating System :: POSIXProgramming Language :: Python :: 3 :: OnlyProgramming Language :: Python :: 3.10Programming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.8Programming Language :: Python :: 3.9Programming Language :: Python :: Implementation :: CPythonTopic :: Software Development :: Libraries

Evidence: immutables-0.21-cp310-cp310-macosx_10_9_x86_64.whl; immutables-0.21-cp310-cp310-macosx_11_0_arm64.whl; immutables-0.21-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; immutables-0.21-cp310-cp310-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl; immutables-0.21-cp310-cp310-musllinux_1_2_aarch64.whl; immutables-0.21-cp310-cp310-musllinux_1_2_x86_64.whl; immutables-0.21-cp310-cp310-win32.whl; immutables-0.21-cp310-cp310-win_amd64.whl; immutables-0.21-cp311-cp311-macosx_10_9_x86_64.whl; immutables-0.21-cp311-cp311-macosx_11_0_arm64.whl; immutables-0.21-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; immutables-0.21-cp311-cp311-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl; immutables-0.21-cp311-cp311-musllinux_1_2_aarch64.whl; immutables-0.21-cp311-cp311-musllinux_1_2_x86_64.whl; immutables-0.21-cp311-cp311-win32.whl; immutables-0.21-cp311-cp311-win_amd64.whl; immutables-0.21-cp312-cp312-macosx_10_13_x86_64.whl; immutables-0.21-cp312-cp312-macosx_11_0_arm64.whl; immutables-0.21-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl; immutables-0.21-cp312-cp312-manylinux_2_5_x86_64.manylinux1_x86_64.manylinux_2_17_x86_64.manylinux2014_x86_64.whl

Tags

Capabilities
immutable mapping pythonhamt hash array mapped trieimmutable dict alternativefunctional data structures pythonpersistent hash mapcopy-on-write collectionsimmutable collections library
Topics
immutable-data-structuresfunctional-programmingconcurrency-safe
PyPI keywords
collectionsimmutablehamt

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “hamt hash array mapped trie”

  • immutablesProvides an immutable mapping type backed by a Hash Array Mapped Trie…
  • trieImplements the Ethereum Merkle Trie data structure for efficient…
  • dict-hashGenerates consistent hashes for Python dictionaries and supports…

Give your agent the search over MCP, or paste the wish link into any chat.

More Libraries packages

urllib3 Worth it
PyPI · Libraries · released May 2026

urllib3 is an HTTP client library that provides thread-safe connection pooling, SSL/TLS verification, multipart file uploads, request retries, compression support, and proxy handling for Python applications.

MITpure Python · 3.10+
1.8Bdownloads / mo
requests Worth it
PyPI · Libraries · released May 2026

Requests is a Python HTTP library that simplifies sending HTTP/1.1 requests with automatic handling of headers, authentication, cookies, and response parsing.

Apache-2.0pure Python · 3.10+
1.8Bdownloads / mo
pluggy Worth it
PyPI · Libraries · released May 2025

Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.

Install it if you're building an extensible application or framework.

MITpure Python · 3.9+aging
1.3Bdownloads / mo
python-dateutil Worth it
PyPI · Libraries · released Mar 2024

Provides parsing, arithmetic, and recurrence rule computation for dates and times, with timezone support and iCalendar RFC compliance.

Install it if you need to parse flexible date strings, compute relative dates, handle timezones, or work with recurrence rules—it's the de facto choice for these tasks.

Apache-2.0pure Python
1.2Bdownloads / mo
six With conditions
PyPI · Libraries · released Dec 2024

Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.

MITpure Python
1.2Bdownloads / mo
pytest Worth it
PyPI · Libraries · released Jun 2026

pytest is a testing framework that lets you write test functions using plain assert statements and automatically discovers and runs them, with detailed failure reporting.

MITpure Python · 3.10+
1.1Bdownloads / mo

See also frozendict · frozenlist · lenses · constantdict · pyrsistent · multiset · immutabledict · rpds-py · jaraco.collections · marisa-trie