Initially was reported in flutter - ably/ably-flutter#583
When server responds with a http error in JSON format, library assumes it's a dictionary with an error sub-dictionary. error can be just a string.
You can reproduce this error by running test__014__RestClient__client_should_handle_error_messages_in_plaintext_and_HTML_format test with https://api.restful-api.dev/objects/<not_existing_object_id> url.
┆Issue is synchronized with this Jira Task by Unito