Revert "Use OS level locking in git_cache.py"

This reverts commit d3affaa62488e0d67e04f810f1c2f2f40793e06b.

Reason for revert: no attribute ignore_lock

Original change's description:
> Use OS level locking in git_cache.py
> 
> Without OS level locking it's possible to leave "lock" files on disk
> which will prevent next run to acquire those locks. This can easily
> happen if SIGKIL is issued.
> 
> R=​apolito@google.com, ehmaldonado@chromium.org
> 
> Bug: 1049610
> Change-Id: Id87aa1376b9ea5ff0c2d14f3603636493ed1dd5b
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2189333
> Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
> Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
> Commit-Queue: Josip Sokcevic <sokcevic@google.com>

TBR=iannucci@chromium.org,ehmaldonado@chromium.org,apolito@google.com,infra-scoped@luci-project-accounts.iam.gserviceaccount.com,sokcevic@google.com

Change-Id: Iecc963e0a99d7f59f3f8801e529839346f9fbaf3
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 1049610
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2211186
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
diff --git a/gclient.py b/gclient.py
index b2f15a7..4480c3f 100755
--- a/gclient.py
+++ b/gclient.py
@@ -1407,14 +1407,12 @@
 
 You should ensure that the URL listed in .gclient is correct and either change
 it or fix the checkout.
-''' % {
-                  'checkout_path': os.path.join(self.root_dir, dep.name),
-                  'expected_url': dep.url,
-                  'expected_scm': dep.GetScmName(),
-                  'mirror_string': mirror_string,
-                  'actual_url': actual_url,
-                  'actual_scm': dep.GetScmName()
-              })
+'''  % {'checkout_path': os.path.join(self.root_dir, dep.name),
+        'expected_url': dep.url,
+        'expected_scm': dep.GetScmName(),
+        'mirror_string': mirror_string,
+        'actual_url': actual_url,
+        'actual_scm': dep.GetScmName()})
 
   def SetConfig(self, content):
     assert not self.dependencies
@@ -2689,12 +2687,13 @@
   parser.add_option('--no_bootstrap', '--no-bootstrap',
                     action='store_true',
                     help='Don\'t bootstrap from Google Storage.')
-  parser.add_option('--ignore_locks',
-                    action='store_true',
-                    help='No longer used.')
-  parser.add_option('--break_repo_locks',
-                    action='store_true',
-                    help='No longer used.')
+  parser.add_option('--ignore_locks', action='store_true',
+                    help='GIT ONLY - Ignore cache locks.')
+  parser.add_option('--break_repo_locks', action='store_true',
+                    help='GIT ONLY - Forcibly remove repo locks (e.g. '
+                      'index.lock). This should only be used if you know for '
+                      'certain that this invocation of gclient is the only '
+                      'thing operating on the git repos (e.g. on a bot).')
   parser.add_option('--lock_timeout', type='int', default=5000,
                     help='GIT ONLY - Deadline (in seconds) to wait for git '
                          'cache lock to become available. Default is %default.')
@@ -2715,13 +2714,6 @@
   if not client:
     raise gclient_utils.Error('client not configured; see \'gclient config\'')
 
-  if options.ignore_locks:
-    print('Warning: ignore_locks is no longer used. Please remove its usage.')
-
-  if options.break_repo_locks:
-    print('Warning: break_repo_locks is no longer used. Please remove its '
-          'usage.')
-
   if options.revisions and options.head:
     # TODO(maruel): Make it a parser.error if it doesn't break any builder.
     print('Warning: you cannot use both --head and --revision')
@@ -2792,14 +2784,12 @@
                     help='don\'t run pre-DEPS hooks', default=False)
   parser.add_option('--upstream', action='store_true',
                     help='Make repo state match upstream branch.')
-  parser.add_option('--break_repo_locks',
-                    action='store_true',
-                    help='No longer used.')
+  parser.add_option('--break_repo_locks', action='store_true',
+                    help='GIT ONLY - Forcibly remove repo locks (e.g. '
+                      'index.lock). This should only be used if you know for '
+                      'certain that this invocation of gclient is the only '
+                      'thing operating on the git repos (e.g. on a bot).')
   (options, args) = parser.parse_args(args)
-  if options.break_repo_locks:
-    print('Warning: break_repo_locks is no longer used. Please remove its ' +
-          'usage.')
-
   # --force is implied.
   options.force = True
   options.reset = False