| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -166,7 +166,12 @@ def _release_lock(self): | |||
| 166 | 166 | """ | |
| 167 | 167 | if not self._has_lock(): | |
| 168 | 168 | return | |
| 169 | - os.remove(self._lock_file_path()) | ||
| 169 | + | ||
| 170 | + # if someone removed our file beforhand, lets just flag this issue | ||
| 171 | + # instead of failing, to make it more usable. | ||
| 172 | + lfp = self._lock_file_path() | ||
| 173 | + if os.path.isfile(lfp): | ||
| 174 | + os.remove(lfp) | ||
| 170 | 175 | self._owns_lock = False | |
| 171 | 176 | ||
| 172 | 177 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments