MycroftAI / mycroft-core

Mycroft Core, the Mycroft Artificial Intelligence platform.
https://mycroft.ai
Apache License 2.0
6.51k stars 1.27k forks source link

Use response method for track_info handler #2974

Open krisgesling opened 3 years ago

krisgesling commented 3 years ago

Description

The audioservice.track_info handler was using a custom reply message, which is an older form of replying to a message.

This required you to know what the reply_type is eg:

response = self.bus.wait_for_response(
            Message('mycroft.audio.service.track_info'),
            reply_type='mycroft.audio.service.track_info_reply')

The new format is automatic:

response = self.bus.wait_for_response(
            Message('mycroft.audio.service.track_info'))

This is a breaking change as any calls expecting the custom reply_type will break. Creating the PR now so that we can switch it over in the next major release.

How to test

Using the new standard format of wait_for_response as above will currently result in no response being received. With this change, the reply conforms to the new standard and will be returned correctly.

devops-mycroft commented 3 years ago

Voight Kampff Integration Test Succeeded (Results)