I just had a thought and wish I knew the answer. Looking at the light sensors that screw into the light bulb socket I am wondering what is keeping the light from the bulb you use in the sensors from affecting the sensors? You know, it gets dark, light comes on, sensor sees light from bulb and thinks it daylight again and shuts the light off.
This can happen, especially if there is something nearby to reflect the light back to the sensor. Usually the best thing is to install and test, and then modify the installation if there are problems.
What many manufacturers will do, especially in vehicles with dashboard sensors for autmoatic headlights, is include a filter that shades out almost all light above the infrared range. Natural sunlight puts out very high levels of infrared radiation compared to other light sources and will easily trip the sensor through the filter, while other light sources will not.