Several minor documentation changes, plus:
* 'cancel' now has to be an exact match
* Cancel events return None instead of the spoken cancelation string
* Reduced timeout to 10 seconds instead of 20
* Changed 'text' to 'announcement' and simplified logic
Since the garbage collection can be on a bit on the slow side it
shouldn't be done at a normal user's device.
A developer can still enable this by setting the configuration flag
"debug" to true.
The reference count sometimes reported that references were remaining
even if they actually weren't. By enforcing a garbage collector run
after shutting down a skill the false possitives are reduced if not
removed all together.
- Add support for unnamed intents.
- Add more debugging information for skill handler errors
- Clean up skill name for pronounciation
- Update docstring for initialize method
Corrected my refinement after a previous review.
Also added support for splitting the name of a skill before running it through
TTS, making "VolumeSkill" sound like "Volume Skill" and such. Plus a log
message before raising some errors in the skill wrapper.
This allows skill writers to ignore naming intents. Combined with a
forthcoming change to Adapt that creates a default of None for IntentBuilder()
This allows the current:
@intent_handler(IntentBuilder("CurrentWeatherIntent").require(
"Weather").optionally("Location").build())
def handle_current_weather(self, message):
...
To become:
@intent_handler(IntentBuilder().require("Weather").optionally("Location"))
def handle_current_weather(self, message):
...
Which will automatically name the Intent "handle_current_weather".
Also dropped the log message in the default initialize() method since it is
common to not override it now.
==== Tech Notes ====
queue command will start playback if no playback is running.
mpg123 and vlc services updated support queueing tracks while playing
==== Protocol Notes ====
mycroft.audio.service.queue message added
A Skill can now implement the get_intro_message() method, which can return a
string to be spoken the very first time a skill is run. This is intended to
be an announcement, such as further steps necessary to setup the skill.
Also stopped generation of the Error message when the expected StopIteration
occurs on a intent failure. This confused new developers and poluted the logs.
Finally, corrected some documentation typos.
==== Tech Notes ====
This allows you to remove message bus messages inside core.py. When canceling scheduling events, the message bus messages were not removed which could caused duplicate listeners and handlers for the same intent. Adding remove_event function removes the actual messages from the bus to prevent potential duplicates.
==== Tech Notes ====
Location was added as a default context keyword when the context manager
was added as an example of how the context feature could be used.
However in the current greedy implementation in can cause some confusion
with lingering context providing incorrect Location.
The feature can still be turned on in configuration if someone wants to
experiment with it.