Closed AuthFailed closed 3 years ago
Hey @AuthFailed
Super strange, it seems to have found the package and installed what was necessary but it can't find the entry point. Any chance you just need to run source ~/.zshrc
or open up a new terminal to find the new executable?
@conor-f
I tried again run spotibar
command, but nothing new. source ~/.zshrc
doesnt help too.
if you run python3
and then import spotibar
does it import correctly or does it get a module not found error?
if you run
python3
and thenimport spotibar
does it import correctly or does it get a module not found error?
Imported correctly.
Thanks @AuthFailed, I'll get this sorted this evening. Must be an issue with the setup.py
and how it sets up the console script. Will get back to you shortly!
Hey @AuthFailed this is super weird. I tried replicating this as closely as possible:
conor@Conor:~ $ python3.9 -m pip uninstall spotibar
Found existing installation: spotibar 0.2.0
Uninstalling spotibar-0.2.0:
Would remove:
/home/conor/.local/bin/spotibar
/home/conor/.local/lib/python3.9/site-packages/spotibar-0.2.0.dist-info/*
/home/conor/.local/lib/python3.9/site-packages/spotibar/*
Proceed (y/n)? y
Successfully uninstalled spotibar-0.2.0
conor@Conor:~ $ spotibar --help
zsh: command not found: spotibar
conor@Conor:~ $ python3.9 -m pip install spotibar
Looking in indexes: https://pypi.org/simple, https://conor:****@pip.******.com, https://pypi.python.org/simple
/usr/share/python-wheels/urllib3-1.25.8-py2.py3-none-any.whl/urllib3/connectionpool.py:999: InsecureRequestWarning: Unverified HTTPS request is being made to host 'pip.******.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
/usr/share/python-wheels/urllib3-1.25.8-py2.py3-none-any.whl/urllib3/connectionpool.py:999: InsecureRequestWarning: Unverified HTTPS request is being made to host 'pip.******.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
Processing ./.cache/pip/wheels/42/82/d5/22f9a8b8c3390d44e89a6f80cfe4ca6099626b0925e7d77da6/spotibar-0.2.0-py3-none-any.whl
Requirement already satisfied: pylast in ./.local/lib/python3.9/site-packages (from spotibar) (4.2.0)
Requirement already satisfied: spotipy in ./.local/lib/python3.9/site-packages (from spotibar) (2.17.1)
Requirement already satisfied: requests>=2.25.0 in ./.local/lib/python3.9/site-packages (from spotipy->spotibar) (2.25.1)
Requirement already satisfied: urllib3>=1.26.0 in ./.local/lib/python3.9/site-packages (from spotipy->spotibar) (1.26.4)
Requirement already satisfied: six>=1.15.0 in ./.local/lib/python3.9/site-packages (from spotipy->spotibar) (1.15.0)
Requirement already satisfied: certifi>=2017.4.17 in /usr/lib/python3/dist-packages (from requests>=2.25.0->spotipy->spotibar) (2019.11.28)
Requirement already satisfied: idna<3,>=2.5 in /usr/lib/python3/dist-packages (from requests>=2.25.0->spotipy->spotibar) (2.8)
Requirement already satisfied: chardet<5,>=3.0.2 in /usr/lib/python3/dist-packages (from requests>=2.25.0->spotipy->spotibar) (3.0.4)
Installing collected packages: spotibar
Successfully installed spotibar-0.2.0
conor@Conor:~ $ spotibar --help
usage: spotibar [-h]
[--get-currently-playing | --previous-track | --next-track | --toggle-playback | --add-track-to-monthly-playlist | --auth | --config-popup | --init]
Entrypoint for Spotify/Polybar integration.
optional arguments:
-h, --help show this help message and exit
--get-currently-playing
--previous-track
--next-track
--toggle-playback
--add-track-to-monthly-playlist
--auth
--config-popup
--init
tried with and without pip caching enabled, etc etc. Only difference I notice in pip output is that yours doesn't specify "building wheels for collected packages: spotibar..." towards the end of the output. I really don't have much idea of what to do apart from either trying an older version of pip (e.g. python3.8 -m pip install spotibar), trying with sudo
or uninstalling and reinstalling!
I just removed spotibar package and then run installation command with sudo:
Maybe problem in this line? Defaulting to user installation because normal site-packages is not writeable
I think I got the problem:
WARNING: The script spotibar is installed in '/home/authfailed/.local/bin' which is not on PATH. Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
I don't know why, I don't know how. I only understood it because of this
Well that should be a pretty simple fix - adding /home/authfailed/.local/bin
to your PATH
by adding export PATH=$PATH:/home/authfailed/.local/bin
in your .zshrc
?
Well that should be a pretty simple fix - adding
/home/authfailed/.local/bin
to yourPATH
by addingexport PATH=$PATH:/home/authfailed/.local/bin
in your.zshrc
?
Yep, already fixed. BUT! There are new error from this
Sorry I don't see what the new error is? :)
Sorry I don't see what the new error is? :)
ImportError: libtk8.6.so: cannot open shared object file: No such file or directory
I solved this problem by using pacman -S tk
Oh, shit, I've already added bin to PATH
`
ls -l /bin/sh
said that /bin/sh -> bash
I logon in /bin/sh and tried to run spotibar
and got no errors.
Could be because of how you start your polybar? Mine is started via a shell script loaded from my i3 config which has the shebang line of #!/bin/bash
You was right
My firstline in shell polybar scipt was #!/usr/bin/env bash
. Now everything works correctly. But I did not find information in the readme that I was supposed to add http://127.0.0.1
as a REDIRECT URI in Spotify
Steps to reproduce:
python3 -m pip install spotibar
spotibar --auth
Error I got:
command not found: Spotibar
I'm already tried to rerun first command, got this:![python3 -m pip install spotibar](https://user-images.githubusercontent.com/21986465/111133487-2c0fc700-85ad-11eb-972c-e0f2ae3b0672.png)