Hi,
While investigating the issue with Lightorio, I took a look at this. I'm certain this mod is to blame for the issue, I suspect you'll need to add a similar exception to your logic as for Lightorio.
The only mods I had enabled were the dependencies for geothermal, and this mod:
https://imgur.com/a/UEVToBp
Not clear how it was functioning correctly for you.
Might you be better off changing your data-updates logic to be for "small-lamp" only? This will make vanilla lamps placeable on water, but won't break modded lamps. Not clear if there's a specific reason you're updating all lamps.
Thanks
Jack