Remove old code and debugging statements.

pull/7/head
Ferry Boender 10 years ago
parent 56d4d12d1f
commit 4c289f992c
  1. 4
      src/scriptform.py

@ -178,8 +178,6 @@ class FormDefinition:
m = re.match('([0-9]{4})-([0-9]{2})-([0-9]{2})', value) m = re.match('([0-9]{4})-([0-9]{2})-([0-9]{2})', value)
if m: if m:
return value return value
#g = m.groups()
#return datetime.date(int(g[0]), int(g[1]), int(g[2]))
elif field_def.get('required', False): elif field_def.get('required', False):
raise ValueError( raise ValueError(
"Invalid value for date field: {}".format(value)) "Invalid value for date field: {}".format(value))
@ -201,6 +199,7 @@ class FormDefinition:
class ThreadedHTTPServer(ThreadingMixIn, BaseHTTPServer.HTTPServer): class ThreadedHTTPServer(ThreadingMixIn, BaseHTTPServer.HTTPServer):
pass pass
class WebSrv: class WebSrv:
""" """
Very basic web server. Very basic web server.
@ -481,7 +480,6 @@ class ScriptForm:
def run(self, listen_addr='0.0.0.0', listen_port=80): def run(self, listen_addr='0.0.0.0', listen_port=80):
ScriptFormWebApp.vitaform = self ScriptFormWebApp.vitaform = self
ScriptFormWebApp.callbacks = self.callbacks ScriptFormWebApp.callbacks = self.callbacks
#webapp = ScriptFormWebApp(vitaform, self.callbacks)
WebSrv(ScriptFormWebApp, listen_addr=listen_addr, listen_port=listen_port) WebSrv(ScriptFormWebApp, listen_addr=listen_addr, listen_port=listen_port)

Loading…
Cancel
Save