Forcing Upload Mode

I have loaded a sketch which seems to block the processor and the port disapears.
Since then I can't upload any new sketches.
Is there a way to force the processor to stay in upload mode ?
Or is there any other recommended way to resolve this ?
I am working with Linux

Just found part of the answer myself: double clicking the reset pin set the board in DFU mode.
This was working on the Minima only!

But on the UNO WIFI R4 I am getting the error:
Failed uploading: no upload port provided.
It finally worked there as well after retrying several times

We want to confirm if your issue was solved with the UNO R4 WiFi?

Yes, it's working again.
As indicated I had to repeat the procedure on the R4 WIFI several times to make it work.