-
-
Notifications
You must be signed in to change notification settings - Fork 173
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] Error while starting with last update on RaspberryPi #221
Comments
You have a few options:
|
P.S.: This is not a bug. Installing the AppIndicator libraries on Linux is now "required" (unless you apply the second or third workaround I mentioned in my previous post), because after the addition of And because the Linux binary we are distributing through the CI (AMD64 only, unfortunately) already includes everything, it didn't cross my mind to mention this in the README, but we probably should. |
What makes me think it's a bug is that it's not written in the README / wiki ;) Lines 46 to 53 in 3fa9568
But yep, I should migrate my RaspberryPi to 64bit too 😄 |
I did try but still not working :( tdm.sh#!/bin/bash
apt_install() {
sudo apt-get install -y libappindicator3-1
}
exe() {
cd "$HOME/Downloads/TwitchDropsMiner/" || exit
# Create .exe
pip install pyinstaller
pyinstaller build.spec
}
run() {
cd "$HOME/Downloads/TwitchDropsMiner/" || exit
source ./env/bin/activate
python main.py --log
}
update() {
cd "$HOME/Downloads/TwitchDropsMiner/" || exit
# Update
git pull --ff-only
# Update requirements
source ./env/bin/activate
pip install -r requirements.txt
}
show_help() {
Color_Off="\033[0m" # Text Reset
IYellow="\033[0;93m" # Yellow
ICyan="\033[0;96m" # Cyan
echo -e "${Color_Off}USAGE: ${IYellow}tdm.sh ${ICyan}[OPTIONS]${Color_Off}"
echo
echo -e "OPTIONS"
echo -e " ${ICyan}-a${Color_Off}"
echo -e " Install apt packages for Linux."
echo -e " ${ICyan}-e${Color_Off}"
echo -e " Compile exe for Windows."
echo -e " ${ICyan}-h${Color_Off}"
echo -e " Show help."
echo -e " ${ICyan}-r${Color_Off}"
echo -e " Run from sources."
echo -e " ${ICyan}-u${Color_Off}"
echo -e " Update sources & pip packages."
}
if [ -z "$1" ]; then
run
exit 0
fi
while getopts ":aehru" opt; do
case $opt in
a)
apt_install
;;
e)
exe
;;
h)
show_help
;;
r)
run
;;
u)
update
;;
\?)
echo "$OPTARG : Invalid option"
exit 1
;;
esac
done
exit 0
pi@raspberrypi:~/Documents $ sudo apt-get install -y libappindicator3-1
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
libappindicator3-1 is already the newest version (0.4.92-8).
The following packages were automatically installed and are no longer required:
golang-1.15 golang-1.15-doc golang-1.15-go golang-1.15-src golang-doc golang-go golang-src
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
pi@raspberrypi:~/Documents $ ./tdm.sh -r
Traceback (most recent call last):
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/pystray/_appindicator.py", line 23, in <module>
gi.require_version('AppIndicator3', '0.1')
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/gi/__init__.py", line 126, in require_version
raise ValueError('Namespace %s not available' % namespace)
ValueError: Namespace AppIndicator3 not available
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/pi/Downloads/TwitchDropsMiner/main.py", line 29, in <module>
from twitch import Twitch
File "/home/pi/Downloads/TwitchDropsMiner/twitch.py", line 39, in <module>
from gui import GUIManager
File "/home/pi/Downloads/TwitchDropsMiner/gui.py", line 21, in <module>
import pystray
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/pystray/__init__.py", line 64, in <module>
Icon = backend().Icon
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/pystray/__init__.py", line 56, in backend
return candidate()
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/pystray/__init__.py", line 28, in appindicator
from . import _appindicator as backend; return backend
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/pystray/_appindicator.py", line 26, in <module>
gi.require_version('AyatanaAppIndicator3', '0.1')
File "/home/pi/Downloads/TwitchDropsMiner/env/lib/python3.9/site-packages/gi/__init__.py", line 126, in require_version
raise ValueError('Namespace %s not available' % namespace)
ValueError: Namespace AyatanaAppIndicator3 not available |
@kevingrillet I had to install these additional packages on Ubuntu to make it work
|
@miroslav-suvada Ty, it works! tdm.sh#!/bin/bash
apt_install() {
# sudo apt-get install -y libgtk-3-dev
# sudo apt-get install -y libappindicator3-1
sudo apt-get install -y gir1.2-appindicator3-0.1 libcairo2-dev libgirepository1.0-dev pkg-config
}
exe() {
cd "$HOME/Downloads/TwitchDropsMiner/" || exit
# Create .exe
pip install pyinstaller
pyinstaller build.spec
}
run() {
cd "$HOME/Downloads/TwitchDropsMiner/" || exit
# PYSTRAY_BACKEND=gtk
source ./env/bin/activate
python main.py --log
}
update() {
cd "$HOME/Downloads/TwitchDropsMiner/" || exit
# Update
git pull --ff-only
# Update requirements
source ./env/bin/activate
pip install -r requirements.txt
}
show_help() {
Color_Off="\033[0m" # Text Reset
IYellow="\033[0;93m" # Yellow
ICyan="\033[0;96m" # Cyan
echo -e "${Color_Off}USAGE: ${IYellow}tdm.sh ${ICyan}[OPTIONS]${Color_Off}"
echo
echo -e "OPTIONS"
echo -e " ${ICyan}-a${Color_Off}"
echo -e " Install apt packages for Linux."
echo -e " ${ICyan}-e${Color_Off}"
echo -e " Compile exe for Windows."
echo -e " ${ICyan}-h${Color_Off}"
echo -e " Show help."
echo -e " ${ICyan}-r${Color_Off}"
echo -e " Run from sources."
echo -e " ${ICyan}-u${Color_Off}"
echo -e " Update sources & pip packages."
}
if [ -z "$1" ]; then
run
exit 0
fi
while getopts ":aehru" opt; do
case $opt in
a)
apt_install
;;
e)
exe
;;
h)
show_help
;;
r)
run
;;
u)
update
;;
\?)
echo "$OPTARG : Invalid option"
exit 1
;;
esac
done
exit 0
pi@raspberrypi:~/Documents $ ./tdm.sh -aur
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
gir1.2-appindicator3-0.1 is already the newest version (0.4.92-8).
libgirepository1.0-dev is already the newest version (1.66.1-1+b1).
pkg-config is already the newest version (0.29.2-1).
libcairo2-dev is already the newest version (1.16.0-5+rpt1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Already up to date.
Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple
Collecting pystray@ git+https://github.com/moses-palmer/pystray.git@903836104f8b1a2979f4fa5a333870ef7b075992
Cloning https://github.com/moses-palmer/pystray.git (to revision 903836104f8b1a2979f4fa5a333870ef7b075992) to /tmp/pip-install-xg1_wrl9/pystray_333945fa934f4da78ebd5921076bbc34
Running command git clone -q https://github.com/moses-palmer/pystray.git /tmp/pip-install-xg1_wrl9/pystray_333945fa934f4da78ebd5921076bbc34
Running command git rev-parse -q --verify 'sha^903836104f8b1a2979f4fa5a333870ef7b075992'
Running command git fetch -q https://github.com/moses-palmer/pystray.git 903836104f8b1a2979f4fa5a333870ef7b075992
Ignoring pywin32: markers 'sys_platform == "win32"' don't match your environment
Ignoring truststore: markers 'sys_platform == "linux" and python_version >= "3.10"' don't match your environment
Requirement already satisfied: aiohttp<4.0,>2.0 in ./env/lib/python3.9/site-packages (from -r requirements.txt (line 1)) (3.8.4)
Requirement already satisfied: Pillow in ./env/lib/python3.9/site-packages (from -r requirements.txt (line 2)) (9.4.0)
Requirement already satisfied: PyGObject in ./env/lib/python3.9/site-packages (from -r requirements.txt (line 5)) (3.44.1)
Requirement already satisfied: six in ./env/lib/python3.9/site-packages (from pystray@ git+https://github.com/moses-palmer/pystray.git@903836104f8b1a2979f4fa5a333870ef7b075992->-r requirements.txt (line 4)) (1.16.0)
Requirement already satisfied: python-xlib>=0.17 in ./env/lib/python3.9/site-packages (from pystray@ git+https://github.com/moses-palmer/pystray.git@903836104f8b1a2979f4fa5a333870ef7b075992->-r requirements.txt (line 4)) (0.33)
Requirement already satisfied: frozenlist>=1.1.1 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (1.3.3)
Requirement already satisfied: yarl<2.0,>=1.0 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (1.8.2)
Requirement already satisfied: charset-normalizer<4.0,>=2.0 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (3.1.0)
Requirement already satisfied: aiosignal>=1.1.2 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (1.3.1)
Requirement already satisfied: multidict<7.0,>=4.5 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (6.0.4)
Requirement already satisfied: attrs>=17.3.0 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (22.2.0)
Requirement already satisfied: async-timeout<5.0,>=4.0.0a3 in ./env/lib/python3.9/site-packages (from aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (4.0.2)
Requirement already satisfied: idna>=2.0 in ./env/lib/python3.9/site-packages (from yarl<2.0,>=1.0->aiohttp<4.0,>2.0->-r requirements.txt (line 1)) (3.4)
Requirement already satisfied: pycairo>=1.16.0 in ./env/lib/python3.9/site-packages (from PyGObject->-r requirements.txt (line 5)) (1.23.0)
|
@DevilXD thanks for this great tool! I don't like running my desktop 24/7 so installed this on a Pi. Running DietPi from a 4 GB SD card on a Raspberry Pi rev2 B. Below are the upgraded scripts, also added this comment's code. Would like to have this in one session with two windows. Since everything is now in tmux you have to run tmux-tdm.sh``` tmux new-session -d -s Xvfb tmux send-keys -t Xvfb 'Xvfb :99 -screen 0 1x2x8' Enter tmux new-session -d -s tdm tmux send-keys -t tdm 'cd ~/TwitchDropsMiner;source ./env/bin/activate;export DISPLAY=:99;./env/bin/python main.py --log' Enter ``` tdm.sh``` #!/bin/bash apt_install() { exe() {
} run() { update() {
} show_help() {
} if [ -z "$1" ]; then while getopts ":aehru" opt; do
|
I was having the same problem on my raspberry pi 4b with 'AppIndicator3 not available', but for some reason 'apt-get install gir1.2-appindicator3-0' was not able to find the package, from what I see online gir1.2 is outdated. I was able to circumvent the issue by building from source and running in a venv following this guide. Now I get the same issue when starting with |
Hi, sorry to resurrect like this, are you still somehow active in raspi TDM? I tried script from your comment with new TDM by Win20k (which fixed drop change done by twitch) https://github.com/Windows200000/TwitchDropsMiner-updated/releases, but without success. I would really like to run this on raspi and not keeping my main pc up. If you could look into it and do little walkthru on how to do it properly, it will be epic. Thanks |
I've just pull the last update of the project, then updated the packages & run, but it's not working :/
Hardware
Running on Raspbian 32 bits, up to date.
Update
Output:
Run
Output
The text was updated successfully, but these errors were encountered: