From 9ba12e3f0d450abd422704b0d35840085f4d11ca Mon Sep 17 00:00:00 2001 From: Michael Pimmer Date: Thu, 6 Aug 2020 13:13:26 +0200 Subject: [PATCH] Meta documentation update: valid args describe valid args of getting/setting/deleting meta indicators --- ixmp/backend/base.py | 25 +++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/ixmp/backend/base.py b/ixmp/backend/base.py index 411d9dbd1..6f575d1d7 100644 --- a/ixmp/backend/base.py +++ b/ixmp/backend/base.py @@ -941,6 +941,13 @@ def get_meta(self, model: str, scenario: str, version: int) -> dict: ------- dict (str -> any) Mapping from meta category keys to values. + + Raises + ------ + ValueError + On unsupported model-scenario-version combinations. + Supported combinations are: (model), (scenario), (model, scenario), + (model, scenario, version) """ @abstractmethod @@ -960,6 +967,13 @@ def set_meta(self, meta: dict, model: str, scenario: str, version: int): Returns ------- None + + Raises + ------ + ValueError + On unsupported model-scenario-version combinations. + Supported combinations are: (model), (scenario), (model, scenario), + (model, scenario, version) """ @abstractmethod @@ -980,6 +994,13 @@ def remove_meta(self, categories: list, model: str, scenario: str, Returns ------- None + + Raises + ------ + ValueError + On unsupported model-scenario-version combinations. + Supported combinations are: (model), (scenario), (model, scenario), + (model, scenario, version) """ @abstractmethod @@ -990,10 +1011,6 @@ def get_scenario_meta(self, s: Scenario): ------- dict (str -> any) Mapping from meta keys to values. - - See also - -------- - s_get_meta """ @abstractmethod