I've been through many types of earplug - but no electronic ones, unfortunately for the purposes of the question - and my overall winners so far are easily Sleepsoft earplugs made by Alpine. They have the best balance of noise attenuation to comfort by miles of those I've tried (for sleeping, that is. But I think I'll trying wearing them elsewhere soon). I can keep these in for hours without itching or heating up my ear canals, and their design includes a filtered channel which doesn't completely isolate you from sound (so if somebody opens a door nearby etc. you'll probably be aware, but only quietly). Cheaper models often have the same channel design but I found in other brands it generally had next to no filtering effect, so reduced sound only minimally.
3M Peltor ear-defenders are pretty excellent, too, if a bit bulky. Very bulky.