Skip to content

The http client githubot uses does not handle redirects #32

@rophy

Description

@rophy

Hi,

githubot supports GitHub Enterprise (through changing the base URL).

But when I try to use it in my GHE, the server responses with a 302 redirects, which fails githubot :

{ server: 'GitHub.com',
  date: 'Wed, 13 Jul 2016 07:05:20 GMT',
  'content-type': 'text/html',
  'content-length': '154',
  connection: 'close',
  location: 'https://github.ibm.com/sessions/_auth_request_bounce?return_to=https%3a%2f%2fapi.github.ibm.com%2frepos%2ftsaiyl%2fbluemix-catalog-scan%2fissues%3fassignee%3d%26labels%3dtodo_current' }

Digging in the problem, I found that this is because the http client (node-scoped-http-client) being used does not support 302: technoweenie/node-scoped-http-client#7
In addition, the node-scoped-http-client is no longer being maintained (title of the github project says: Unmaintained. Free push/npm access to anyone interested.).

Is it possible to switch to another http client (e.g. https://github.com/request/request) so that GHE redirects can be handled?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions