aboutsummaryrefslogtreecommitdiff
path: root/immutables
AgeCommit message (Collapse)Author
2022-05-22Add an explaining comment for _Py_HAMT_MAX_TREE_DEPTHHEADmasterYury Selivanov
2022-05-21v0.18v0.18Yury Selivanov
2022-05-21Fix iteration when the tree is 7 levels deep + collisionsYury Selivanov
Fixes issue #84. Co-authored-by: eli <eli@hyro.ai>
2022-03-25immutables v0.17v0.17Elvis Pranskevichus
Fixes ===== * Add missing name in table [project] in 'pyproject.toml'. (#78) (by @mvaled in 80b537f7 for #78)
2022-03-25Update pythoncapi_compat.h (#79)Elvis Pranskevichus
2021-08-07Bump version to 0.17.dev0Elvis Pranskevichus
2021-08-07immutables v0.16v0.16Elvis Pranskevichus
Updates ======= * Refactor typings (by @bryanforbes in 39f9f0de and @msullivan in 4a175499) * Update Python 3.10 support, drop Python 3.5 (by @elprans in fa355239 and 189b959d) Fixes ===== * Fix test_none_collisions on 32-bit systems (#69) (by @elprans in fa355239 for #69) Misc ==== * Clarify the license of the included pythoncapi_compat.h header (by @elprans in 67c5edfb for #64) * Use cibuildwheel to build wheels (#70) (by @elprans in f671cb4d for #70)
2021-08-06Drop Python 3.5 support declaration, add Python 3.10 (#71)Elvis Pranskevichus
2021-08-04Fix test_none_collisions on 32-bit systems (#69)Elvis Pranskevichus
There are two issues at play here: 1. Python version of `map_hash` unnecessarily performs hash truncation even if the hash is already 32-bit wide, which potentially converts it from signed int to unsigned long. 2. The `test_none_collisions` test generates a collision node with hash greater than 2^32. Both of these are problematic on 32-bit systems, where `sizeof(Py_hash_t)` is 4, and so anything that doesn't fit into `Py_hash_t` gets bit-mangled, breaking the `hash(x) != x` invariance that the test relies upon. Fixes: #53 Fixes: #50
2021-08-03Sync pythoncapi_compat.hElvis Pranskevichus
2021-08-03Refactor typingsBryan Forbes
* Improve typing of `__init__()` * Update typing of `Map`-producing functions to produce the correct type * Update typing of other methods to more closely align with `Mapping` * Add protocol classes for unexposed data structures * Export protocol classes for ease of use in typed code * Update stub file to pass in mypy strict mode
2021-04-22Clarify the license of the included pythoncapi_compat.h headerElvis Pranskevichus
The `pythoncapi_compat.h` header is distributed under the MIT license, so include the full text of the license in the header and mention it in the top level LICENSE file. Fixes: #64
2021-02-09v0.15v0.15Fantix King
New Features * Add support for Python 3.10 and more tests (by @vstinner in 45105ecd for #46, @hukkinj1 in d7f3eebb, f0b4fd40) * Make __repr__ more similar to other mapping types (by @ofek in 8af15021 for #17) Misc * Minor docs and CI fixes (by @MisterKeefe in 76e491cf for #32, @fantix in 1282379d for #39)
2021-02-09Fix flake8 errors and add it to CI (#45)Taneli Hukkinen
* Fix flake8 errors and add it to CI * Use extras for test dependencies Co-authored-by: Fantix King <fantix.king@gmail.com>
2021-02-09Make __repr__ more similar to other mapping types (#58)Ofek Lev
2020-12-06Add Python 3.10 support: use Py_SET_SIZE() (#52)Victor Stinner
2020-05-17v0.14v0.14Yury Selivanov
* Allow `None` to be used as key in pure-Python implementation. By @TIGirardi.
2020-05-17Unbreak CIYury Selivanov
2020-05-17Accept None as a key in pure python module (#42)TIGirardi
2020-05-13v0.13v0.13Yury Selivanov
Bugfixes * Various improvements w.r.t. type annotations & typing support (by @hukkinj1) * Fix pure-Python implementation to accept keyword argument "col" correctly (by @hukkinj1)
2020-05-13Import Literal type from typing_extensions if python version<3.8 (#33)Taneli Hukkinen
2020-05-13Improve type annotation of Map.__init__Taneli Hukkinen
2020-05-13Fix errors when a kwarg is named "col" (#35)Taneli Hukkinen
2020-05-13Make MapMutation.update consistently return an implicit NoneTaneli Hukkinen
2020-05-13Improve type annotations of Map.update and MapMutation.updateTaneli Hukkinen
2020-05-13Fix return type annotation of Map.__reduce__Taneli Hukkinen
2020-04-22Add Github release workflowv0.12Elvis Pranskevichus
2020-04-22Define NDEBUG activelyElvis Pranskevichus
`NDEBUG` is not defined by the standard library or the compiler by default, so make sure it's defined when building non-debug builds.
2020-04-22A bunch of fixesYury Selivanov
* Fix #26: `ifdef NDEBUG` should be `ifndef NDEBUG` * More tests for #24 * Add a `DEBUG_IMMUTABLES` env var to build debug builds
2020-04-22Fix the mutation API to maintain elements count correctly (#25, #24)TIGirardi
2019-11-04Bump the version to 0.12Yury Selivanov
2019-10-11Bump the version to 0.11v0.11Yury Selivanov
2019-10-07Bump the version to 0.10v0.10Yury Selivanov
2019-10-03Add typing information (#13)Anton Agestam
2018-12-13Bump the version to 0.9v0.9Yury Selivanov
2018-12-13Simplify MapMutation.__exit__() implementationYury Selivanov
2018-12-13Don't allow MapMutation.update() calls after the mutation is finishedYury Selivanov
2018-12-13Bump the version to 0.8v0.8Yury Selivanov
2018-12-13Add MapMutation.update(); make creating Map from a Map faster; fix bugsYury Selivanov
* Add new MapMutation.update() method that behaves like MutableMapping.update() * Make it faster to create a Map() from another Map() -- it's now an O(1) operation. * update() method had a bug that could cause the update Map object to have a wrong number of elements.
2018-11-20Bump the version to 0.7v0.7Yury Selivanov
2018-11-20Make MapMutation unpickleableYury Selivanov
2018-11-20Fix error message: "has been finalized" -> "has been finished"Yury Selivanov
2018-11-20Rename .finalize() to .finish()Yury Selivanov
2018-11-20Fix commentYury Selivanov
2018-11-20Get rid of f-strings to restore 3.5 compatibilityYury Selivanov
2018-11-20Make MapMutation a context managerYury Selivanov
2018-11-20Implement mutable mapping API for MapMutation; add after-finalize checksYury Selivanov
2018-11-20Implement pickle supportYury Selivanov
2018-11-20Fix .keys() and other views to support being iterated more than onceYury Selivanov
2018-11-20Implement Map.update(); support initializing Map from dict/iter/mapYury Selivanov