Skip to content

Node 18 and @octokit/core v5.0.0 incompatability #77

@ataylorme

Description

@ataylorme

Describe the bug
Moctokit does not work with Node 18. All .reply responses return the same result to Octokit. Setting the status as 200 and 404 do not differ the mock response`

I believe this is due to Node 18 using a new http client named undici for fetch API support

Looking at the code for Moctokit it uses nock, which has an open issue for undici support

To Reproduce
Use Moctokit with Node 18 and @octokit/core v5.0.0

Expected behavior
Proper mock responses are returned.

Additional context
I don't actually expect this to be solved until Nock is updated but an incompatibility note in the README would be nice.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions