pylint packaging

Sat, 25 Nov 2017 02:32:50 +0100

author
Malte Bayer <mbayer@neo-soft.org>
date
Sat, 25 Nov 2017 02:32:50 +0100
branch
packaging
changeset 64
da8bba34e7e1
parent 63
93988ac017d0
child 65
5b4234e20fc9

pylint

victrond/config.py file | annotate | diff | comparison | revisions
victrond/victrond.py file | annotate | diff | comparison | revisions
--- a/victrond/config.py	Thu Dec 18 13:04:07 2014 +0100
+++ b/victrond/config.py	Sat Nov 25 02:32:50 2017 +0100
@@ -12,7 +12,7 @@
 SHUTDOWN_CMD = "/usr/lib/victrond/scripts/shutdown.sh now"  # which command should be executed after shutdown delay?
 
 # HTTP SERVER CONFIGURATION
-HTTP_ENABLED = True
+#HTTP_ENABLED = True # OBSOLETE
 HTTP_IP = "0.0.0.0"  # http listen ip (0.0.0.0 = all interfaces)
 HTTP_PORT = 500
 
--- a/victrond/victrond.py	Thu Dec 18 13:04:07 2014 +0100
+++ b/victrond/victrond.py	Sat Nov 25 02:32:50 2017 +0100
@@ -9,7 +9,8 @@
 import serial
 import time
 import json
-from os import curdir, sep, path  # http
+from os import path # http
+#from os import curdir, sep
 from BaseHTTPServer import BaseHTTPRequestHandler, HTTPServer  # http
 import cgi  # http
 from base64 import b64decode  # http auth
@@ -19,10 +20,10 @@
 from tools import bstr_pos, test_bit, mail_deliver, tmpl_replace
 from config import BATTERYVOLTAGE, LOG_INFOS, LOG_DEBUG, NOTICE_EMAIL, \
     SHUTDOWN_DELAY, SHUTDOWN_POSTDELAY, SHUTDOWN_BATTERYLEFT, SHUTDOWN_CMD, \
-    HTTP_ENABLED, HTTP_AUTH_STATUS, HTTP_AUTH_SETTINGS, HTTP_IP, HTTP_PORT, \
+    HTTP_AUTH_STATUS, HTTP_AUTH_SETTINGS, HTTP_IP, HTTP_PORT, \
     SERIAL_DEV, HTTP_AJAX_UI
 
-__version__ = "0.8.2"
+__version__ = "0.8.3"
 
 
 class AuthException(Exception):
@@ -997,10 +998,6 @@
 
 # BEGIN MAIN
 def main():
-    from config import BATTERYVOLTAGE, LOG_INFOS, LOG_DEBUG, NOTICE_EMAIL, \
-    SHUTDOWN_DELAY, SHUTDOWN_POSTDELAY, SHUTDOWN_BATTERYLEFT, SHUTDOWN_CMD, \
-    HTTP_ENABLED, HTTP_AUTH_STATUS, HTTP_AUTH_SETTINGS, HTTP_IP, HTTP_PORT, \
-    SERIAL_DEV
     tools.rrd_check()
 
     if SHUTDOWN_POSTDELAY < 60:

mercurial