From eba1ecdaacbcbf29e324c637f23da5f0c102cde4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Behmo?= Date: Tue, 1 Sep 2020 14:15:33 +0200 Subject: [PATCH 1/2] Deprecate WaffleSample feature toggle annotation implementation As far as we understand, this implementation is used nowhere. --- .../config_and_tools/config/feature_toggle_annotations.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml b/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml index 4d2aeeb..e3f149d 100644 --- a/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml +++ b/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml @@ -11,7 +11,7 @@ annotations: feature_toggle: - ".. toggle_name:": - ".. toggle_implementation:": - choices: [ExperimentWaffleFlag, WaffleFlag, WaffleSample, WaffleSwitch, CourseWaffleFlag, ConfigurationModel, DjangoSetting] + choices: [ExperimentWaffleFlag, WaffleFlag, WaffleSwitch, CourseWaffleFlag, ConfigurationModel, DjangoSetting] - ".. toggle_default:": - ".. toggle_description:": - ".. toggle_category:": From fa1f5b022ea2bb5d142081731cf9209c63946bc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9gis=20Behmo?= Date: Wed, 2 Sep 2020 09:18:34 +0200 Subject: [PATCH 2/2] [BD-21] Update feature toggle annotation config The following changes are made to the feature toggle annotation config: 1. the `toggle_category` annotation is deprecated 2. the list of `toggle_use_cases` is simplified 3. the `toggle_status` field is deprecated 4. `toggle_expiration_date` was renamed to `toggle_target_removal_date` 5. Add SettingToggle, SettingDictToggle toggle implementations OEP-17 will be updated correspondingly. --- CHANGELOG.rst | 5 +++++ code_annotations/__init__.py | 2 +- .../config/feature_toggle_annotations.yaml | 8 +++----- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 65cca76..d2074a8 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -11,6 +11,11 @@ Change Log .. There should always be an "Unreleased" section for changes pending release. +[0.7.0] - 2020-09-07 +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +* Simplify the feature toggle annotation format + [0.6.0] - 2020-08-27 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ diff --git a/code_annotations/__init__.py b/code_annotations/__init__.py index 8538025..cb705bc 100644 --- a/code_annotations/__init__.py +++ b/code_annotations/__init__.py @@ -2,4 +2,4 @@ Extensible tools for parsing annotations in codebases. """ -__version__ = '0.6.0' +__version__ = '0.7.0' diff --git a/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml b/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml index e3f149d..ff94e2e 100644 --- a/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml +++ b/code_annotations/config_and_tools/config/feature_toggle_annotations.yaml @@ -11,17 +11,15 @@ annotations: feature_toggle: - ".. toggle_name:": - ".. toggle_implementation:": - choices: [ExperimentWaffleFlag, WaffleFlag, WaffleSwitch, CourseWaffleFlag, ConfigurationModel, DjangoSetting] + choices: [WaffleFlag, WaffleSwitch, CourseWaffleFlag, ExperimentWaffleFlag, SettingToggle, SettingDictToggle, ConfigurationModel, DjangoSetting] - ".. toggle_default:": - ".. toggle_description:": - - ".. toggle_category:": - ".. toggle_use_cases:": - choices: [incremental_release, launch_date, monitored_rollout, graceful_degradation, beta_testing, vip, opt_out, opt_in, open_edx] + choices: [temporary, circuit_breaker, vip, opt_out, opt_in, open_edx] - ".. toggle_creation_date:": - - ".. toggle_expiration_date:": + - ".. toggle_target_removal_date:": - ".. toggle_warnings:": - ".. toggle_tickets:": - - ".. toggle_status:": extensions: python: - py