Kodi Community Forum

Full Version: Launching Android application from inside Kodi
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
This worked in version 18.9 but I cannot make it work in version 19.3.
I have a script, that I'm installing under addons script.program.Windscribe
The default.py is launching but nothing happens, it suppose to open windscribe vpn from inside kodi
the default.py is ( I added log)

python:
import xbmc
import xbmcgui
import os

appname="Windscribe"
packagename="com.windscribe.vpn"


def launcher():
    packagepath = os.popen('pm path %s' % packagename).read()
    xbmc.log('windscribe package path is %s' % packagepath, level=xbmc.LOGERROR)
    if packagepath:
        xbmc.log('windscribe inside package path %s' % packagepath, level=xbmc.LOGERROR)
        xbmc.executebuiltin('XBMC.StartAndroidActivity("%s")' % packagename)
    else:
        xbmcgui.Dialog().ok('App Not Installed', 'This is only a shortcut.  Please install the "%s" app (%s) and try again.' % (appname, packagename))

launcher()

in the log I get
windscribe inside package path package:/data/app/com.windscribe.vpn-KJFIo5_HMN4VVPRUzuQBjw==/base.apk

but it doesn't launch windscribe, any help will be appreciated.
I want to do the same for netflix and hulu
Your previous post is almost some 5 years ago, since then there have been a couple of forum rules added or changed, including the VPN policy (wiki).

I suggest you fully read it, and then you'll perhaps understand why we are not really enthusiastic about your script. It may not be the VPN tool itself, but in our opinion it will indirectly encourage the use of VPNs with Kodi. And that is not we have in mind as per our policy.
After more consideration between moderators, this thread will be closed as per the VPN rules (wiki).