mirror of
https://github.com/bellingcat/snscrape.git
synced 2026-06-13 04:48:28 +03:00
Fix crash on race condition in CLI guest token manager resets
Fixes #414
This commit is contained in:
@@ -287,7 +287,11 @@ class _CLIGuestTokenManager(GuestTokenManager):
|
|||||||
def reset(self):
|
def reset(self):
|
||||||
super().reset()
|
super().reset()
|
||||||
with self._lock:
|
with self._lock:
|
||||||
os.remove(self._file)
|
try:
|
||||||
|
os.remove(self._file)
|
||||||
|
except FileNotFoundError:
|
||||||
|
# Another process likely already removed the file
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
class _TwitterAPIType(enum.Enum):
|
class _TwitterAPIType(enum.Enum):
|
||||||
|
|||||||
Reference in New Issue
Block a user