diff --git a/CHANGELOG.md b/CHANGELOG.md index 09469a5..c52233a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,10 +1,20 @@ # Changelog -## v0.1a1 +## v0.1a2 + +### Fixes + + - Use `lru_cache` in a compatible way with Python 3.6 + +### Other changes + + - Go from pre-alpha to alpha ([5741b021e100054fd799609a09e20d819f5de43e](https://github.com/hearot/pyrubrum/commit/5741b021e100054fd799609a09e20d819f5de43e)) + +## v0.1a1 - 2020-06-19 ### Documentation - - Add contributing guidelines + - Add contributing guidelines ([5474eb251a807e76ed00b05fb3d49024ca654525](https://github.com/hearot/pyrubrum/commit/5474eb251a807e76ed00b05fb3d49024ca654525)) ## v0.1a1.dev7 - 2020-06-19 diff --git a/FEATURES.md b/FEATURES.md index 5ba30d2..b5c54df 100644 --- a/FEATURES.md +++ b/FEATURES.md @@ -1,3 +1,7 @@ -### Documentation +### Fixes - - Add contributing guidelines + - Use `lru_cache` in a compatible way with Python 3.6 + +### Other changes + + - Go from pre-alpha to alpha ([5741b021e100054fd799609a09e20d819f5de43e](https://github.com/hearot/pyrubrum/commit/5741b021e100054fd799609a09e20d819f5de43e)) diff --git a/pyrubrum/__init__.py b/pyrubrum/__init__.py index ff7f1da..15a6932 100644 --- a/pyrubrum/__init__.py +++ b/pyrubrum/__init__.py @@ -22,7 +22,7 @@ __license__ = "GNU General Public License v3" __package__ = "pyrubrum" __url__ = "https://github.com/hearot/pyrubrum" -__version__ = "0.1a1" +__version__ = "0.1a2" from .database import BaseDatabase # noqa from .database import DictDatabase # noqa diff --git a/pyrubrum/handlers/handler.py b/pyrubrum/handlers/handler.py index 0af68a6..46109e4 100644 --- a/pyrubrum/handlers/handler.py +++ b/pyrubrum/handlers/handler.py @@ -92,7 +92,7 @@ class Handler(BaseHandler): def __init__(self, nodes: Set[Node]): self.nodes = nodes - @lru_cache + @lru_cache() def get_family( self, menu_id: str ) -> Tuple[Optional[BaseMenu], Optional[Iterable[BaseMenu]]]: diff --git a/pyrubrum/tree/node.py b/pyrubrum/tree/node.py index 060413e..161e284 100644 --- a/pyrubrum/tree/node.py +++ b/pyrubrum/tree/node.py @@ -77,7 +77,7 @@ def get_children_menus(self) -> Iterable[BaseMenu]: children = tuple(child.menu for child in self.children) return children if children else None - @lru_cache + @lru_cache() def get_family(self, menu_id: str, parent: Optional["Node"]) -> Family: """Retrieve the menus which are linked to both parent and children of this instance if this instance matches the provided identifier. Otherwise it