I have a REST sensor that works under 117.4 but when I upgraded to 118.2 it does not work and has an error in the logs of - AttributeError: ‘NoneType’ object has no attribute ‘fileno’.
I have tried swapping the secrets for full values which made no difference and after a good Google session could not find any similar issues and I can’t see anything wrong with the code when checked against the docs.
I have added my bit to the issue and tried your workaround. The ‘custom’ rest sensor loads but unfortunately still gives the same error with the sensor.