Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Unified Diff: tools/telemetry/telemetry/core/platform/posix_platform_backend.py

Issue 739623005: [Telemetry] Resolve errors due to new pylint checker. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ready to land Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: tools/telemetry/telemetry/core/platform/posix_platform_backend.py
diff --git a/tools/telemetry/telemetry/core/platform/posix_platform_backend.py b/tools/telemetry/telemetry/core/platform/posix_platform_backend.py
index c9ebc6dfa40f9e76a2a2dc189a949e00b2636fdd..6816f07a7910f57768203af5495020767205640b 100644
--- a/tools/telemetry/telemetry/core/platform/posix_platform_backend.py
+++ b/tools/telemetry/telemetry/core/platform/posix_platform_backend.py
@@ -56,7 +56,7 @@ class PosixPlatformBackend(desktop_platform_backend.DesktopPlatformBackend):
"""Returns a list of child pids of |pid|."""
ps_output = self.GetPsOutput(['pid', 'ppid', 'state'])
ps_line_re = re.compile(
- '\s*(?P<pid>\d+)\s*(?P<ppid>\d+)\s*(?P<state>\S*)\s*')
+ r'\s*(?P<pid>\d+)\s*(?P<ppid>\d+)\s*(?P<state>\S*)\s*')
processes = []
for pid_ppid_state in ps_output:
m = ps_line_re.match(pid_ppid_state)
@@ -74,7 +74,7 @@ class PosixPlatformBackend(desktop_platform_backend.DesktopPlatformBackend):
def IsApplicationRunning(self, application):
ps_output = self.GetPsOutput(['command'])
application_re = re.compile(
- '(.*%s|^)%s(\s|$)' % (os.path.sep, application))
+ r'(.*%s|^)%s(\s|$)' % (os.path.sep, application))
return any(application_re.match(cmd) for cmd in ps_output)
def LaunchApplication(

Powered by Google App Engine
This is Rietveld 408576698