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

[UE] Bug: Nodejs 后端模式,打包后似乎没有拷贝 node_modules #1955

Closed
3 tasks done
shpz opened this issue Dec 28, 2024 · 1 comment
Closed
3 tasks done
Assignees
Labels
bug Something isn't working Unreal

Comments

@shpz
Copy link
Contributor

shpz commented Dec 28, 2024

前置阅读 | Pre-reading

Puer的版本 | Puer Version

main branch

UE的版本 | UE Version

5.4.4

发生在哪个平台 | Platform

win

错误信息 | Error Message

Error: can not find axios in ../../../Win64Client/Content/JavaScript/modules/Context
at require (Pak: ......\Win64Client\Content\Paks\Win64Client-Windows.pak\Win64Client\Content\JavaScript\puerts\modular.js:131:23)
at ......\Win64Client\Content\JavaScript\modules\Context\ContextManager.js:8:17
at executeModule (Pak: ......\Win64Client\Content\Paks\Win64Client-Windows.pak\Win64Client\Content\JavaScript\puerts\modular.js:70:9)
at require (Pak: ......\Win64Client\Content\Paks\Win64Client-Windows.pak\Win64Client\Content\JavaScript\puerts\modular.js:183:29)
at ......\Win64Client\Content\JavaScript\main.js:9:26
at executeModule (Pak: ......\Win64Client\Content\Paks\Win64Client-Windows.pak\Win64Client\Content\JavaScript\puerts\modular.js:70:9)
at require (Pak: ......\Win64Client\Content\Paks\Win64Client-Windows.pak\Win64Client\Content\JavaScript\puerts\modular.js:183:29)

问题重现 | Bug reproduce

使用 PuerTS Nodejs 后端打包 win64 后,启动客户端后报错没有找到 Nodejs Package,手动拷贝一次 node_modules 到 win64 包根目录解决了这个问题

@shpz shpz added bug Something isn't working Unreal labels Dec 28, 2024
@chexiongsheng
Copy link
Collaborator

你如果本来npm模块在编辑器下就直接安装Content/JavaScript下,就不用另外拷贝一趟了

@shpz shpz closed this as completed Jan 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Unreal
Projects
None yet
Development

No branches or pull requests

2 participants