diff --git a/.github/workflows/publish_stable.yml b/.github/workflows/publish_stable.yml index 894b487a..1f2a2423 100644 --- a/.github/workflows/publish_stable.yml +++ b/.github/workflows/publish_stable.yml @@ -26,7 +26,7 @@ jobs: - name: Setup Python uses: actions/setup-python@v1 with: - python-version: 3.8 + python-version: '3.11' - name: Install Build Tools run: | python -m pip install build wheel diff --git a/.github/workflows/release_workflow.yml b/.github/workflows/release_workflow.yml index 8dd76bf6..d2f5b3c7 100644 --- a/.github/workflows/release_workflow.yml +++ b/.github/workflows/release_workflow.yml @@ -46,7 +46,7 @@ jobs: - name: Setup Python uses: actions/setup-python@v1 with: - python-version: 3.8 + python-version: '3.11' - name: Install Build Tools run: | python -m pip install build wheel diff --git a/CHANGELOG.md b/CHANGELOG.md index 67cb8894..36ca0b2d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,24 +1,12 @@ # Changelog -## [3.3.0a1](https://github.com/OpenVoiceOS/OVOS-workshop/tree/3.3.0a1) (2024-12-31) +## [3.3.1a1](https://github.com/OpenVoiceOS/OVOS-workshop/tree/3.3.1a1) (2025-01-04) -[Full Changelog](https://github.com/OpenVoiceOS/OVOS-workshop/compare/3.2.2a1...3.3.0a1) - -**Closed issues:** - -- refactor: simplify common query [\#314](https://github.com/OpenVoiceOS/OVOS-workshop/issues/314) - -**Merged pull requests:** - -- feat:common\_query\_decorator [\#315](https://github.com/OpenVoiceOS/OVOS-workshop/pull/315) ([JarbasAl](https://github.com/JarbasAl)) - -## [3.2.2a1](https://github.com/OpenVoiceOS/OVOS-workshop/tree/3.2.2a1) (2024-12-26) - -[Full Changelog](https://github.com/OpenVoiceOS/OVOS-workshop/compare/3.2.1...3.2.2a1) +[Full Changelog](https://github.com/OpenVoiceOS/OVOS-workshop/compare/3.3.0...3.3.1a1) **Merged pull requests:** -- fix: voc\_match ignore case [\#312](https://github.com/OpenVoiceOS/OVOS-workshop/pull/312) ([JarbasAl](https://github.com/JarbasAl)) +- chore: add warnings [\#317](https://github.com/OpenVoiceOS/OVOS-workshop/pull/317) ([JarbasAl](https://github.com/JarbasAl)) diff --git a/ovos_workshop/backwards_compat.py b/ovos_workshop/backwards_compat.py index 4a57f4cb..788ab1f8 100644 --- a/ovos_workshop/backwards_compat.py +++ b/ovos_workshop/backwards_compat.py @@ -1,3 +1,10 @@ +import warnings +warnings.warn( + "will be removed soon", + DeprecationWarning, + stacklevel=2, +) + try: # TODO - remove this file in next stable release from ovos_utils.ocp import * except ImportError: diff --git a/ovos_workshop/decorators/__init__.py b/ovos_workshop/decorators/__init__.py index 823361ea..d9a099a8 100644 --- a/ovos_workshop/decorators/__init__.py +++ b/ovos_workshop/decorators/__init__.py @@ -1,7 +1,7 @@ from functools import wraps from typing import Optional, Callable from ovos_utils.log import log_deprecation - +import warnings from ovos_workshop.decorators.killable import killable_intent, killable_event from ovos_workshop.decorators.layers import enables_layer, \ disables_layer, layer_intent, removes_layer, resets_layers, replaces_layer @@ -75,6 +75,11 @@ def intent_file_handler(intent_file: str): """ Deprecated decorator for adding a method as an intent file handler. """ + warnings.warn( + "Use `@intent_handler' instead", + DeprecationWarning, + stacklevel=2, + ) def real_decorator(func): # Store the intent_file inside the function diff --git a/ovos_workshop/decorators/converse.py b/ovos_workshop/decorators/converse.py index f4e5fcc2..8c4c17d5 100644 --- a/ovos_workshop/decorators/converse.py +++ b/ovos_workshop/decorators/converse.py @@ -1,4 +1,11 @@ from ovos_utils.log import log_deprecation +import warnings + +warnings.warn( + "Import from `ovos_workshop.decorators`", + DeprecationWarning, + stacklevel=2, +) def converse_handler(func): diff --git a/ovos_workshop/decorators/fallback_handler.py b/ovos_workshop/decorators/fallback_handler.py index 76ff7861..3e9f8dd6 100644 --- a/ovos_workshop/decorators/fallback_handler.py +++ b/ovos_workshop/decorators/fallback_handler.py @@ -1,5 +1,12 @@ from ovos_utils.log import log_deprecation +import warnings + +warnings.warn( + "Import from `ovos_workshop.decorators`", + DeprecationWarning, + stacklevel=2, +) def fallback_handler(priority=50): log_deprecation("Import from `ovos_workshop.decorators`", "0.1.0") diff --git a/ovos_workshop/intents.py b/ovos_workshop/intents.py index 6355f935..32386598 100644 --- a/ovos_workshop/intents.py +++ b/ovos_workshop/intents.py @@ -3,7 +3,7 @@ from os.path import exists from threading import RLock from typing import List, Tuple, Optional - +import warnings from ovos_bus_client.message import Message, dig_for_message from ovos_bus_client.util import get_mycroft_bus from ovos_utils.log import LOG, log_deprecation @@ -500,6 +500,11 @@ class expect intent_name; this was the weird one expecting the internal name = intent_name.split(':')[1] log_deprecation(f"Update to `self.remove_intent({name})", "0.1.0") + warnings.warn( + "use `self.remove_intent' instead", + DeprecationWarning, + stacklevel=2, + ) self.remove_intent(name) def remove_intent(self, intent_name: str): @@ -614,6 +619,11 @@ def register_padatious_entity(self, entity_name: str, filename: str, def get_intent_names(self): log_deprecation("Reference `intent_names` directly", "0.1.0") + warnings.warn( + "use `self.intent_names' property instead", + DeprecationWarning, + stacklevel=2, + ) return self.intent_names def detach_all(self): diff --git a/ovos_workshop/skill_launcher.py b/ovos_workshop/skill_launcher.py index 0d55fd0d..0458f70b 100644 --- a/ovos_workshop/skill_launcher.py +++ b/ovos_workshop/skill_launcher.py @@ -13,7 +13,7 @@ from ovos_plugin_manager.skills import find_skill_plugins, get_skill_directories from ovos_utils import wait_for_exit_signal from ovos_utils.file_utils import FileWatcher -from ovos_utils.log import LOG, deprecated, log_deprecation +from ovos_utils.log import LOG, log_deprecation from ovos_utils.process_utils import RuntimeRequirements from ovos_workshop.skills.active import ActiveSkill diff --git a/ovos_workshop/skills/common_query_skill.py b/ovos_workshop/skills/common_query_skill.py index eb7564ff..4eaec4fb 100644 --- a/ovos_workshop/skills/common_query_skill.py +++ b/ovos_workshop/skills/common_query_skill.py @@ -18,7 +18,7 @@ from ovos_bus_client import Message from ovos_utils.file_utils import resolve_resource_file from ovos_utils.log import LOG, log_deprecation - +import warnings from ovos_workshop.skills.ovos import OVOSSkill @@ -60,6 +60,11 @@ class CommonQuerySkill(OVOSSkill): def __init__(self, *args, **kwargs): log_deprecation("'CommonQuerySkill' class has been deprecated, use @common_query decorator with regular OVOSSkill instead", "4.0.0") + warnings.warn( + "use '@common_query' decorator with regular OVOSSkill instead", + DeprecationWarning, + stacklevel=2, + ) # these should probably be configurable self.level_confidence = { CQSMatchLevel.EXACT: 0.9, diff --git a/ovos_workshop/skills/intent_provider.py b/ovos_workshop/skills/intent_provider.py index 8009765a..4f8742cb 100644 --- a/ovos_workshop/skills/intent_provider.py +++ b/ovos_workshop/skills/intent_provider.py @@ -4,10 +4,21 @@ from ovos_bus_client.message import Message from ovos_workshop.skills.fallback import FallbackSkill from ovos_config.config import read_mycroft_config, update_mycroft_config +import warnings +warnings.warn( + "use pipeline plugins instead", + DeprecationWarning, + stacklevel=2, +) class BaseIntentEngine: def __init__(self, name, config=None): + warnings.warn( + "make a pipeline plugin instead", + DeprecationWarning, + stacklevel=2, + ) log_deprecation("This base class is not supported", "0.1.0") self.name = name.lower() config = config or read_mycroft_config() @@ -51,6 +62,11 @@ def calc_intent(self, query): class IntentEngineSkill(FallbackSkill): def __init__(self, *args, **kwargs): + warnings.warn( + "make a pipeline plugin instead", + DeprecationWarning, + stacklevel=2, + ) log_deprecation("This base class is not supported", "0.1.0") super().__init__(*args, **kwargs) self.engine = None diff --git a/ovos_workshop/skills/layers.py b/ovos_workshop/skills/layers.py index dcedc619..ff9b3f90 100644 --- a/ovos_workshop/skills/layers.py +++ b/ovos_workshop/skills/layers.py @@ -1,3 +1,10 @@ from ovos_workshop.decorators.layers import IntentLayers from ovos_utils.log import log_deprecation log_deprecation("Import from `ovos_workshop.decorators.layers`", "0.1.0") +import warnings + +warnings.warn( + "Import from `ovos_workshop.decorators.layers`", + DeprecationWarning, + stacklevel=2, +) diff --git a/ovos_workshop/version.py b/ovos_workshop/version.py index b1431a0b..55f850ab 100644 --- a/ovos_workshop/version.py +++ b/ovos_workshop/version.py @@ -1,6 +1,6 @@ # START_VERSION_BLOCK VERSION_MAJOR = 3 VERSION_MINOR = 3 -VERSION_BUILD = 0 -VERSION_ALPHA = 0 +VERSION_BUILD = 1 +VERSION_ALPHA = 1 # END_VERSION_BLOCK