Problem:
Error: Missing binding /Users/.../ui/ui-dapp-browser/node_modules/node-sass/vendor/darwin-x64-72/binding.node
Node Sass could not find a binding for your current environment: OS X 64-bit with Node.js 12.x
Found bindings for the following environments:
- OS X 64-bit with Node.js 11.x
Solution:
npm rebuild node-sass
link modules in the folder(s) where the error appears
yarn link @evan.network/angular-gulp; yarn link @evan.network/api-blockchain-core; yarn link @evan.network/dbcp; yarn link @evan.network/smart-contracts-admin; yarn link @evan.network/smart-contracts-core; yarn link @evan.network/task; yarn link @evan.network/taskboard; yarn link @evan.network/ui-angular-core; yarn link @evan.network/ui-angular-libs; yarn link @evan.network/ui-angular-sass; yarn link @evan.network/ui-dapp-browser; yarn link @evan.network/ui-tests; yarn link @evan.network/ui-vue-core; yarn link @evan.network/ui;
- Can not read property XXX of undefined
- XXX of undefined is not a function
- module XXX not found
update all branches
git pull
gr git pull
delete externals from dev-environment folder
cd node_modules/@evan.network/ui-dapp-browser/runtime
rm -rf external
delete bcc from ui/ui-dapp-browser
rm -rf runtime/external/bcc
re-install all modules
rm -rf node_modules
yarn install // yarn install --check-files
- clean the yarn cache (optional)
- do not install at the same time in multiple command line windows
- try again and again as this errors seems to occur with a uncertain probability ...
yarn cache clean
Unlink all linked yarn modules: (check before that there are no ones you need for other projects)
cd ~/.config/yarn/link
rm -r *
Register and link modules again in dev-environment
. scripts/register-api
. scripts/register-ui
. scripts/link-all
Error: Cannot find module 'terser/lib/utils.js' rebuilding dapp-browser