diff options
author | Ofek Lev <ofekmeister@gmail.com> | 2021-12-26 12:23:57 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-12-26 17:23:57 +0000 |
commit | 1f1fdc9a0a5b7af0faf5e6c684d34dfcbf69b61f (patch) | |
tree | 915f30eae7784ab0ce00eb8f299a2edd9d4a6b25 | |
parent | bf5691502d72fba98b2b65a65116dfe94687ea23 (diff) | |
download | virtualenv-1f1fdc9a0a5b7af0faf5e6c684d34dfcbf69b61f.tar.gz |
Avoid a new deprecation warning from filelock dependency (#2237)
Co-authored-by: Bernát Gábor <gaborjbernat@gmail.com>
-rw-r--r-- | docs/changelog/2237.feature.rst | 1 | ||||
-rw-r--r-- | src/virtualenv/util/lock.py | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/docs/changelog/2237.feature.rst b/docs/changelog/2237.feature.rst new file mode 100644 index 0000000..6defa64 --- /dev/null +++ b/docs/changelog/2237.feature.rst @@ -0,0 +1 @@ +Avoid deprecation warning from py-filelock argument - by :user:`ofek`. diff --git a/src/virtualenv/util/lock.py b/src/virtualenv/util/lock.py index e141aaf..1cf968b 100644 --- a/src/virtualenv/util/lock.py +++ b/src/virtualenv/util/lock.py @@ -25,10 +25,10 @@ class _CountedFileLock(FileLock): self.count = 0 self.thread_safe = RLock() - def acquire(self, timeout=None, poll_intervall=0.05): + def acquire(self, timeout=None, poll_interval=0.05): with self.thread_safe: if self.count == 0: - super(_CountedFileLock, self).acquire(timeout=timeout, poll_intervall=poll_intervall) + super(_CountedFileLock, self).acquire(timeout, poll_interval) self.count += 1 def release(self, force=False): |