fixed hg mess
This commit is contained in:
@@ -1 +1 @@
|
|||||||
Version 1.99.5 (2012-03-01 14:08:23) stable
|
Version 1.99.5 (2012-03-01 15:20:14) stable
|
||||||
|
|||||||
+18
-3
@@ -98,7 +98,7 @@ def check_interaction(fn):
|
|||||||
try:
|
try:
|
||||||
if self.filename:
|
if self.filename:
|
||||||
self.clear_interaction()
|
self.clear_interaction()
|
||||||
fn(self, *args, **kwargs)
|
return fn(self, *args, **kwargs)
|
||||||
finally:
|
finally:
|
||||||
interact_lock.release()
|
interact_lock.release()
|
||||||
return check_fn
|
return check_fn
|
||||||
@@ -115,6 +115,7 @@ class WebDebugger(qdb.Frontend):
|
|||||||
self.filename = None
|
self.filename = None
|
||||||
self.lineno = None
|
self.lineno = None
|
||||||
self.exception_info = None
|
self.exception_info = None
|
||||||
|
self.context = None
|
||||||
|
|
||||||
# redefine Frontend methods:
|
# redefine Frontend methods:
|
||||||
|
|
||||||
@@ -126,12 +127,13 @@ class WebDebugger(qdb.Frontend):
|
|||||||
finally:
|
finally:
|
||||||
run_lock.release()
|
run_lock.release()
|
||||||
|
|
||||||
def interaction(self, filename, lineno, line):
|
def interaction(self, filename, lineno, line, **context):
|
||||||
# store current status
|
# store current status
|
||||||
interact_lock.acquire()
|
interact_lock.acquire()
|
||||||
try:
|
try:
|
||||||
self.filename = filename
|
self.filename = filename
|
||||||
self.lineno = lineno
|
self.lineno = lineno
|
||||||
|
self.context = context
|
||||||
finally:
|
finally:
|
||||||
interact_lock.release()
|
interact_lock.release()
|
||||||
|
|
||||||
@@ -160,7 +162,17 @@ class WebDebugger(qdb.Frontend):
|
|||||||
def do_quit(self):
|
def do_quit(self):
|
||||||
qdb.Frontend.do_quit(self)
|
qdb.Frontend.do_quit(self)
|
||||||
|
|
||||||
|
def do_exec(self, statement):
|
||||||
|
interact_lock.acquire()
|
||||||
|
try:
|
||||||
|
# check to see if we're inside interaction
|
||||||
|
if self.filename:
|
||||||
|
# avoid spurious interaction notifications:
|
||||||
|
self.set_burst(2)
|
||||||
|
# execute the statement in the remote debugger:
|
||||||
|
return qdb.Frontend.do_exec(self, statement)
|
||||||
|
finally:
|
||||||
|
interact_lock.release()
|
||||||
|
|
||||||
# create the connection between threads:
|
# create the connection between threads:
|
||||||
|
|
||||||
@@ -172,6 +184,9 @@ web_debugger = WebDebugger(front_conn) # frontend
|
|||||||
qdb_debugger = qdb.Qdb(pipe=child_conn, redirect_stdio=False, skip=None) # backend
|
qdb_debugger = qdb.Qdb(pipe=child_conn, redirect_stdio=False, skip=None) # backend
|
||||||
dbg = qdb_debugger
|
dbg = qdb_debugger
|
||||||
|
|
||||||
|
# enable getting context (stack, globals/locals) at interaction
|
||||||
|
qdb_debugger.set_params(dict(call_stack=True, environment=True))
|
||||||
|
|
||||||
import gluon.main
|
import gluon.main
|
||||||
gluon.main.global_settings.debugging = True
|
gluon.main.global_settings.debugging = True
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user