Going forward just put
sudo in front of your pip commands:
apt-get and pip are similar tools however pip is limited to installing
python packages only but has the advantage it will always install the latest version of a certain module. If you use apt-get you will get the version that is shipped with your current OS release. As you can see that almost always means you get an outdated version.
What we did was:
remove pip and requests installed via apt-get
Code: Select all
sudo apt-get -y --purge remove python-pip python-requests
cleanup by uninstalling other modules which were installed to make the above two work (but are now no longer needed)
Install pip from source so we avoid the auto install of python-requests 2.4.3 when installing python-pip
Code: Select all
curl -O https://bootstrap.pypa.io/get-pip.py
Do a complete reinstall of gigasetelements-cli so we are 100% sure all dependencies are installed.
Code: Select all
sudo pip install --upgrade --force-reinstall https://github.com/dynasticorpheus/gigasetelements-cli/zipball/develop
Please read the my opening post of this thread as I have updated my instruction and made hopefully more clear, needless to say you can skip step 6 which shows how to install the gigasetelements-cli
Don't forget step 5 !!!
micbou wrote:BEER! (right?)
would you mind explaning what we did here? (and why pip freeze doesnt work anymore now)
(and trust me, I look way more stupid

)
Now lets see if I can get the utility and switches working
Code: Select all
root@raspberrypi:/home/pi# sudo apt-get -y --purge remove python-pip python-requests
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
python-chardet python-colorama python-distlib python-html5lib
python-ndg-httpsclient python-openssl python-pyasn1 python-six
python-urllib3 python-wheel
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
python-pip* python-requests*
0 upgraded, 0 newly installed, 2 to remove and 55 not upgraded.
After this operation, 977 kB disk space will be freed.
(Reading database ... 58048 files and directories currently installed.)
Removing python-pip (1.5.6-5) ...
Removing python-requests (2.4.3-6) ...
Processing triggers for man-db (2.7.0.2-5) ...
Code: Select all
root@raspberrypi:/home/pi# sudo apt-get -y autoremove
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
python-chardet python-colorama python-distlib python-html5lib
python-ndg-httpsclient python-openssl python-pyasn1 python-six
python-urllib3 python-wheel
0 upgraded, 0 newly installed, 10 to remove and 55 not upgraded.
After this operation, 3,107 kB disk space will be freed.
(Reading database ... 57942 files and directories currently installed.)
Removing python-chardet (2.3.0-1) ...
Removing python-colorama (0.3.2-1) ...
Removing python-distlib (0.1.9-1) ...
Removing python-html5lib (0.999-3) ...
Removing python-ndg-httpsclient (0.3.2-1) ...
Removing python-openssl (0.13.1-2) ...
Removing python-pyasn1 (0.1.7-1) ...
Removing python-urllib3 (1.9.1-3) ...
Removing python-six (1.8.0-1) ...
Removing python-wheel (0.24.0-1) ...
Processing triggers for man-db (2.7.0.2-5) ...
Processing triggers for python-support (1.0.15) ...
root@raspberrypi:/home/pi# curl -O https://bootstrap.pypa.io/get-pip.py
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 1487k 100 1487k 0 0 4442k 0 --:--:-- --:--:-- --:--:-- 4452k
root@raspberrypi:/home/pi# sudo python get-pip.py
Collecting pip
Downloading pip-8.1.1-py2.py3-none-any.whl (1.2MB)
100% |████████████████████████████████| 1.2MB 203kB/s
Collecting wheel
Downloading wheel-0.29.0-py2.py3-none-any.whl (66kB)
100% |████████████████████████████████| 71kB 1.2MB/s
Installing collected packages: pip, wheel
Successfully installed pip-8.1.1 wheel-0.29.0
Code: Select all
root@raspberrypi:/home/pi# sudo pip install --upgrade --force-reinstall https://github.com/dynasticorpheus/gigasetelements-cli/zipball/develop
Collecting https://github.com/dynasticorpheus/gigasetelements-cli/zipball/develop
Downloading https://github.com/dynasticorpheus/gigasetelements-cli/zipball/develop
| 30kB 214kB/s
Collecting requests (from gigasetelements-cli==1.5.0b1)
Downloading requests-2.10.0-py2.py3-none-any.whl (506kB)
100% |████████████████████████████████| 512kB 454kB/s
Collecting pushbullet.py (from gigasetelements-cli==1.5.0b1)
Downloading pushbullet.py-0.10.0-py2.py3-none-any.whl
Collecting unidecode (from gigasetelements-cli==1.5.0b1)
Downloading Unidecode-0.04.19.tar.gz (204kB)
100% |████████████████████████████████| 204kB 304kB/s
Collecting colorama (from gigasetelements-cli==1.5.0b1)
Downloading colorama-0.3.7-py2.py3-none-any.whl
Collecting python-crontab (from gigasetelements-cli==1.5.0b1)
Downloading python-crontab-2.0.1.tar.gz
Collecting daemonize (from gigasetelements-cli==1.5.0b1)
Downloading daemonize-2.4.6-py2.py3-none-any.whl
Collecting python-magic (from pushbullet.py->gigasetelements-cli==1.5.0b1)
Downloading python-magic-0.4.11.tar.gz
Collecting websocket-client (from pushbullet.py->gigasetelements-cli==1.5.0b1)
Downloading websocket_client-0.37.0.tar.gz (194kB)
100% |████████████████████████████████| 194kB 631kB/s
Collecting python-dateutil (from python-crontab->gigasetelements-cli==1.5.0b1)
Downloading python_dateutil-2.5.3-py2.py3-none-any.whl (201kB)
100% |████████████████████████████████| 204kB 737kB/s
Collecting six (from websocket-client->pushbullet.py->gigasetelements-cli==1.5.0b1)
Downloading six-1.10.0-py2.py3-none-any.whl
Building wheels for collected packages: unidecode, python-crontab, python-magic, websocket-client
Running setup.py bdist_wheel for unidecode ... done
Stored in directory: /root/.cache/pip/wheels/72/da/8f/64e7de75111e143339d331011b56b3a8186e2eb07b0b5e383b
Running setup.py bdist_wheel for python-crontab ... done
Stored in directory: /root/.cache/pip/wheels/64/8d/fb/bb281503710d9de2d193a378c7e9b5d0cdb8367aec3587f1ed
Running setup.py bdist_wheel for python-magic ... done
Stored in directory: /root/.cache/pip/wheels/65/ab/71/40c6c38a050ce64fcbda7e3e8ee3096d5a6302ad4dab28ba8c
Running setup.py bdist_wheel for websocket-client ... done
Stored in directory: /root/.cache/pip/wheels/e4/20/12/48d6732b88733a0a8f98ee1a5b2f59b64b27011d5c34c4f98c
Successfully built unidecode python-crontab python-magic websocket-client
Installing collected packages: requests, python-magic, six, websocket-client, pushbullet.py, unidecode, colorama, python-dateutil, python-crontab, daemonize, gigasetelements-cli
Found existing installation: requests 2.10.0
Uninstalling requests-2.10.0:
Successfully uninstalled requests-2.10.0
Found existing installation: python-magic 0.4.11
Uninstalling python-magic-0.4.11:
Successfully uninstalled python-magic-0.4.11
Found existing installation: six 1.10.0
Uninstalling six-1.10.0:
Successfully uninstalled six-1.10.0
Found existing installation: websocket-client 0.37.0
Uninstalling websocket-client-0.37.0:
Successfully uninstalled websocket-client-0.37.0
Found existing installation: pushbullet.py 0.10.0
Uninstalling pushbullet.py-0.10.0:
Successfully uninstalled pushbullet.py-0.10.0
Found existing installation: Unidecode 0.4.19
Uninstalling Unidecode-0.4.19:
Successfully uninstalled Unidecode-0.4.19
Found existing installation: colorama 0.3.7
Uninstalling colorama-0.3.7:
Successfully uninstalled colorama-0.3.7
Found existing installation: python-dateutil 2.5.3
Uninstalling python-dateutil-2.5.3:
Successfully uninstalled python-dateutil-2.5.3
Found existing installation: python-crontab 2.0.1
Uninstalling python-crontab-2.0.1:
Successfully uninstalled python-crontab-2.0.1
Found existing installation: daemonize 2.4.6
Uninstalling daemonize-2.4.6:
Successfully uninstalled daemonize-2.4.6
Found existing installation: gigasetelements-cli 1.5.0b1
Uninstalling gigasetelements-cli-1.5.0b1:
Successfully uninstalled gigasetelements-cli-1.5.0b1
Running setup.py install for gigasetelements-cli ... done
Successfully installed colorama-0.3.7 daemonize-2.4.6 gigasetelements-cli-1.5.0b1 pushbullet.py-0.10.0 python-crontab-2.0.1 python-dateutil-2.5.3 python-magic-0.4.11 requests-2.10.0 six-1.10.0 unidecode-0.4.19 websocket-client-0.37.0
Code: Select all
root@raspberrypi:/home/pi# pip freeze
bash: /usr/bin/pip: No such file or directory
Code: Select all
root@raspberrypi:/home/pi# gigasetelements-cli -ss
Gigaset Elements - Command-line Interface v1.5.0b1
[-] Configuration | LOADED | /etc/gigasetelements-cli.conf
[-] Identity | VERIFIED | User logged in successfully.
[-] Authentication | SUCCESS |
[-] Basestation | ONLINE | E52C011F30C1BE84C86895D96C76D693
[-] Status | RED | ENDNODE_OFFLINE | Modus set from HOME to HOME
[-] Michel's Thuis | ONLINE | firmware UP_TO_DATE
[-] Achterdeur | OFFLINE | firmware UP_TO_DATE | battery OK | position UNKNOWN | 027C06E864
[-] woonkamer | ONLINE | firmware UP_TO_DATE | battery OK | 027C06E866
root@raspberrypi:/home/pi#