diff --git a/wx/lib/pubsub/core/callables.py b/wx/lib/pubsub/core/callables.py index 00c8a061..3c4a9b10 100644 --- a/wx/lib/pubsub/core/callables.py +++ b/wx/lib/pubsub/core/callables.py @@ -57,16 +57,16 @@ def getRawFunction(callable_): recognized type (function, method or has __call__ method).""" firstArg = 0 if isfunction(callable_): - #print('Function', getID(callable_)) + #print('Function %s' % getID(callable_)) func = callable_ elif ismethod(callable_): - #print('Method', getID(callable_)) + #print('Method %s' % getID(callable_)) func = callable_ if func.__self__ is not None: # Method is bound, don't care about the self arg firstArg = 1 elif hasattr(callable_, '__call__'): - #print('Functor', getID(callable_)) + #print('Functor %s' % getID(callable_)) func = callable_.__call__ firstArg = 1 # don't care about the self arg else: diff --git a/wx/lib/pubsub/core/kwargs/datamsg.py b/wx/lib/pubsub/core/kwargs/datamsg.py index ef68b770..15c1ac04 100644 --- a/wx/lib/pubsub/core/kwargs/datamsg.py +++ b/wx/lib/pubsub/core/kwargs/datamsg.py @@ -12,8 +12,8 @@ class Message: via Message.data, while the topic name is available in Message.topic:: def listener(msg): - print("data is ", msg.data) - print("topic name is ", msg.topic) + print("data is %s" % msg.data) + print("topic name is %s" % msg.topic) print(msg) The example also shows (last line) how a message is convertible to a string. diff --git a/wx/lib/pubsub/core/kwargs/publisher.py b/wx/lib/pubsub/core/kwargs/publisher.py index 5e3fd255..ba08cc7e 100644 --- a/wx/lib/pubsub/core/kwargs/publisher.py +++ b/wx/lib/pubsub/core/kwargs/publisher.py @@ -72,6 +72,6 @@ class PublisherArg1Stage2(Publisher): if policies.msgProtocolTransStage is not None: Publisher = PublisherArg1Stage2 - #print('Using protocol', Publisher) + #print('Using protocol %s' % Publisher) diff --git a/wx/lib/pubsub/core/topicobj.py b/wx/lib/pubsub/core/topicobj.py index 368ffecc..5f218f32 100644 --- a/wx/lib/pubsub/core/topicobj.py +++ b/wx/lib/pubsub/core/topicobj.py @@ -409,7 +409,7 @@ class Topic(PublisherMixin): self.__handlingUncaughtListenerExc = False except Exception: exc = py2and3.getexcobj() - #print('exception raised', exc) + #print('Exception raised\n%s' % exc) self.__handlingUncaughtListenerExc = False raise ExcHandlerError(listener.name(), topicObj, exc) diff --git a/wx/lib/pubsub/policies.py b/wx/lib/pubsub/policies.py index 239c0054..16b90200 100644 --- a/wx/lib/pubsub/policies.py +++ b/wx/lib/pubsub/policies.py @@ -19,8 +19,8 @@ def setMsgDataArgName(stage, listenerArgName, senderArgNameAny=False): senderKwargNameAny = senderArgNameAny msgDataArgName = listenerArgName msgProtocolTransStage = stage - #print(repr(policies.msgProtocolTransStage), - # repr(policies.msgDataProtocol), - # repr(policies.senderKwargNameAny), - # repr(policies.msgDataArgName)) - #print('override "arg1" protocol arg name:', argName) + #print('%s' % repr(policies.msgProtocolTransStage)) + #print('%s' % repr(policies.msgDataProtocol)) + #print('%s' % repr(policies.senderKwargNameAny)) + #print('%s' % repr(policies.msgDataArgName)) + #print('override "arg1" protocol arg name: %s' % argName)