Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to Release the lock file before script end ? #94

Closed
instasck opened this issue Nov 3, 2024 · 1 comment
Closed

How to Release the lock file before script end ? #94

instasck opened this issue Nov 3, 2024 · 1 comment

Comments

@instasck
Copy link

instasck commented Nov 3, 2024

I am looking for a way to sync 2 process using a lock file.
So only one process can run at the same time.
runner_lock_obj = singleton.SingleInstance(lockfile=running_lock_filename)
.. do what ever but here the other file wont run...
runner_lock_obj.del()
.. do what ever but here the other file CAN run...

This works nice, just when I get out of the run I get

[Errno 9] Bad file descriptor
Exception ignored in: <function SingleInstance.__del__ at 0x000001ECB2A58670>
Traceback (most recent call last):
  File "C:\Program Files\Python39\lib\site-packages\tendo\singleton.py", line 89, in __del__
SystemExit: -1

I guess it already exited ... can IU avoid this error ?

@ssbarnea
Copy link
Member

ssbarnea commented Nov 11, 2024

Windows is no longer supported, #106

@ssbarnea ssbarnea closed this as not planned Won't fix, can't repro, duplicate, stale Nov 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants