TypeError: Cannot assign to read only property 'Headers' of object '[object Object]' #2271
-
I encountered the following error after updating the node_modules folder and then running the tests, TypeError: Cannot assign to read only property 'Headers' of object '[object Object]'
14 | describe('test/stream/client/xxx.tests.ts', () => {
15 | beforeAll(() => {
> 16 | server.listen();
| ^
17 | });
18 |
19 | afterEach(() => {
at recordRawFetchHeaders (node_modules/@mswjs/interceptors/lib/node/chunk-BMRE2LOX.js:157:3)
at _ClientRequestInterceptor.setup (node_modules/@mswjs/interceptors/lib/node/chunk-BMRE2LOX.js:995:5)
at _ClientRequestInterceptor.apply (node_modules/@mswjs/interceptors/lib/node/chunk-AABH3XLQ.js:75:10)
at BatchInterceptor.setup (node_modules/@mswjs/interceptors/lib/node/chunk-PGTBKPWN.js:17:19)
at BatchInterceptor.apply (node_modules/@mswjs/interceptors/lib/node/chunk-AABH3XLQ.js:75:10)
at SetupServerApi.listen (node_modules/msw/lib/node/index.js:100:22) Does anyone have similar mistakes? How should I deal with it? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
i had a similar error but it was Request instead of Headers |
Beta Was this translation helpful? Give feedback.
-
Same here with I fixed the version on |
Beta Was this translation helpful? Give feedback.
-
This looks like an MSW issue. I opened it in #2281, please track its progress there. Thanks. |
Beta Was this translation helpful? Give feedback.
This looks like an MSW issue. I opened it in #2281, please track its progress there. Thanks.