Closed JohnMcLear closed 3 years ago
@JohnMcLear, Thank you for the log information as that is helpful. As far as the pip install(s). For some reason the latest Mycroft does not install the required dependencies automatically. It was successful in the previous version. At this point I am not sure why the requirements installation are failing but you are correct I should add the manual installation process to the readme. I noticed from your log that the skill settings are still default. Did you update the settings in your "account.mycroft.ai"? Also after you have done that try issuing the command "update music library". This should index all your files and report what it has found. Thanks for testing this skill
I went ahead and changed the path to /home/pi/mycroft-core/usb-music
and hit save in the settings. I then unplugged and plugged back in my USB stick and it did update the sources.
Trying to do play my music
returns
2021-05-08 16:29:35.668 | INFO | 2496 | Playback Control Skill | Resolving Player for: my music
2021-05-08 16:29:35.676 | INFO | 2496 | ReSpeaker_4mic_hat | Pixel Ring: Think
2021-05-08 16:29:35.701 | INFO | 2496 | ReSpeaker_4mic_hat | Pixel Ring: Speak
2021-05-08 16:29:38.400 | INFO | 2496 | ReSpeaker_4mic_hat | Pixel Ring: Off
2021-05-08 16:29:38.493 | INFO | 2496 | usb-music_pcwii:CPS_match_query_phrase:389 | USBMusicSkill received the following phrase: my music
2021-05-08 16:29:38.495 | INFO | 2496 | usb-music_pcwii:CPS_match_query_phrase:391 | USBMusicSkill is Searching for requested media...
2021-05-08 16:29:38.507 | INFO | 2496 | usb-music_pcwii:parse_music_utterance:147 | Parse Music Received: my music
2021-05-08 16:29:38.509 | INFO | 2496 | ReSpeaker_4mic_hat | Pixel Ring: Off
Removing event mycroft-playback-control.mycroftai:PlayQueryTimeout
2021-05-08 16:29:38.517 | INFO | 2496 | usb-music_pcwii:parse_music_utterance:169 | Primary Regex Key Not Found
Removing event mycroft-playback-control.mycroftai:PlayQueryTimeout
2021-05-08 16:29:38.538 | ERROR | 2496 | mycroft.skills.mycroft_skill.mycroft_skill:on_error:835 | An error occurred while processing a request in USB Music Skill
Traceback (most recent call last):
File "/home/pi/mycroft-core/mycroft/skills/mycroft_skill/event_container.py", line 66, in wrapper
handler(message)
File "/home/pi/mycroft-core/mycroft/skills/common_play_skill.py", line 96, in __handle_play_query
result = self.CPS_match_query_phrase(search_phrase)
File "/opt/mycroft/skills/usb-music.pcwii/__init__.py", line 392, in CPS_match_query_phrase
play_request = self.parse_music_utterance(phrase) # get the requested Music Item
File "/opt/mycroft/skills/usb-music.pcwii/__init__.py", line 171, in parse_music_utterance
if key_found.group("any"):
AttributeError: 'NoneType' object has no attribute 'group'
2021-05-08 16:29:38.548 | INFO | 2496 | mycroft.skills.settings:save_settings:116 | Skill settings successfully saved to /home/pi/.config/mycroft/skills/usb-music.pcwii/settings.json
2021-05-08 16:29:39.837 | INFO | 2496 | ReSpeaker_4mic_hat | Pixel Ring: Speak
So I need a music skill, which one would you recommend? All of the ones I have tested are basically broken ;\
I wrote this one, as there are no great music skills for local music playback. I have not actually implemented a call for "play my music". I will add this command and see if it does what you expect, give me a couple hours to get it updated on github.
Ah, great thanks!
Just FYI: I tried "play music by Elton John" too and I think I got an error doing that, would you expect that should work?
As I have been digging into this I have noticed a couple things that are not working as expected. It may take me a bit to clean it up but I am on it. If you could try a couple things for me that would be helpful.
artist:""
?play the song <insert song name>
?I appreciate all the testing and feedback you have provided. I will try to get this cleaned up so that you have a music app that is not "broken" ;-) Cheers!
Will have some test results for you within the hour.
Thanks for taking your time to help debug, we're making great progress now :)
''
.Thanks!
@JohnMcLear Thanks for testing that.
Heads up, went to test things today and "play my music" and I got error 2021-05-10 14:15:35.400 | INFO | 800 | usb-music_pcwii:CPS_match_query_phrase:426 | Device or Library Not Ready, Passing on this request
I detatched > attached the USB stick and I get the "im indexing number of songs will take time to complete" but it never completes.
I think the offending mp3 causing an issue is
2021-05-10 14:16:40.366 | INFO | 800 | usb-music_pcwii:create_library:360 | Validating title: Anymore
2021-05-10 14:16:40.367 | INFO | 800 | usb-music_pcwii:create_library:368 | Validating artist: The Cat Empire
2021-05-10 14:16:40.379 | INFO | 800 | usb-music_pcwii:create_library:353 | Checking m4a Tags{'©nam': ['So Many Nights'], '©ART': ['The Cat Empire'], '©wrt': ['Felix Riebl'], '©alb': ['So Many Nights'], '©gen': ['Alternative'], 'trkn': [(1, 14)], 'disk': [(1, 1)], '©day': ['2007'], 'cpil': False, 'pgap': False, 'tmpo': [0], '©too': ['iTunes 10.0.1.22, QuickTime 7.6.8'], '----:com.apple.iTunes:iTunSMPB': [MP4FreeForm(b' 00000000 00000840 00000180 00000000008ED640 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000', <AtomDataType.UTF8: 1>)], '----:com.apple.iTunes:Encoding Params': [MP4FreeForm(b'vers\x00\x00\x00\x01acbf\x00\x00\x00\x02brat\x00\x03\xe8\x00srcq\x00\x00\x00\x7fcdcv\x00\x01\x07\x02', <AtomDataType.IMPLICIT: 0>)], '----:com.apple.iTunes:iTunNORM': [MP4FreeForm(b' 00001326 00001109 00006C33 00008B49 0002DF82 00022C47 00008000 00008000 0000914E 0001A33A', <AtomDataType.UTF8: 1>)], '----:com.apple.iTunes:iTunes_CDDB_IDs': [MP4FreeForm(b'14++', <AtomDataType.UTF8: 1>)], '----:com.apple.iTunes:UFIDhttp://www.cddb.com/id3/taginfo1.html': [MP4FreeForm(b'3CD3N48Q138148622U4181E7F7B7B5F7A453ED7B9FC022F72D2F2P3', <AtomDataType.UTF8: 1>)], 'aART': ['Cat Empire, The']}
(.venv) pi@picroft:/var/log/mycroft $
I have been trying to sort out the issues with the artist last night and added some additional logging to point me to the problem, This logging is causing the indexing to take a very long time. Things may be broken a bit until I can sort it out. Hope to get it cleaned up later today. Thanks for the patience.
@JohnMcLear Looks like I may have sorted out a couple issues. You should be able to issue the command play music by Elton John
now and it should recognize the artist(s) now. Indexing of the library initially is not very fast, I will look at ways to speed it up. It took about 8 minutes to index about 2097 songs on my smb share. Hopefully now you have a working music player for mycroft.
Good job man! Thanks very much.
Post installation using
msm install https://github.com/pcwii/usb-music.git
on picroft the commands are not working with no errors on the UI.In
skills.log
I getand post installation of
pyudev
I get:Resolution
Permanent fix?
Perhaps the installation docs should also include steps to include deps? Perhaps the installation should error if it fails during
msm install
? -- upstream issue will let maintainer decide best course of action.Related to https://github.com/pcwii/usb-music/issues/2
Successful output
It appears indexing of music does then work but playback does not.
No playback still.,.