The situation is complex and the lens only plays a part in what is going on.
First of all, with a light source lacking a continuous output spectrum (think fluorescent or their derivatives), the usual assumption behind the colour spatial autocorrelation in the scene breaks down. The image will typically show purple fringing with nearly all lenses. As a collateral effect focusing can also be tricky. Do note that purple fringing also can result from an overloaded sensor.
Secondly, the correction of chromatic aberrations in a lens, in particular wide angle and zoom optics, might be less efficient at certain focal settings (zooms) or towards the corners of the image (wide angles in particular, but all lenses can have this problem). For lenses with a very long focusing range, such as Micro-Nikkors or equivalents, chromatic aberrations can be more visible in the near range. Even the legendary Voigtländer 125 mm f/2.5 APO-Lanthar suffers from this issue near 1:1. Lenses with internal focusing (IF, RF designs) very often are troubled with longitudinal chromatic aberration (axial colour) making the image exhibit differently coloured fringes in front of and just behind the plane of focus.
Thirdly, as you already noted, harsh transients in contrast can trigger colour fringing of which kind the red/cyan is the most common. The cause is again to be split between subject (excessive transients), lens (residual chromatic aberration in particular the lateral kind), and camera (inadequate handling and modelling of colour spatial autocorrelation).