If you have multiple browser threads then you can add a date column in database for each account. When some action is finished then you can add 30 minutes to the date now and add it to the database of that particular account. Then add a check condition in the beginning of the thread which checks if the current date is less or greater than the database date. If it is greater that means there is still time left and then close that thread without opening browser.
Timeout if Thread takes longer then XX minutes
-
@blird said in Timeout if Thread takes longer then XX minutes:
Hey I have a script that sometimes takes wayyy to long. Is there any way I can set a max duration in s/ms for a thread to be alive and then killed?
Create a function for some work, in the main function run that function asynchronously, wait for some time, and if the thread is still alive, kill it and exit the thread.
-
@blird said in Timeout if Thread takes longer then XX minutes:
Appreciate it. Any way I can get in contact with you?
I do not provide any free private consultations to anyone.
If you would like to make a paid offer, feel free to send me a private message on this forum.