Closed ezmetic closed 4 years ago
Yep - the underlying library that this uses dropped python2 support in January https://github.com/simon-weber/gmusicapi#status-and-updates
it may be that you need to specify python3: $ python3 gmpydl.py
Python3 should be installed by default (I'm reasonably sure)
Thanks. I've tried running the script as python3 ,which gave me syntax errors with print lines missing ( ) characters. I've fixed those, and then ended up with this error:
$ python3 gmpydl.py
Traceback (most recent call last):
File "gmpydl.py", line 13, in
Yes this is going to need some work to move to python 3 (gmusicapi was originally PY2 only so I wrote this as such).
Also, you will need to install gmusicapi in pip3 (and maybe even install python3-pip) to get the python3 versions of the module.
Along with your changes, this should work - feel free to submit any changes you make to get this Python3 compatible. I don't have a GPM account any more so i cant really verify any changes I make.
Thanks for tips and notes :) I will try it out, see if I can make it work. Will post here if I submit a working solution.
This should be resolved with the latest merge to master to move this to Python3
Sorry if posting this the wrong way or place! I'm really new to linux, using it only on my raspberry pi, but I've tried to install this great tool (using a few step-by-step guides from the internet). I have installed git, I have installed the gmusicapi, and cloned and installed gmpydl. I have Python 2.7.13.
When running gmpydl, I keep getting this Invalid Syntax error:
Traceback (most recent call last): File "./gmpydl.py", line 13, in
from gmusicapi import Musicmanager
File "/usr/local/lib/python2.7/dist-packages/gmusicapi/init.py", line 2, in
from gmusicapi.clients import Webclient, Musicmanager, Mobileclient
File "/usr/local/lib/python2.7/dist-packages/gmusicapi/clients/init.py", line 1, in
from gmusicapi.clients.webclient import Webclient
File "/usr/local/lib/python2.7/dist-packages/gmusicapi/clients/webclient.py", line 5, in
from gmusicapi.clients.shared import _Base
File "/usr/local/lib/python2.7/dist-packages/gmusicapi/clients/shared.py", line 10
class _Base(metaclass=utils.DocstringInheritMeta):
^
SyntaxError: invalid syntax
(The syntax pointer points to the = sign in the last line)
Some sources on the internet mention it's got something to do with python 2 or 3, but I'm at a loss about how to fix it.