hechtus / squeezebox-googlemusic

Squeezebox (Logitech Media Server) Plugin for Google Play Music
103 stars 24 forks source link

Problems installing on ubuntu server 14.04 #71

Closed phildobson closed 9 years ago

phildobson commented 9 years ago

I'm attempting a fresh install on a new box (ubuntu 14.04) - all is well until I run:

sudo -H pip install git+https://github.com/simon-weber/Unofficial-Google-Music-API.git@develop

which eventually returns:

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-tl7m68jd/protobuf

Any suggestions are gratefully received!

I have another version running without problem on an older 12.04 box, so it's possible.

Thanks for the fantastic plugin.

Phil

Output from command python setup.py egg_info:

/usr/local/lib/python3.4/dist-packages/pkg_resources/__init__.py:2512: PEP440Warning: 'google (apputils-0.2)' is being parsed as a legacy, non PEP 440, version. You may find odd behavior and sort order. In particular it will be sorted as less than 0.0. It is recommend to migrate to PEP 440 compatible versions.

  PEP440Warning,

Repeated 4 times, then:

Traceback (most recent call last):

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 152, in save_modules

    yield saved

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 193, in setup_context

    yield

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 237, in run_setup

    DirectorySandbox(setup_dir).run(runner)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 267, in run

    return func()

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 236, in runner

    _execfile(setup_script, ns)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 46, in _execfile

    exec(code, globals, locals)

  File "/tmp/easy_install-6nh9c3nr/google-apputils-0.4.1/setup.py", line 18, in <module>

    sys.stderr.write

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

  File "<string>", line 20, in <module>

  File "/tmp/pip-build-tl7m68jd/protobuf/setup.py", line 200, in <module>

    "Protocol Buffers are Google's data interchange format.",

  File "/usr/lib/python3.4/distutils/core.py", line 108, in setup

    _setup_distribution = dist = klass(attrs)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/dist.py", line 265, in __init__

    self.fetch_build_eggs(attrs['setup_requires'])

  File "/usr/local/lib/python3.4/dist-packages/setuptools/dist.py", line 310, in fetch_build_eggs

    replace_conflicting=True,

  File "/usr/local/lib/python3.4/dist-packages/pkg_resources/__init__.py", line 799, in resolve

    dist = best[req.key] = env.best_match(req, ws, installer)

  File "/usr/local/lib/python3.4/dist-packages/pkg_resources/__init__.py", line 1049, in best_match

    return self.obtain(req, installer)

  File "/usr/local/lib/python3.4/dist-packages/pkg_resources/__init__.py", line 1061, in obtain

    return installer(requirement)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/dist.py", line 377, in fetch_build_egg

    return cmd.easy_install(req)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/command/easy_install.py", line 623, in easy_install

    return self.install_item(spec, dist.location, tmpdir, deps)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/command/easy_install.py", line 653, in install_item

    dists = self.install_eggs(spec, download, tmpdir)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/command/easy_install.py", line 838, in install_eggs

    return self.build_and_install(setup_script, setup_base)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/command/easy_install.py", line 1066, in build_and_install

    self.run_setup(setup_script, setup_base, args)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/command/easy_install.py", line 1052, in run_setup

    run_setup(setup_script, args)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 240, in run_setup

    raise

  File "/usr/lib/python3.4/contextlib.py", line 77, in __exit__

    self.gen.throw(type, value, traceback)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 193, in setup_context

    yield

  File "/usr/lib/python3.4/contextlib.py", line 77, in __exit__

    self.gen.throw(type, value, traceback)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 164, in save_modules

    saved_exc.resume()

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 139, in resume

    compat.reraise(type, exc, self._tb)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/compat.py", line 65, in reraise

    raise value.with_traceback(tb)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 152, in save_modules

    yield saved

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 193, in setup_context

    yield

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 237, in run_setup

    DirectorySandbox(setup_dir).run(runner)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 267, in run

    return func()

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 236, in runner

    _execfile(setup_script, ns)

  File "/usr/local/lib/python3.4/dist-packages/setuptools/sandbox.py", line 46, in _execfile

    exec(code, globals, locals)

  File "/tmp/easy_install-6nh9c3nr/google-apputils-0.4.1/setup.py", line 18, in <module>

    sys.stderr.write

----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-tl7m68jd/protobuf
phildobson commented 9 years ago

Apologies for answering my own question but I've solved this issue. Turns out that you should use pip2 to install the API in Ubuntu server 14.04.

I had to run the following two lines for step 3 of the installation procedure instead of those described in the README.md:

sudo apt-get install python-pip sudo pip2 install git+https://github.com/simon-weber/Unofficial-Google-Music-API.git@develop

All other steps (1-2 and 4-6) worked as described.

Hopefully this is of some help to other users,

Phil

hechtus commented 9 years ago

OK, thanks for letting us know!