REST sensor not working after 118 update

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’.

platform: rest
resource: !secret iparcelbox_rest_api
name: iParcelBox Status
json_attributes_path: "$.data"
json_attributes:
  - routerSSID
  - routerRSSI
  - boxStatus
  - lastOpened
  - parcelCount
  - connected
  - lockStatus
  - lidStatus
value_template: "{{ value_json['data']['boxStatus'] }}"
username: !secret iparcelbox_username
password: !secret iparcelbox_password
authentication: digest
verify_ssl: False
scan_interval: 3600

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.

After downgrading back to 117.4 it works again.

Any suggestions?

Looks like you searched a few hours too early, someone’s having the same issue, you could press the +1 emoji on the issue I guess:


What could work as a temporary fix:
  • Go to https://downgit.github.io/#/home
  • Download https://github.com/home-assistant/core/tree/0.117.6/homeassistant/components/rest
  • Unpack the .zip as a custom_component (unpack the files into config/custom_components/rest/)
1 Like

Thank you @fedot.

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.

Thank you @fedot.

The download solved the problem.
Before I had the error message: AttributeError: ‘NoneType’ object has no attribute ‘update’