I'm watching the Soviet Storm documentary series (which is awesome), and every time they show reenactments of Russian infantry charges, there's always an officer with just a pistol charging with the men. What was the role these officers were supposed to play? They're never shown wearing helmets, and they only ever have a revolver.
Though I haven't seen a great deal of it that series seems to be generally pretty factual in it's information but it's reenactments often seem to take a fair few dramatic liberties. The pistol-armed men are likely meant to be junior officers, the lieutenants and typical platoon leaders. Junior officers in the Red Army were indeed expected to literally lead from the front and took tragically high casualties as a result, even for Red Army front-line units. While this aspect of the Eastern Front has been largely oversimplified and overblown in the West (with movies like Enemy at the Gates for example) Soviet assaults typically did involve large numbers of men charging forward with an officer at the front (ideally with copious amounts of tank and artillery/air support). In the book Tank Rider the author (a former Russian infantry officer, Evgeni Bessonov) describes participating in infantry attacks in such a way throughout the war. In his first few engagements he was in fact armed only with a pistol due to supply issues, though later on as the Red Army's overall situation improved he presumably would've picked up another weapon, likely a PPSh-41 sub-machine gun.
The actual role of the platoon/squad leader in an infantry assault would be to direct their men towards the enemy, making sure they were working to accomplish the designated objective(s) and coordinating efforts with other unit commanders. They weren't necessarily meant to get right in there to clear out the enemy (which possibly explains why in some cases they could get away with only a pistol), it was their job to direct their men to do that, but they were generally supposed to be up front leading the way initially.
So Soviet squad leaders would often attack in this sort of way, the shaky part is the pistol-only thing. Why would a Soviet officer in combat only be armed with a pistol when his German or American counterpart would virtually always be armed with another weapon, usually an SMG? I can only speculate as to how common this was if it was at all but like in Bessonov's account it probably did happen a fair bit earlier in the war due to supply issues. Perhaps a squad leader would chose to only use a pistol to lighten his load, deciding he'd only need a sidearm for emergencies and not a bulkier weapon in addition. Maybe he wanted to appear more leaderly, waving a sidearm around in front of your troops would readily mark you as an officer, essentially saying 'Hey I'm in charge, do what I say!', though of course there's no reason he still couldn't have a PPSh or whatnot slung over his shoulder too. It's possible the series just had these guys waving only pistols around for dramatic effect and/or to mark these particular guys as being leaders of some sort... or just because they could away with lowering the budget there.
As for the helmet-less bit many Red Army personnel of all ranks instead wore 'pilotka' caps. Some men preferred them over helmets for their lower weight and portability but their usage was again, likely largely also a matter of supply, many units were likely issued with such caps because there simply weren't enough helmets to go around earlier in the war. In general it does seem within photographs of the Eastern Front that the later in the war the greater the proportion of Red Army front-line men wearing steel helmets increased.
All this said the charging pistol men in the series could instead be representing commissars, political officers that were basically there to monitor Red Army units and ensure they were following the Party line. They did at times participate in combat but this generally wasn't their role, they'd typically be more towards the rear in a sort of 'advisory' capacity.
The actual sidearm a Soviet officer of any stripe in the Second World War carried would typically be either the older, somewhat obsolete M1895 Nagant revolver or the newer TT-33 semi-automatic pistol. The TT-33 is generally regarded as being superior in most ways, though the Nagant revolver is noteworthy for carrying 7 rounds rather than the usual 6 and capable of making effective use of a suppressor which is very unusual for a revolver (as far as I know this wasn't ever done in WW2 combat, just an interesting tidbit if you're into that sort of thing).
So overall, Soviet officers waving pistols around at the head of infantry charges? Definitely happened. These men being only armed with pistols? Likely happened at points particularly earlier in the war but for the most part not usual.