Skip to content

Commit

Permalink
Add Runtime Requirements (#11)
Browse files Browse the repository at this point in the history
* Add Runtime Requirements

* Update skill.json

* Correct RuntimeRequirements

---------

Co-authored-by: NeonDaniel <NeonDaniel@users.noreply.github.com>
  • Loading branch information
NeonDaniel and NeonDaniel committed Feb 24, 2023
1 parent 2a0473f commit 3023689
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
14 changes: 14 additions & 0 deletions __init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@
from mycroft import Message, intent_handler
from neon_utils.skills.instructor_skill import InstructorSkill
from neon_utils.message_utils import get_message_user
from ovos_utils import classproperty
from ovos_utils.process_utils import RuntimeRequirements
from .recipe_utils import Recipe, RecipeStorage


Expand Down Expand Up @@ -95,6 +97,18 @@ def __init__(self):
self.internal_language = "en"
self.recipe_storage = RecipeStorage()

@classproperty
def runtime_requirements(self):
return RuntimeRequirements(network_before_load=False,
internet_before_load=False,
gui_before_load=False,
requires_internet=True,
requires_network=True,
requires_gui=False,
no_internet_fallback=False,
no_network_fallback=False,
no_gui_fallback=True)

# intent handlers
@intent_handler('get.recipe.by.name.intent')
def handle_search_recipe_by_name(self, message: Message):
Expand Down
3 changes: 2 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
neon-utils~=0.6
neon-utils~=1.0
ovos-utils~=0.0.28
3 changes: 2 additions & 1 deletion skill.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
"systemDeps": false,
"requirements": {
"python": [
"neon-utils~=0.6"
"neon-utils~=1.0",
"ovos-utils~=0.0.28"
],
"system": {},
"skill": []
Expand Down

0 comments on commit 3023689

Please sign in to comment.