Enum github_rs::github::GithubError [] [src]

pub enum GithubError {
    JsonParsingSyntax(ErrorCode, usizeusize),
    JsonParsingIo(Error),
    JsonParsingFromUtf8(FromUtf8Error),
    Request,
    RequestMethod,
    RequestUri(ParseError),
    RequestVersion,
    RequestHeader,
    RequestTooLarge,
    RequestStatus,
    RequestIo(Error),
    RequestSsl(Box<Error + Send + Sync>),
    RequestHttp2(Http2Error),
    RequestUtf8(Utf8Error),
    NonJsonBody,
    InvalidFields,
    Unauthorized,
    QueryLimit,
    LibIo(Error),
    Github404,
    Mime,
    LibError,
}

Errors related to improper usage of the API

Variants

Encountered if serde cannot deserialize JSON returned from the API or it cannot serialize a struct into JSON to be sent to the API.

While parsing with serde an IO error occured.

While converting from Utf8 into a byte string for the request to the API an error occured

A General error for the hyper library when none of the other errors work for it.

While setting up the method for the request an error occurred (i.e. PST instead of POST)

While parsing the Uri for the request an error occurred

An error occured with the version used to communicate (i.e. HTP/1.1 instead of HTTP/1.1)

An error in creating the header occurred making the request invalid

The request being sent is far to large to work

An invalid status code was retuned

While performing an IO action with hyper an error occurred

While intitiating, in the process of, or while terminating an SSL connection with the API an error occurred.

While attemptin to make a connection via Http2 an error occured

An error within the byte string for the request to the API occured

Encountered if whatever was returned was not at all JSON

Encountered if you've made a request with improper JSON. Most likely encountered where serde serializes a struct incorrectly, otherwise type checking prevents this error.

You aren't authorized to make the request. Make sure your token's scope allows you to make the call to the API that you would expect

Github puts a rate limit on API calls (you get more if you're authenticated). If that happens you'll get this error.

While performing an IO action within the github-rs library an error occured.

The Github API returned a 404 object.

The github-rs library encountered an error making a Mime type for the header.

The catch all error. If it's not one of the above then something in the implementation of github-rs went absolutely wrong. A bug report is greatly appreciated if you encounter this error.

Trait Implementations

impl Debug for GithubError
[src]

Formats the value using the given formatter.

impl Display for GithubError
[src]

Formats the value using the given formatter.

impl Error for GithubError
[src]

A short description of the error. Read more

The lower-level cause of this error, if any. Read more

impl From<Error> for GithubError
[src]

Performs the conversion.

impl From<Error> for GithubError
[src]

Performs the conversion.