Add Python modules in GC

616 views
Skip to first unread message

Manuel Oberti

unread,
Aug 16, 2021, 7:41:17 AM8/16/21
to golden-cheetah-users
Hi,
is possible to add extra python modules in GC ?
I dont want use python installed but GC python embedded with custom modules for my charts

THANKS

Hwa Runner

unread,
Aug 16, 2021, 8:07:11 AM8/16/21
to golden-cheetah-users
I'm not sure about the official way, but I did install additional modules using the following way (Windows):
1. Make sure the folders 'Scripts' and  'Lib' within the Golden Cheetah installation folder are writable for the current user.
2. Install 'pip'. At least I had to install it. <path>/Golden Cheetah/python.exe get-pip.py
The script get-pip.py is available in the net - search for it.
3. Now you can run <path>/Golden Cheetah/Scripts/pip install <module>

This worked for me but, I suppose there might be more elegant ways, which would be of interest to me as well.
After installing an new version of GC, you might have to process the steps above again.

Ale Martinez

unread,
Aug 18, 2021, 12:04:01 AM8/18/21
to golden-cheetah-users
El lunes, 16 de agosto de 2021 a la(s) 05:07:11 UTC-7, Hwa Runner escribió:
I'm not sure about the official way

Peret

unread,
Nov 5, 2021, 9:08:26 AM11/5/21
to golden-cheetah-users
If I have understood correctly, the official way aims to install additional packages using the OS python installation, and then, to use that OS installation.
I prefer to use GC installation.
I have found a way to install packages in the GC python embedded installation, using binary 'pip' of the OS installation. this is for linux, I cannot say the way for Windows:
1. You must unpackage GoldenCheetah appimage to a directory (say ~/squashfs-root). As explained here: ./GoldenCheetah*.AppImage --appimage-extract
2. Now, use your pip command from your OS python3.7 installation. In my case:
pip3.7 install --prefix=~/squashfs-root/opt/python3.7 <package name>

So, I have installed the package in the correct place, available for GoldenCheetah.
As Ale says, this is not the official way, so, consider this disclaimer: this is a choice with no garantee

Ale Martinez

unread,
Nov 5, 2021, 9:59:46 AM11/5/21
to golden-cheetah-users
El viernes, 5 de noviembre de 2021 a la(s) 10:08:26 UTC-3, Peret escribió:
If I have understood correctly, the official way aims to install additional packages using the OS python installation, and then, to use that OS installation.
I prefer to use GC installation.
I have found a way to install packages in the GC python embedded installation, using binary 'pip' of the OS installation. this is for linux, I cannot say the way for Windows:
1. You must unpackage GoldenCheetah appimage to a directory (say ~/squashfs-root). As explained here: ./GoldenCheetah*.AppImage --appimage-extract
2. Now, use your pip command from your OS python3.7 installation. In my case:
pip3.7 install --prefix=~/squashfs-root/opt/python3.7 <package name>

So, I have installed the package in the correct place, available for GoldenCheetah.
As Ale says, this is not the official way, so, consider this disclaimer: this is a choice with no garantee

This is reasonable for users who understand what they are doing, in fact, once you extract the AppImage you don't need to have installed the same version in your system to install packages since we are including the full usr and opt folders from https://github.com/niess/python-appimage 
Reply all
Reply to author
Forward
Message has been deleted
0 new messages