Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
senpy
senpy
Commits
384aba46
Commit
384aba46
authored
Apr 26, 2015
by
J. Fernando Sánchez
Browse files
Sleep plugin sleeps on request too
parent
a857dd30
Changes
2
Hide whitespace changes
Inline
Side-by-side
tests/sleep_plugin/sleep.py
View file @
384aba46
...
...
@@ -13,4 +13,5 @@ class SleepPlugin(SenpyPlugin):
sleep
(
self
.
timeout
)
def
analyse
(
self
,
*
args
,
**
kwargs
):
sleep
(
float
(
kwargs
.
get
(
"timeout"
,
self
.
timeout
)))
return
Response
()
tests/sleep_plugin/sleep.senpy
View file @
384aba46
...
...
@@ -4,5 +4,13 @@
"description": "I am dummy",
"author": "@balkian",
"version": "0.1",
"timeout": "2"
"timeout": "2",
"extra_params": {
"timeout": {
"@id": "timeout_sleep",
"aliases": ["timeout", "to"],
"required": false,
"default": 0
}
}
}
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment