Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to intercept octokit request using msw v2. #2409

Open
4 tasks done
Lord-Kamina opened this issue Jan 11, 2025 · 1 comment
Open
4 tasks done

Unable to intercept octokit request using msw v2. #2409

Lord-Kamina opened this issue Jan 11, 2025 · 1 comment
Labels
bug Something isn't working needs:triage Issues that have not been investigated yet. scope:node Related to MSW running in Node

Comments

@Lord-Kamina
Copy link

Prerequisites

Environment check

  • I'm using the latest msw version
  • I'm using Node.js version 18 or higher

Node.js version

20.18.1

Reproduction repository

https://github.com/Lord-Kamina/always-upload-cache/tree/msw-issue

Reproduction steps

npm run test -- --runInBand --verbose --testLocationInResults=true --runTestsByPath tests/saveImpl.test.ts

Current behavior

The 'DELETE' requests sent by octokit are not being intercepted by MSW

Expected behavior

They should be intercepted? I really don't know what am I doing wrong.
What was virtually the same code was working in node16 using msw 0.49, you can see the working branch here: https://github.com/Lord-Kamina/always-upload-cache/tree/allow-refresh

@Lord-Kamina Lord-Kamina added bug Something isn't working needs:triage Issues that have not been investigated yet. scope:node Related to MSW running in Node labels Jan 11, 2025
@Lord-Kamina
Copy link
Author

Lord-Kamina commented Jan 27, 2025

Some more info... from this https://github.com/octokit/action.js/blob/49a9baa814345814970d410d61f5880a35e2cdf9/src/index.ts#L9, I gather this is related to #2165, but I didn't really understand how to fix it from what was described in that issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs:triage Issues that have not been investigated yet. scope:node Related to MSW running in Node
Projects
None yet
Development

No branches or pull requests

1 participant