diff --git a/ops/charm.py b/ops/charm.py index 99e1f2651..db02e13d9 100644 --- a/ops/charm.py +++ b/ops/charm.py @@ -668,7 +668,9 @@ def restore(self, snapshot: Dict[str, Any]): if storage_name and storage_index is not None: storages = self.framework.model.storages[storage_name] - self.storage = next((s for s in storages if s.index == storage_index), None) # type: ignore + self.storage = next( + (s for s in storages if s.index == storage_index), + None) # type: ignore if self.storage is None: msg = 'failed loading storage (name={!r}, index={!r}) from snapshot' \ .format(storage_name, storage_index) diff --git a/tox.ini b/tox.ini index a5330ae56..15c1a46f8 100644 --- a/tox.ini +++ b/tox.ini @@ -36,9 +36,9 @@ commands = description = Apply coding style standards to code deps = autopep8~=1.6 - isort~=5.11 + isort~=5.13 commands = - isort {[vars]all_path} + isort {[vars]all_path} --multi-line=3 --line-length=99 --split-on-trailing-comma autopep8 --in-place {[vars]all_path} [testenv:lint]