<commit_before>from enigma import * #, quitMainloop
from Components.ServiceEventTracker import ServiceEventTracker
from Tools.Directories import fileExists
from crossepglib import *
from crossepg_downloader import CrossEPG_Downloader
from crossepg_converter import CrossEPG_Converter
from crossepg_loader import CrossEPG_Loader
from crossepg_importer import CrossEPG_Importer
from crossepg_locale import _
from Screens.Screen import Screen

from time import *

import os

class CrossEPG_Auto(Screen):
	POLL_TIMER = 1800000	# poll every 30 minutes
	#POLL_TIMER = 18000

	def __init__(self):
		self.session = None

		self.timer = eTimer()
		self.standbyTimer = eTimer()

		self.timer.callback.append(self.poll)
		self.standbyTimer.callback.append(self.backToStandby)

		self.config = CrossEPG_Config()
		self.patchtype = getEPGPatchType()

		self.pdownloader = None
		self.pimporter = None
		self.pconverter = None
		self.ploader = None

		self.osd = False
		self.ontune = False
		self.lock = False

		if fileExists("/tmp/crossepg.standby"):
			os.system("rm -f /tmp/crossepg.standby")
			print "[CrossEPG_Auto] coming back in standby in 30 seconds"
			self.standbyTimer.start(30000, 1)

	def init(self, session):
		self.session = session
		self.timer.start(self.POLL_TIMER, 1)

	def poll(self):
		from Screens.Standby import inStandby<commit_msg>(enigma2) fixed force load on boot<commit_after>from enigma import * #, quitMainloop
from Components.ServiceEventTracker import ServiceEventTracker
from Tools.Directories import fileExists
from crossepglib import *
from crossepg_downloader import CrossEPG_Downloader
from crossepg_converter import CrossEPG_Converter
from crossepg_loader import CrossEPG_Loader
from crossepg_importer import CrossEPG_Importer
from crossepg_locale import _
from Screens.Screen import Screen

from time import *

import os

class CrossEPG_Auto(Screen):
	POLL_TIMER = 1800000	# poll every 30 minutes
	#POLL_TIMER = 18000

	def __init__(self):
		self.session = None

		self.timer = eTimer()
		self.standbyTimer = eTimer()

		self.timer.callback.append(self.poll)
		self.standbyTimer.callback.append(self.backToStandby)

		self.config = CrossEPG_Config()
		self.patchtype = getEPGPatchType()

		self.pdownloader = None
		self.pimporter = None
		self.pconverter = None
		self.ploader = None

		self.osd = False
		self.ontune = False
		self.lock = False

		if fileExists("/tmp/crossepg.standby"):
			os.system("rm -f /tmp/crossepg.standby")
			print "[CrossEPG_Auto] coming back in standby in 30 seconds"
			self.standbyTimer.start(30000, 1)
			
		self.config.load()
		if self.config.force_load_on_boot:
			self.loader()

	def init(self, session):
		self.session = session
		self.timer.start(self.POLL_TIMER, 1)

	def poll(self):
		from Screens.Standby import inStandby
{'fraction_non_alphanumeric': 0.08100358422939068, 'fraction_numerical': 0.016845878136200716, 'mean_word_length': 4.742798353909465, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3380817', 'n_tokens_mistral': 1048, 'n_tokens_neox': 922, 'n_words': 228}