remove PLC.Debug.log, use PLC.Logger.logger instead
[plcapi.git] / PLC / Peers.py
index 6489199..c272a2a 100644 (file)
@@ -4,10 +4,11 @@
 
 import re
 from types import StringTypes
+import traceback
 from urlparse import urlparse
 
 import PLC.Auth
-from PLC.Debug import log
+from PLC.Logger import logger
 from PLC.Faults import *
 from PLC.Namespace import hostname_to_hrn
 from PLC.Parameter import Parameter, Mixed
@@ -174,7 +175,7 @@ class Peer(Row):
             tags = {'hrn': hrn}
             Node(self.api, node).update_tags(tags)
         except:
-            print >>log, "WARNING: could not find out hrn on hostname=%s"%node['hostname']
+            logger.exception("Could not find out hrn on hostname=%s"%node['hostname'])
 
     def remove_node(self, node, commit = True):
         """