OpenVoiceOS / skill-ovos-wikipedia

wikipedia skill for mycroft
Apache License 2.0
7 stars 8 forks source link

wikipedia fails with no results #44

Closed denics closed 3 months ago

denics commented 3 months ago

I am running this query on the last code, in Italian: sistema solare, and I get:

13:05:07.261 - PHAL - ovos_bus_client.client.client:on_default_session_update:161 - DEBUG - synced default_session
 13:05:07.258 - voice - ovos_bus_client.client.client:on_default_session_update:161 - DEBUG - synced default_session
 13:05:07.281 - skills - ovos_bus_client.client.client:on_default_session_update:161 - DEBUG - synced default_session
 13:05:07.306 - skills - skill_ovos_wikipedia:get_data:71 - DEBUG - WikiSolver query: sistema solare
 13:05:07.327 - audio - ovos_plugin_manager.templates.tts:_get_ctxt:559 - DEBUG - TTS kwargs: {'lang': 'it-it', 'voice': 'default'}
 13:05:07.330 - audio - ovos_tts_plugin_server:_fetch_audio_data:86 - DEBUG - Chosen TTS server https://tts.smartgic.io/piper/v2/synthesize
  13:05:08.507 - skills - skill_ovos_wikipedia:get_data:95 - DEBUG - Found image: https://upload.wikimedia.org/wikipedia/commons/1/19/Solar_System_true_color.jpg
 13:05:08.512 - skills - ovos_utils.file_utils:resolve_resource_file:164 - WARNING - Deprecation version=0.1.0. Caller=ovos_utils.dialog:166. Expected a dict config and got None.
 13:05:08.545 - audio - ovos_audio.service:execute_tts:381 - INFO - Speak: Si è verificato un errore durante l'elaborazione di una richiesta in Wikipedia Skill
 13:05:08.532 - skill-ovos-wikipedia.openvoiceos - ERROR - 'WikipediaSkill' object has no attribute 'results'
Traceback (most recent call last):
  File "/home/denix/.venvs/ovos/lib/python3.11/site-packages/ovos_utils/events.py", line 78, in wrapper
    handler(message)
  File "/home/denix/.venvs/ovos/lib/python3.11/site-packages/skill_ovos_wikipedia/__init__.py", line 194, in handle_search
    self.speak_result(sess)
  File "/home/denix/.venvs/ovos/lib/python3.11/site-packages/skill_ovos_wikipedia/__init__.py", line 299, in speak_result
    if idx + 1 > len(self.results):
                     ^^^^^^^^^^^^
AttributeError: 'WikipediaSkill' object has no attribute 'results'
 13:05:08.792 - audio - ovos_plugin_manager.templates.tts:_get_ctxt:559 - DEBUG - TTS kwargs: {'lang': 'it-it', 'voice': 'default'}
 13:05:08.800 - audio - ovos_plugin_manager.templates.tts:get_from_cache:125 - INFO - Found 138f880ae04a751fce6daee47eef3f56.wav in TTS cache
 13:05:08.809 - audio - ovos_bus_client.session:get:594 - DEBUG - No message, use default session