lvkaokao commited on
Commit
f79e1cd
1 Parent(s): fa9f3ea

add global lock for git-push.

Browse files
Files changed (1) hide show
  1. src/envs.py +3 -0
src/envs.py CHANGED
@@ -42,6 +42,9 @@ API = HfApi(token=H4_TOKEN)
42
 
43
  from git import Repo
44
  import os
 
 
 
45
  if not os.path.exists(CACHE_GIT):
46
  REPO = Repo.clone_from(
47
  url=GIT_REPO,
 
42
 
43
  from git import Repo
44
  import os
45
+ import threading
46
+ GLOBAL_COND = threading.Condition()
47
+
48
  if not os.path.exists(CACHE_GIT):
49
  REPO = Repo.clone_from(
50
  url=GIT_REPO,