SyntaxErrors off the bat from a pip install

#1

I’m excited to get started with Beets, but I’m running an issue right off the bat after installing it. I’m running Ubuntu Server 18.04 bionic with pip and python packages installed. I used pip install beets (both as a standard user and as superuser for troubleshooting) which seemed to go well enough, but running beets or any variation with options results in a crash:

> beet

Traceback (most recent call last):
  File "/usr/local/bin/beet", line 7, in <module>
    from beets.ui import main
  File "/usr/local/lib/python2.7/dist-packages/beets/ui/__init__.py", line 42, in <module>
    from beets.autotag import mb
  File "/usr/local/lib/python2.7/dist-packages/beets/autotag/__init__.py", line 26, in <module>
    from .match import tag_item, tag_album, Proposal  # noqa
  File "/usr/local/lib/python2.7/dist-packages/beets/autotag/match.py", line 24, in <module>
    from munkres import Munkres
  File "/usr/local/lib/python2.7/dist-packages/munkres.py", line 79
    def pad_matrix(self, matrix: Matrix, pad_value: int=0) -> Matrix:
                               ^
SyntaxError: invalid syntax

This is after virtually no post-install configuration - I’m just running the command directly after installation. Can anyone offer any insight on this problem?

0 Likes

#2

This issue (and the ones I linked to there) are about this problem:

1 Like

#3

Thank you for linking that, I can’t believe none of this showed up while I was searching… Much appreciated!

Edit: I apologize if this is obvious, but regarding the ticket, how do I make beets use Python 3 when I’m running it from command line?

0 Likes

#4

You’ll want to install it using Python 3, i.e., make sure that pip is a Python 3 program (or use pip3 if that’s available) before you pip install beets.

1 Like

#5

That was the ticket, thank you again Adrian!

0 Likes