Replace deprecated logging function with equivalent
authorChristian Herdtweck <christian.herdtweck@intra2net.com>
Wed, 14 Nov 2018 09:53:10 +0000 (10:53 +0100)
committerChristian Herdtweck <christian.herdtweck@intra2net.com>
Wed, 14 Nov 2018 09:53:10 +0000 (10:53 +0100)
src/arnied_wrapper.py

index b759379..a97242e 100644 (file)
@@ -168,8 +168,8 @@ def go_online(provider_id, wait_online=True, timeout=60, vm=None):
 
     get_cnf_res = run_cmd(cmd='get_cnf PROVIDER %d' % provider_id, vm=vm)
     if b'PROVIDER,' not in get_cnf_res.stdout:
-        log.warn('There is no PROVIDER %d on the vm. Skipping go_online.',
-                 provider_id)
+        log.warning('There is no PROVIDER %d on the vm. Skipping go_online.',
+                    provider_id)
         return
 
     cmd = 'tell-connd --online P%i' % provider_id