All of the above. My Elektra Semiauto is sometimes left on over night has been used every day for the last three years. Always with the portafilter loosely locked in. The gasket is still fine.
On the other hand I have just acquired a new looking 10yo Bezzera BZ99s that was only used for the first few years then stored with the portafilter handle locked in hard. When I removed the gasket it was still soft but had a groove where the basket pressed into the gasket. It leaked like sieve.
I don't like leaving the handles out. They get knocked around, fall off benches and sometimes get thrown at husbands

.. It's safer all round to leave them in the machine.
"24 hours in a day, 24 beers in a case. Coincidence? I don't think so."