I had trouble all last year with my vacuum .... and a small amount of bubbles in the basket as well.
If i close the main drain and switched to just the skimmer / vacuum the pump would lose prime (i assume that is the correct phrase - it would stop pumping water until i reopen the main drain).
Last year i had a leak and installed a new valve as part of my repair ..... it is different than the previous valve and different than the valve for the main drain .... i believe i have read on here that the incorrect valve type could cause my issues.
this is the new one
here is the main drain valve