Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Feb 25, 2022. It is now read-only.
This repository was archived by the owner on Feb 25, 2022. It is now read-only.

No repr or str on some exceptions #658

Open
@Lucidiot

Description

apistar.exceptions.ErrorResponse and ClientError do not have __repr__ or __str__ implemented; this causes error messages to be empty in tracebacks and makes debugging harder. Here is what I get with IPython for example:

~/Prog/apistar/apistar/client/transports.py in send(self, method, url, query_params, content, encoding)
 76 title = "%d %s" % (response.status_code, response.reason)
 77 raise exceptions.ErrorResponse(
---> 78 title=title, status_code=response.status_code, content=result
 79 )
 80 
ErrorResponse: 

The exception actually had a name, status code and content set.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

        AltStyle によって変換されたページ (->オリジナル) /