How to not repeat a block in puppeteer

Is there any way to open a browser and set cookies only once in a lifetime of checking? The idea behind this is that I want to open a browser and set the cookies only once and not repeat that on every bot is that possible to achieve in OB2 with puppeteer?
And I’m also facing one issue
using puppeteer when I try to set a cookie it says 1 cookie is set but it doesn’t appear on the browser
Capture

and it’s not showing on the page
Capture
Am I doing something wrong here or is there is a bug in puppeteer block
@Ruri
Capture

Saving and restoring cookies - Guides / LoliCode - OpenBullet

Try

1 Like

@EdwardN Thanks I solved the cookies problem but is there any way to not repeat a block?

Yes u can put the set cookie block inside an IF condition which checks whether cookies are already set or not, if they are not then execute the block otherwise skip

@thelurker thanks for the idea but do you have any info about restart the job again when it’s completed

Do U mean with the same input data?

This feature is currently being worked on. You will be able to write a “startup” script that will only be executed once at the start of the job, where you will set the cookies to use for the rest of the run. Expect it to be out soon.

1 Like

oh, that is going to be awsome

yes with the same input data

What are the possible statuses?
If its success or custom then you can just make a manual loop using if and jump statements and juml the job to the start after it ends.
If is for running it a specific amount of times, u can make a counter and use if counter < number then jump to start

is there any way to find out if the job has been done

Ofcourse yes there are ways to know that, most popular is the block keycheck

Can you provide me an example or lolicode to check if the job is done and restart it?