I used to tune CLAHE until a folder of sample photos looked pretty. Then night shift sent a batch that was basically orange noise, and day shift sent photos with a white rectangle where the dock door blew out the sensor.
Lighting is not a preprocessing footnote. It is the domain.
Detect the lighting class cheaply
A very small classifier — even rules on color temperature and brightness — lets you pick a preprocessing path. Warm and dark gets one stretch. Cold and bright gets another. Blown highlights get a request for a different angle, not a hallucination.
I log which path ran with each image. When accuracy drops, I can see that we hired a new lighting layout in aisle 4, not that "the model got worse."
Shoot a calibration set when lights change
When facilities replace bulbs, I ask for twenty photos of known SKUs under the new lights. That is cheaper than rediscovering the failure in mis-picks.