[go: up one dir, main page]

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

throw new TypeError(${context} is not a ReadableStream.); #65

Closed
5 tasks done
powersee opened this issue Mar 4, 2023 · 4 comments
Closed
5 tasks done

throw new TypeError(${context} is not a ReadableStream.); #65

powersee opened this issue Mar 4, 2023 · 4 comments
Labels
question Further information is requested

Comments

@powersee
Copy link
powersee commented Mar 4, 2023

Describe the bug

机器 Mac mini M1

❯ node -v
v16.13.2

❯ npm -v
8.3.0

按照 readme 操作之后,运行不起来

❯ npm run dev

novel-gpt@0.0.1 dev
astro dev

(node:55714) ExperimentalWarning: stream/web is an experimental feature. This feature could change at any time
(Use node --trace-warnings ... to show where the warning was created)
🚀 astro v2.0.17 started in 40ms

┃ Local http://localhost:3000/
┃ Network use --host to expose

file:///Users/ming/code/chatgpt-demo/node_modules/node-fetch-native/dist/shared/node-fetch-native.2b047dc1.mjs:432
throw new TypeError(${context} is not a ReadableStream.);
^

TypeError: First parameter has member 'readable' that is not a ReadableStream.
at assertReadableStream (file:///Users/ming/code/chatgpt-demo/node_modules/node-fetch-native/dist/shared/node-fetch-native.2b047dc1.mjs:432:21)
at convertReadableWritablePair (file:///Users/ming/code/chatgpt-demo/node_modules/node-fetch-native/dist/shared/node-fetch-native.2b047dc1.mjs:3509:11)
at ReadableStream.pipeThrough (file:///Users/ming/code/chatgpt-demo/node_modules/node-fetch-native/dist/shared/node-fetch-native.2b047dc1.mjs:3584:33)
at fetchFinale (/Users/ming/code/chatgpt-demo/node_modules/undici/lib/fetch/index.js:973:52)
at mainFetch (/Users/ming/code/chatgpt-demo/node_modules/undici/lib/fetch/index.js:773:5)
at processTicksAndRejections (node:internal/process/task_queues:96:5)

Reproduction

1

System Info

1

Used Package Manager

npm

Validations

  • Follow our Code of Conduct
  • Read the Contributing Guide.
  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • Check that this is a concrete bug. For Q&A, please open a GitHub Discussion instead.
  • The provided reproduction is a minimal reproducible of the bug.
@khum08
Copy link
khum08 commented Mar 4, 2023

相同问题

@likui628
Copy link
Contributor
likui628 commented Mar 4, 2023

node v18

@powersee
Copy link
Author
powersee commented Mar 4, 2023

感谢 @likui628 问题已解决。

因为我在 Mac,通过

brew install node@18

可以安装好,然后把 /opt/homebrew/opt/node@18/bin 加入环境变量。

之后再来运行项目就 OK 了。

@khum08 你或许可以参考一下。

@powersee powersee closed this as completed Mar 4, 2023
@MssText
Copy link
MssText commented Mar 4, 2023

确实 需要node 18+

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

5 participants