Skip to content

Conversation

@Damego
Copy link
Member

@Damego Damego commented Jan 22, 2023

About

There is case when exception was raised before http client was set.

Traceback (most recent call last):
  File "/config/.local/lib/python3.10/site-packages/interactions/client/bot.py", line 202, in start
    self._loop.run_until_complete(self._logout())
  File "/usr/lib/python3.10/asyncio/base_events.py", line 649, in run_until_complete
    return future.result()
  File "/config/.local/lib/python3.10/site-packages/interactions/client/bot.py", line 1623, in _logout
    await self._http._req.close()
AttributeError: 'str' object has no attribute '_req'

Checklist

  • The pre-commit code linter has been run over all edited files to ensure the code is linted.
  • I've ensured the change(s) work on 3.8.6 and higher.
  • I have added the versionadded, versionchanged and deprecated to any new or changed user-facing function I committed.

Pull-Request specification

I've made this pull request: (check all that apply)

  • For the documentation
  • To add a new feature
  • As a general enhancement
  • As a refactor of the library/the library's code
  • To fix an existing bug
  • To resolve #ISSUENUMBER

This is:

  • A breaking change

@Damego Damego added the bug Something isn't working label Jan 22, 2023
@Damego Damego requested a review from FayeDel January 22, 2023 08:50
@FayeDel FayeDel merged commit a997fae into interactions-py:unstable Jan 22, 2023
@Damego Damego deleted the make-sure-http-is-not-a-string branch January 23, 2023 02:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants