It seems we don't have the memory issue anymore so I removed at least the twisted...
authorStephan Reichholf <sreichholf@users.schwerkraft.elitedvb.net>
Thu, 5 Apr 2007 20:25:57 +0000 (20:25 +0000)
committerStephan Reichholf <sreichholf@users.schwerkraft.elitedvb.net>
Thu, 5 Apr 2007 20:25:57 +0000 (20:25 +0000)
If you experience any Problems please report them in official forums.

webinterface/src/plugin.py
webinterface/src/web-data/tools.js
webinterface/src/webif.py

index 176d292..f1f8a4f 100644 (file)
@@ -1,10 +1,18 @@
 from Plugins.Plugin import PluginDescriptor
 
-from twisted.internet import reactor
+from twisted.internet import reactor, defer
+
 from twisted.web2 import server, channel, static, resource, stream, http_headers, responsecode, http
+from twisted.web2.auth import digest, basic, wrapper
+
 from twisted.python import util
 from twisted.python.log import startLogging,discardLogs
 
+from twisted.cred.portal import Portal, IRealm
+from twisted.cred import checkers, credentials, error
+
+from zope.interface import Interface, implements
+
 import webif
 import WebIfConfig  
 import os
@@ -50,16 +58,6 @@ DEBUG = True
 DEBUG = False
 DEBUGFILE= "/tmp/twisted.log"
 
-from twisted.cred.portal import Portal
-from twisted.cred import checkers
-from twisted.web2.auth import digest, basic, wrapper
-from zope.interface import Interface, implements
-from twisted.cred import portal
-from twisted.cred import credentials, error
-from twisted.internet import defer
-from zope import interface
-
-
 def stopWebserver():
        reactor.disconnectAll()
 
@@ -186,7 +184,7 @@ class PasswordDatabase:
        this checks webiflogins agains /etc/passwd
     """
     passwordfile = "/etc/passwd"
-    interface.implements(checkers.ICredentialsChecker)
+    implements(checkers.ICredentialsChecker)
     credentialInterfaces = (credentials.IUsernamePassword,credentials.IUsernameHashedPassword)
 
     def _cbPasswordMatch(self, matched, username):
@@ -208,7 +206,7 @@ class HTTPUser(object):
        implements(IHTTPUser)
 
 class HTTPAuthRealm(object):
-       implements(portal.IRealm)
+       implements(IRealm)
        def requestAvatar(self, avatarId, mind, *interfaces):
                if IHTTPUser in interfaces:
                        return IHTTPUser, HTTPUser()
index f75ced3..58ba89c 100644 (file)
@@ -101,12 +101,14 @@ function UpdateStreamReaderLatestResponse() {
                UpdateStreamReaderStart();
                
                UpdateStreamReaderPollTimerCounterTwisted++;
-               if(UpdateStreamReaderPollTimerCounterTwisted > 5) {
+/*
+               if(UpdateStreamReaderPollTimerCounterTwisted > 5) {
                        UpdateStreamReaderPollTimerCounterTwisted = 0;
                        debug("restarting twisted");
                        debug(new Ajax.Request( "/web/restarttwisted", { method: 'get' }));
                        debug("...twisted restart");
                }
+*/
                return;
        }
 // Quickhack jjbig end
index 1630fc0..1ed2b2c 100644 (file)
@@ -16,6 +16,7 @@ from Screens.InfoBarGenerics import InfoBarServiceName, InfoBarEvent, InfoBarTun
 
 from Components.Sources.Clock import Clock
 from Components.Sources.ServiceList import ServiceList
+
 from WebComponents.Sources.Volume import Volume
 from WebComponents.Sources.EPG import EPG
 from WebComponents.Sources.Timer import Timer
@@ -27,8 +28,8 @@ from WebComponents.Sources.Settings import Settings
 from WebComponents.Sources.SubServices import SubServices
 from WebComponents.Sources.ParentControl import ParentControl
 from WebComponents.Sources.About import About
-
 from WebComponents.Sources.RequestData import RequestData
+
 from Components.Sources.FrontendStatus import FrontendStatus
 
 from Components.Converter.Converter import Converter
@@ -37,14 +38,16 @@ from Components.Element import Element
 
 from xml.sax import make_parser
 from xml.sax.handler import ContentHandler, feature_namespaces
+
 from twisted.python import util
+
 import sys
 import time
  
 # prototype of the new web frontend template system.
 
 class WebScreen(Screen):
-       def __init__(self, session,request):
+       def __init__(self, session, request):
                Screen.__init__(self, session)
                self.stand_alone = True
                self.request = request