Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 0.12 #619

Merged
merged 14 commits into from
Jan 13, 2023
19 changes: 10 additions & 9 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,20 @@
# CHANGELOG


## 0.12.0 (2023-xx-xx)
## 0.12.0 (2023-01-13)

* Add ``async with`` support to ``BaseCache``.
Dreamsorcerer marked this conversation as resolved.
Show resolved Hide resolved
* Add initial typing support.
* Migrate to ``redis`` library (``aioredis`` is no longer supported).
* ``SimpleMemoryBackend`` now has a cache per instance, rather than a global cache.
* Improved support for ``build_key(key, namespace)`` [#569](https://github.com/aio-libs/aiocache/issues/569) -- Padraic Shafer
* Remove deprecated ``loop`` parameters.
* Remove deprecated ``cache`` parameter from ``create()``.
* Use ``base._ensure_key()`` in ``_build_key()`` to ensure consistency of enum
keys between different Python versions. [#633](https://github.com/aio-libs/aiocache/issues/633) -- Padraic Shafer
* Improved support for ``build_key(key, namespace)`` [#569](https://github.com/aio-libs/aiocache/issues/569) - Padraic Shafer
* `BaseCache.build_key` uses `namespace` argument if provided,
otherwise it uses `self.namespace`.
* Cache locks use `client.build_key` rather than `client._build_key`.
* Include examples of using a custom `key_builder` when creating a cache.
* Warn when decorator parameters are unused because alias takes precedence.
* Allow keyword arguments in ``TimingPlugin`` methods.
* Fix inconsistent enum keys between different Python versions. -- Padraic Shafer
* Fix ``.clear()`` breaking when no keys are present.
* Fix ``from aiocache import *``.
* Fix ``.delete()`` when values are falsy.

## 0.11.1 (2019-07-31)

Expand Down
4 changes: 2 additions & 2 deletions aiocache/__init__.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import logging
from typing import Dict, Type

from ._version import __version__
from .backends.memory import SimpleMemoryCache
from .base import BaseCache

__version__ = "0.12.0"

logger = logging.getLogger(__name__)

AIOCACHE_CACHES: Dict[str, Type[BaseCache]] = {SimpleMemoryCache.NAME: SimpleMemoryCache}
Expand Down Expand Up @@ -40,5 +41,4 @@
"cached_stampede",
"multi_cached",
*(c.__name__ for c in AIOCACHE_CACHES.values()),
"__version__",
)
1 change: 0 additions & 1 deletion aiocache/_version.py

This file was deleted.

2 changes: 1 addition & 1 deletion docs/readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ build:
image: latest

python:
version: 3.6
version: 3.7
pip_install: true
extra_requirements:
- redis
Expand Down
19 changes: 9 additions & 10 deletions setup.py
Original file line number Diff line number Diff line change
@@ -1,17 +1,15 @@
import re
import os
from pathlib import Path

from setuptools import setup, find_packages

with open(os.path.join(os.path.abspath(os.path.dirname(__file__)), "aiocache/_version.py")) as fp:
try:
version = re.findall(r"^__version__ = \"([^']+)\"\r?$", fp.read(), re.M)[0]
except IndexError:
raise RuntimeError("Unable to determine version.")
p = Path(__file__).with_name("aiocache") / "__init__.py"
try:
version = re.findall(r"^__version__ = \"([^']+)\"\r?$", p.read_text(), re.M)[0]
except IndexError:
raise RuntimeError("Unable to determine version.")


with open("README.rst", encoding="utf8") as f:
readme = f.read()
readme = Path(__file__).with_name("README.rst").read_text()


setup(
Expand All @@ -24,10 +22,11 @@
long_description=readme,
classifiers=[
"Programming Language :: Python",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Framework :: AsyncIO",
],
packages=find_packages(),
Expand Down
64 changes: 0 additions & 64 deletions tox.ini

This file was deleted.