Skip to main content

SAKÉ can help you to debug and develop Kodi Python add-ons

Project description

SAKÉ: Simple ASCII Kodi Emulator

License Quality Gate Status Python

alt text

SAKÉ: your favourite 'drink' for debugging and developiong Kodi Python add-ons

SAKÉ can help you to debug and develop Kodi Python add-ons. It contains a set of libraries that try to mimic the functionality of the corresponding Kodi modules:

Module Purpose
xbmc General functions on Kodi
xbmcaddon Kodi’s addon class
xbmcgui GUI functions on Kodi.
xbmcplugin Plugin functions on Kodi.

Not all libraries are present and certainly not all methods are implemented. Currently missing are:

Module Purpose
xbmcvfs Virtual file system functions on Kodi.
xbmcdrm Kodi’s DRM class

Feel free to contribute to the completion using Pull Requests for this repository.

Using SAKÉ

In order to use SAKÉ for development Kodi add-ons, you will need to include its path the the Python paths. Eiter via:

sys.path.append('<path to SAKÉ>')

Or by appending the SAKÉ path to the Python path environment variable: PYTHONPATH

Configuration

SAKÉ requires you to run with your add-on as the main working directory. Running it outside of that directory will fail.

If your add-on is in a subfolder of Kodi's addons folder, you are done. SAKÉ will try to find its own way and determine what your Kodi path is and where your profile is stored. However, if you are running it standalone, so without Kodi at all, or if SAKÉ got 'drunk' and lost its way, you can always specify some directions using environment variables as follows:

Environment Variable Description
KODI_HOME If specified, will force SAKÉ to look at that path for Kodi's home path.
KODI_PROFILE If specified, will force SAKÉ to use this folder as the Kodi 'master' profile (user_data) folder. This will disable the auto detection of the profile folder based on Kodi's home path.
KODI_ACTIVE_PROFILE SAKÉ will asume that you don't have any Kodi profiles, but in case you have, you can specify what profile to use for the add-on settings.
KODI_INTERACTIVE Normally, SAKÉ will try to interact with you: Whenever there should be a dialog shown within Kodi, SAKÉ will present you with an ASCII version and wait for a response. You can disable this by setting this environment variable to "0". SAKÉ will not disturb you and will continue. However, SAKÉ will answer those dialogs for you and that might result in unwanted actions, but it might come in handy while running unit tests.
KODI_STUB_VERBOSE If set to "1" will make SAKÉ a bit more verbose.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sakee-0.0.1.dev1.tar.gz (16.9 kB view hashes)

Uploaded Source

Built Distribution

sakee-0.0.1.dev1-py3-none-any.whl (32.7 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page