mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-15 09:42:57 -07:00
Add python version to Google Analytics
This commit is contained in:
parent
a116c26c25
commit
416d869288
3 changed files with 4 additions and 3 deletions
|
@ -37,8 +37,7 @@ from apscheduler.triggers.interval import IntervalTrigger
|
||||||
from UniversalAnalytics import Tracker
|
from UniversalAnalytics import Tracker
|
||||||
import pytz
|
import pytz
|
||||||
|
|
||||||
PYTHON_VERSION = sys.version_info[:3]
|
PYTHON2 = sys.version_info[0] == 2
|
||||||
PYTHON2 = PYTHON_VERSION[0] == 2
|
|
||||||
|
|
||||||
if PYTHON2:
|
if PYTHON2:
|
||||||
import activity_handler
|
import activity_handler
|
||||||
|
@ -2264,6 +2263,7 @@ def initialize_tracker():
|
||||||
'appInstallerId': CONFIG.GIT_BRANCH,
|
'appInstallerId': CONFIG.GIT_BRANCH,
|
||||||
'dimension1': '{} {}'.format(common.PLATFORM, common.PLATFORM_RELEASE), # App Platform
|
'dimension1': '{} {}'.format(common.PLATFORM, common.PLATFORM_RELEASE), # App Platform
|
||||||
'dimension2': common.PLATFORM_LINUX_DISTRO, # Linux Distro
|
'dimension2': common.PLATFORM_LINUX_DISTRO, # Linux Distro
|
||||||
|
'dimension3': common.PYTHON_VERSION,
|
||||||
'userLanguage': SYS_LANGUAGE,
|
'userLanguage': SYS_LANGUAGE,
|
||||||
'documentEncoding': SYS_ENCODING,
|
'documentEncoding': SYS_ENCODING,
|
||||||
'noninteractive': True
|
'noninteractive': True
|
||||||
|
|
|
@ -35,6 +35,7 @@ PLATFORM_RELEASE = platform.release()
|
||||||
PLATFORM_VERSION = platform.version()
|
PLATFORM_VERSION = platform.version()
|
||||||
PLATFORM_LINUX_DISTRO = ' '.join(x for x in distro.linux_distribution() if x)
|
PLATFORM_LINUX_DISTRO = ' '.join(x for x in distro.linux_distribution() if x)
|
||||||
PLATFORM_DEVICE_NAME = platform.node()
|
PLATFORM_DEVICE_NAME = platform.node()
|
||||||
|
PYTHON_VERSION = platform.python_version()
|
||||||
BRANCH = version.PLEXPY_BRANCH
|
BRANCH = version.PLEXPY_BRANCH
|
||||||
RELEASE = version.PLEXPY_RELEASE_VERSION
|
RELEASE = version.PLEXPY_RELEASE_VERSION
|
||||||
|
|
||||||
|
|
|
@ -3007,7 +3007,7 @@ class SCRIPTS(Notifier):
|
||||||
'TAUTULLI_PUBLIC_URL': plexpy.CONFIG.HTTP_BASE_URL + plexpy.HTTP_ROOT,
|
'TAUTULLI_PUBLIC_URL': plexpy.CONFIG.HTTP_BASE_URL + plexpy.HTTP_ROOT,
|
||||||
'TAUTULLI_APIKEY': plexpy.CONFIG.API_KEY,
|
'TAUTULLI_APIKEY': plexpy.CONFIG.API_KEY,
|
||||||
'TAUTULLI_ENCODING': plexpy.SYS_ENCODING,
|
'TAUTULLI_ENCODING': plexpy.SYS_ENCODING,
|
||||||
'TAUTULLI_PYTHON_VERSION': '.'.join(map(str, plexpy.PYTHON_VERSION))
|
'TAUTULLI_PYTHON_VERSION': common.PYTHON_VERSION
|
||||||
}
|
}
|
||||||
|
|
||||||
if user_id:
|
if user_id:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue