diff --git a/examples/consoles.py b/examples/consoles.py
index 607163d9495d745fe9622263f4511b2e30581811..57294540ab8d8e86b5f852c060fb6f6cbd32812c 100755
--- a/examples/consoles.py
+++ b/examples/consoles.py
@@ -107,8 +107,10 @@ def append( self, text ):
         self.text.insert( 'end', text )
         self.text.mark_set( 'insert', 'end' )
         self.text.see( 'insert' )
+        outputHook = lambda x,y: True  # make pylint happy
         if self.outputHook:
-            self.outputHook( self, text )
+            outputHook = self.outputHook
+        outputHook( self, text )
 
     def handleKey( self, event ):
         "If it's an interactive command, send it to the node."