You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.
I've asked for help in the Truffle Gitter before filing this issue.
Issue
Can't use local installed node_modules in external scripts and migration files.
This issue is same as #255 and #259.
requre statements for global node_modules is fixed by Truffle 3.1.10, but local is not.
Steps to Reproduce
Run truffle exec ext/sample.js in following project.
Truffle is installed global, local_node_module is only local.
This bug is fixed, but we never pushed out a new version. Added tests here. Will push out a new version of Truffle with the fix once the changes are approved. trufflesuite/truffle-require#6
Issue
Can't use local installed
node_modules
in external scripts and migration files.This issue is same as #255 and #259.
requre statements for global node_modules is fixed by Truffle 3.1.10, but local is not.
Steps to Reproduce
Run
truffle exec ext/sample.js
in following project.Truffle is installed global, local_node_module is only local.
Results
Error: Cannot find module 'local_node_module'
Cause
Truffle looks only
/home/user/myProject/ext/node_modules
, but expected location is/home/user/myProject/node_modules
.Node.js looks parent directory if can not find
node_modules
.https://nodejs.org/api/modules.html#modules_loading_from_node_modules_folders
This behavior is not implemented on Truffle.
Environment
Pull Request
trufflesuite/truffle-require#1
The text was updated successfully, but these errors were encountered: