Home of the Squeezebox™ & Transporter® network music players.
Page 11 of 12 FirstFirst ... 9101112 LastLast
Results 101 to 110 of 111
  1. #101
    Unfortunately, given that Google Music is due to be retired soon, there's not much work happening on this, particularly given that any work with the API is stabbing in the dark, since it's all unoffical reverse-engineered anyway. It's time to change to another system. I believe Spotify is well supported in LMS (for paid subscriptions at least), and has a publicly documented API, so is likely to be more resilient. No idea about Tidal though.

  2. #102

    Thank you VICTOR -

    Quote Originally Posted by askvictor View Post
    Unfortunately, given that Google Music is due to be retired soon, there's not much work happening on this, particularly given that any work with the API is stabbing in the dark, since it's all unoffical reverse-engineered anyway. It's time to change to another system. I believe Spotify is well supported in LMS (for paid subscriptions at least), and has a publicly documented API, so is likely to be more resilient. No idea about Tidal though.
    The work you and others - Simon Weber - Hectus created a period of access I/we have greatly appreciated.

    I will trial the use of spotify - spotty first then Tidal

    There is a shame for google music which I like in most other aspects.

    Thank you for replying I will update any experience in transitioning.

  3. #103
    Junior Member
    Join Date
    May 2014
    Posts
    19
    User/Password based auth with gmusicapi has started failing for me. When I restarted the 'GMusicProxy' after months of uptime, it would not log in and neither would my LMS installation.

    After some hunting and research, the OAuth login method is still working well, and I wanted to drop a note here for those like myself who are still clinging to Google Music.

    You need to upgrade the underlying 'gmusicapi' to at least 11.1.1 (that's what I used since 12.0.0 had some dependency issue on my old Debian system)

    Next, amend the 'Plugin.pm' 'initPlugin' function (around line 88) to this:

    # Try to login. If SSL verification fails, login() raises an
    # exception. Catch it to allow the plugin to be started.
    eval {
    $googleapi->oauth_login($prefs->get('device_id'));
    };
    if ($@) {
    $log->error("Not able to login to Google Play Music: $@");
    }

    Since we are no longer sending a username or password, we need to get an OAuth token block. The easiest way to do this is to use a new version of GMusicProxy from this repo: https://github.com/jeffmhubbard/gmusicproxy

    Run 'GMusicProxy --oauth' - it'll generate a web URL that you paste into your browser, authenticate with Google, and will write out a local file.

    Restart LMS and watch the logs - it will probably complain something like

    Plugins::GoogleMusic::Plugin::initPlugin (93) Not able to login to Google Play Music: exceptions.IOError: [Errno 13] Permission denied: u'/usr/share/squeezeboxserver/.local/share/gmusicapi/mobileclient.cred' at line 183

    Copy the OAuth file creds file to that location, maybe mess around with file permissions so the LMS user has access to read the file, restart LMS again and you should be back in business. Hope that helps someone.
    Last edited by gdhgdh; 2019-12-19 at 03:04.

  4. #104
    Senior Member
    Join Date
    Sep 2007
    Posts
    181
    Quote Originally Posted by gdhgdh View Post
    User/Password based auth with gmusicapi has started failing for me. When I restarted the 'GMusicProxy' after months of uptime, it would not log in and neither would my LMS installation.

    After some hunting and research, the OAuth login method is still working well, and I wanted to drop a note here for those like myself who are still clinging to Google Music.

    You need to upgrade the underlying 'gmusicapi' to at least 1.11.1 (that's what I used since 1.12.0 had some dependency issue on my old systems)
    ....
    I did all you said:
    gmusicapi 11.1.1
    created mobileclient.cred
    Altered the Plugin.pm

    But I get:
    Plugins::GoogleMusic::Plugin::initPlugin (96) Not able to login to Google Play Music: Python object has no method named oauth_login at /usr/local/lib/arm-linux-gnueabi/perl/5.24.1/Inline/Python.pm line 337.

    What have I done wrong?

  5. #105
    Junior Member
    Join Date
    May 2014
    Posts
    19
    Quote Originally Posted by bits View Post
    I did all you said:
    Plugins::GoogleMusic::Plugin::initPlugin (96) Not able to login to Google Play Music: Python object has no method named oauth_login at /usr/local/lib/arm-linux-gnueabi/perl/5.24.1/Inline/Python.pm line 337.

    What have I done wrong?
    from the arm-linux I'm guessing this is running on a Raspi of some kind. The /usr/local tells me there's been some './configure; make; make install' software installations going on, so yeah there are 100 ways to cut yourself with that.

    The "Python object has no method named oauth_login" only tells me that whatever Python installation that Perl 5 is seeing is not the same one that you installed the new gmusicapi into. I did also notice a slight typo.. you mentioned ' gmusicapi 11.1.1 ' .. I used 1.11.1

    I mean, you might have both Python2 and Python3 on your system in which case you could try 'pip install gmusicapi==1.11.1' as well as 'pip3 install gmusicapi==1.11.1'

    Good luck!

  6. #106
    Senior Member
    Join Date
    Sep 2007
    Posts
    181
    Quote Originally Posted by gdhgdh View Post
    from the arm-linux I'm guessing this is running on a Raspi of some kind. The /usr/local tells me there's been some './configure; make; make install' software installations going on, so yeah there are 100 ways to cut yourself with that.

    The "Python object has no method named oauth_login" only tells me that whatever Python installation that Perl 5 is seeing is not the same one that you installed the new gmusicapi into. I did also notice a slight typo.. you mentioned ' gmusicapi 11.1.1 ' .. I used 1.11.1

    I mean, you might have both Python2 and Python3 on your system in which case you could try 'pip install gmusicapi==1.11.1' as well as 'pip3 install gmusicapi==1.11.1'

    Good luck!
    It is the smallest things that help!
    pip2 install gmusicapi==11.1.1 << updated 11.0.1 to 11.1.1

    My box is Debian 9.11 on Qnap NAS.
    pip tells me there is no 1.11.1, also every gmusicapi page I can find lists versions as 11.1.1 and 12.1.0 etc.

    I am now on to:
    [19-12-19 08:29:35.7226] Plugins::GoogleMusic::Plugin::initPlugin (96) Not able to login to Google Play Music: exceptions.OSError: [Errno 13] Permission denied: '/usr/share/squeezeboxserver/.local' at line 183

    But I have to head off to my day job so will work on this later.
    Thanks for the hint about the wrong Python!

  7. #107
    Junior Member
    Join Date
    May 2014
    Posts
    19
    Quote Originally Posted by bits View Post
    It is the smallest things that help!
    pip2 install gmusicapi==11.1.1 << updated 11.0.1 to 11.1.1

    My box is Debian 9.11 on Qnap NAS.
    pip tells me there is no 1.11.1, also every gmusicapi page I can find lists versions as 11.1.1 and 12.1.0 etc.

    I am now on to:
    [19-12-19 08:29:35.7226] Plugins::GoogleMusic::Plugin::initPlugin (96) Not able to login to Google Play Music: exceptions.OSError: [Errno 13] Permission denied: '/usr/share/squeezeboxserver/.local' at line 183

    But I have to head off to my day job so will work on this later.
    Thanks for the hint about the wrong Python!
    Ahh excellent - in that case yes the typo was all mine. I'll update my original post to reduce confusion in future.

    I just checked 'pip list' and sure enough I do have 11.1.1 installed.

    The Permission denied errors can be resolved easily with a bit of chmod / chown - best to chown -R the path from /usr/share/squeezeboxserver to whichever user the squeezeboxserver app is running as, but yes chmod -R 755 will also do to make /usr/share/squeezeboxserver/.local/share/gmusicapi/mobileclient.cred readable by any user.

  8. #108
    Senior Member
    Join Date
    Sep 2007
    Posts
    181
    And it works. Thanks mate!

    I got sidetracked updating my box from Debian 9.11 to 10.2 and cleaning up my hacked up pip and other packges etc.
    But now my Google Music access is restored.

    Noteworthy things for my system:
    mkdir /usr/share/squeezeboxserver/.local/share/gmusicapi
    cp /root/.local/share/gmusicapi/mobileclient.cred /usr/share/squeezeboxserver/.local/share/gmusicapi/
    chown squeezeboxserver /usr/share/squeezeboxserver/.local/share/gmusicapi/mobileclient.cred
    Last edited by bits; 2019-12-19 at 06:34.

  9. #109

    Got it working again on a max2play

    Just wanted to post a detailed guide to what I was able to do to successfully get the google play music plugin working again (for now) on raspberry pi using max2play (https://www.max2play.com).

    In my setup, the plugin was already installed via the max2play interface and with all libraries and working through the max2play interface.

    As others have pointed out, there is an updated version of the Google Play Music plugin by hubbouma (https://github.com/huubbouma/squeezebox-googlemusic). It uses an updated login method. I also includes a python-based proxy server that somehow solves issues with tracks stopping/ending.

    * Following the directions for the plugin, I updated the GoogleMusicApi library
    First I checked the version installed:
    `sudo pip show gmusicapi`
    Then I updated to 12.1.0 specifically
    `sudo pip2 install gmusicapi==12.1.0`

    (Note I had all other libraries and dependencies already installed thanks to the max2play installer script...so this was the only update I performed)

    * I cloned the updated plugin into /var/lib/squeezeboxserver/Plugins/:
    `cd /var/lib/squeezeboxserver/Plugins/
    sudo git clone https://github.com/huubbouma/squeezebox-googlemusic</blockquote>`

    (I think the better way would be to add this as a 3-rd party plugin, but in the max2play setup the google-play-music plugin is already installed and adding a new repo did not seem to work... so I just cloned it directly and used the github clone to replace the previous plugin)

    * I then swapped out the new plugin directory with the old one and made it a public directory (just in case):
    `sudo mv GoogleMusic GoogleMusic-old
    sudo mv squeezebox-googlemusic GoogleMusic
    sudo chmod 777 GoogleMusic`


    * Then I re-started squeezebox server, made sure the plugin was enabled, and went through the settings to authorize login with OpenAuth. At this point, I could reload my library, but songs wouldn't start.

    * The next step was to enable to python-based proxy server. You can do this temporarily with:
    `sudo python /var/lib/squeezeboxserver/Plugins/GoogleMusic/proxy/proxy.py`

    And viola - I could use the plugin again. However, when I closed the terminal the python-based proxy server stopped and tracks again wouldn't load.

    * So the last step I did was to setup the python-based proxy server as a service. I followed this tutorial https://tecadmin.net/setup-autorun-p...using-systemd/.
    ** First, I made a file called myproxy.system in /lib/systemd/system
    `sudo pico /lib/systemd/system/myproxy.service`

    With these contents:
    `[Unit]
    Description=Dummy Service
    After=multi-user.target
    Conflicts=getty@tty1.service

    [Service]
    Type=simple
    ExecStart=/usr/bin/python /var/lib/squeezeboxserver/Plugins/GoogleMusic/proxy/proxy.py
    StandardInput=tty-force

    [Install]
    WantedBy=multi-user.target`


    ** And then I reloaded systemd, enabled the new service, and started it:
    `sudo systemctl daemon-reload
    sudo systemctl enable myproxy.service
    sudo systemctl start myproxy.service`


    and checked the status with:
    `sudo systemctl status myproxy.service`

    The first time I did this the service was in a failed state. It turned out I had accidentally left an instance of the proxy server running from the command line so the service-based version couldn't attach to the same port and failed. I killed the previous python thread and the service was able to start properly.


    This seems to have done the trick. Don't know yet it it will be super-stable, but fingers crossed. Haven't tested this yet with having multiple players within the house playing different GPM tracks.

  10. #110
    Junior Member
    Join Date
    Dec 2018
    Posts
    2
    I pretty much gave up on the GMusic plugin in 2018. Version 0.6 worked temporarily, but 0.7.1 is still broken. I am running the latest LMS on Max2Play Debian. Looks like it doesn't want to compile, so it's possible some of the plugin code is faulty. I followed all the steps posted here and in the README.md from the distro several times. This is what I get consistently:

    [20-02-23 20:00:17.4251] main::init (387) Starting Logitech Media Server (v7.9.3, 1580910396, Thu Feb 6 04:14:58 CET 2020) perl 5.024001 - arm-linux-gnueabihf-thread-multi-64int
    [20-02-23 20:00:18.8487] Slim::bootstrap::tryModuleLoad (285) Warning: Module [Plugins::GoogleMusic::Plugin] failed to load:
    Error -- py_eval raised an exception at /usr/local/lib/arm-linux-gnueabihf/perl/5.24.1/Inline/Python.pm line 177.
    BEGIN failed--compilation aborted at /usr/share/squeezeboxserver/Plugins/GoogleMusic/GoogleAPI.pm line 74.
    Compilation failed in require at /usr/share/squeezeboxserver/Plugins/GoogleMusic/Settings.pm line 20.
    BEGIN failed--compilation aborted at /usr/share/squeezeboxserver/Plugins/GoogleMusic/Settings.pm line 20.
    Compilation failed in require at /usr/share/squeezeboxserver/Plugins/GoogleMusic/Plugin.pm line 24.
    BEGIN failed--compilation aborted at /usr/share/squeezeboxserver/Plugins/GoogleMusic/Plugin.pm line 24.
    Compilation failed in require at (eval 892) line 1.
    BEGIN failed--compilation aborted at (eval 892) line 1.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •