From d94f8ea2b5458c36f10adaf46b53aba359d6a655 Mon Sep 17 00:00:00 2001 From: John Budorick Date: Fri, 27 Mar 2020 15:55:24 +0000 Subject: [PATCH] gclient: update logging.warn to logging.warning. logging.warn is deprecated. Change-Id: I047f356b8eeced631edc51e3b846f0995f4ce95e Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2124526 Reviewed-by: Edward Lesmes Commit-Queue: John Budorick --- gclient.py | 2 +- gclient_scm.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/gclient.py b/gclient.py index d132d3cd7..285bb017e 100755 --- a/gclient.py +++ b/gclient.py @@ -601,7 +601,7 @@ class Dependency(gclient_utils.WorkItem, DependencySettings): self.url)) # In theory we could keep it as a shadow of the other one. In # practice, simply ignore it. - logging.warn('Won\'t process duplicate dependency %s' % sibling) + logging.warning("Won't process duplicate dependency %s" % sibling) return False return True diff --git a/gclient_scm.py b/gclient_scm.py index d97c7e84a..c58af6ce0 100644 --- a/gclient_scm.py +++ b/gclient_scm.py @@ -885,8 +885,8 @@ class GitWrapper(SCMWrapper): except NoUsableRevError as e: # If the DEPS entry's url and hash changed, try to update the origin. # See also http://crbug.com/520067. - logging.warn( - 'Couldn\'t find usable revision, will retrying to update instead: %s', + logging.warning( + "Couldn't find usable revision, will retrying to update instead: %s", e.message) return self.update(options, [], file_list)