question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG] No such file or directory, open 'node_modules\src\util\root.ts'

See original GitHub issue

Type of Issue

[x ] Bug Report
[ ] Feature Request

Description

> ng-packagr -p package.json

Building Angular library
Generating bundle for project
Cleaning bundle build directory
Processing assets
Running ngc
Compiling to FESM15
'default' is not exported by 'node_modules\rxjs\add\operator\toPromise.js'
Compiling to FESM5
Compiling to UMD
Minifying UMD bundle
Side effects in initialization of unused variable ez [0:80,12]
Dropping side-effect-free statement [0:2738,17]
Dropping side-effect-free statement [0:3243,21]
Dropping side-effect-free statement [0:4926,17]
Dropping side-effect-free statement [0:6090,21]
Dropping duplicated definition of variable gV [0:6518,16]
Dropping duplicated definition of variable fV [0:6525,17]
Dropping unreachable code [0:15959,0]
Declarations in unreachable code! [0:15959,0]
Dropping unreachable code [0:17346,0]
Declarations in unreachable code! [0:17346,0]
Side effects in initialization of unused variable sya [0:19408,53]
Side effects in initialization of unused variable tya [0:19408,89]
Side effects in initialization of unused variable uya [0:19408,131]
Dropping duplicated definition of variable nFa [0:21288,17]
Side effects in initialization of unused variable V [0:813,4]
Side effects in initialization of unused variable W [0:814,4]
Side effects in initialization of unused variable fa [0:1128,4]
Side effects in initialization of unused variable ga [0:1129,4]
Side effects in initialization of unused variable ha [0:1130,4]
Dropping duplicated definition of variable f [0:1537,4]
Side effects in initialization of unused variable Ab [0:2648,4]
Side effects in initialization of unused variable Bb [0:2649,4]
Side effects in initialization of unused variable Cb [0:2650,4]
Side effects in initialization of unused variable Ip [0:15332,4]
Side effects in initialization of unused variable ev [0:19436,4]
Side effects in initialization of unused variable fv [0:19437,4]
Side effects in initialization of unused variable $x [0:21698,4]
Side effects in initialization of unused variable ly [0:22074,4]
Side effects in initialization of unused variable my [0:22075,4]

BUILD ERROR
ENOENT: no such file or directory, open 'C:\Users\xxxxxx\node_modules\src\util\root.ts'
Error: ENOENT: no such file or directory, open 'C:\Users\xxxxxx\node_modules\src\util\root.ts'

npm ERR! code ELIFECYCLE
npm ERR! errno 111
npm ERR! xxx@1.0.0 packagr: `ng-packagr -p package.json`
npm ERR! Exit status 111
npm ERR!
npm ERR! Failed at the xxx@1.0.0 packagr script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\xx\AppData\Roaming\npm-cache\_logs\2018-04-09T11_24_23_994Z-debug.log

Version Information

npm : 5.6.0 node: 8.9.4

+-- @angular/cli@1.4.10
+-- @angular/common@4.4.6
+-- @angular/compiler@4.4.6
+-- @angular/compiler-cli@4.4.6
+-- @angular/core@4.4.6
+-- @angular/forms@4.4.6
+-- @angular/http@4.4.6
+-- @angular/language-service@4.4.6
+-- @angular/platform-browser@4.4.6
+-- @angular/platform-browser-dynamic@4.4.6
+-- @angular/router@4.4.6
+-- @compodoc/compodoc@1.0.6
+-- @types/jasmine@2.5.54
+-- @types/jasminewd2@2.0.3
+-- @types/node@6.0.104
+-- codelyzer@3.1.2
+-- core-js@2.5.5
+-- jasmine-core@2.6.4
+-- jasmine-spec-reporter@4.1.1
+-- karma@1.7.1
+-- karma-chrome-launcher@2.1.1
+-- karma-cli@1.0.1
+-- karma-coverage-istanbul-reporter@1.2.1
+-- karma-jasmine@1.1.1
+-- karma-jasmine-html-reporter@0.2.2
+-- ng-packagr@1.7.0
+-- protractor@5.3.0
+-- rollup-plugin-commonjs@8.3.0
+-- rxjs@5.5.8
+-- ts-node@3.2.2
+-- tslint@5.3.2
+-- typescript@2.3.4
`-- zone.js@0.8.26

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:9
  • Comments:18 (1 by maintainers)

github_iconTop GitHub Comments

11reactions
ninjadqcommented, Apr 10, 2018

I tried npm install uglify-js@3.3.18 , but the problem seems still exists.

10reactions
dmenesescommented, Apr 9, 2018

Seems that the culprit is: uglify-js. I run:

npm install uglify-js@3.3.18

to downgrade uglify-js and try to build again and worked.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to resolve Nodejs: Error: ENOENT: no such file or directory
Your app is expecting to find a file at /home/embah/node/nodeapp/config/config.json but that file does not exist (which is what ENOENT ...
Read more >
[BUG] ENOENT: no such file or directory, when attempting to ...
I run my tests with npx playwright test tests/upload-sxml.spec.ts from the root of the e2e folder. Can anyone see what I possible can...
Read more >
Bug: ORA-06522: (path)\st_shapelib.dll: cannot open shared ...
dll: cannot open shared object file: No such file or directory. Description. When accessing the Spatial Type for Oracle using SQL, the following...
Read more >
1978207 – Certmonger on overcloud nodes complains about ...
txt": No such file or directory. I have tried to check certmonger code and find related bugs. It looks like this error is...
Read more >
Filing useful bug reports - Apache Software Foundation
This is a page that we hope will help you file useful bug reports. ... ts/.libs/libtsutil.so: open failed: No such file or directory...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found