I’d have a good look at the temperature sender and the wiring to and from the gauge. Perhaps swap the senders between engines and see if the problem follows the sender. They are a very simple device but they are installed in a rather severe service location and can degrade over time.
The engines don’t generate much heat into the oil while idling so there is no source of heat to raise the temperature suddenly like that.
All of my troubles with oil temperature over the years have ended up being sensor or gauge related.
Mechanically you could have an issue with the vernatherm spring loaded temperature actuated valve that routes oil to the cooler at higher temperatures. This valve is a thermostat that regulates the engine oil temperature. If the engine is cool the oil is routed directly back to the engine. If it is hot it is routed to the oil cooler. Perhaps that is operating in an erratic manner or closing at lower oil pressures (such as idling) but opening properly at higher oil pressures (flight). The temperature sender is mounted right next to it on the same housing as the oil filter.
Either way I’d hunt it down relentlessly. The one thing you don’t want to have gremlins in is your engine’s lubrication system. Even if it just a gauge / sender issue it could be masking something more serious.
Good luck,
William