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.

Error while packaging a JavaScript file not in a subfolder

See original GitHub issue

Im getting this error after I package my app and then try to run it:

Uncaught Exception:
Error: Asked for ...Path/App.app/Contents/Resources/app/main.js but it was not precompiled!
    at FileChangedCache.getHashForPathSync (...Path/out/App-darwin-x64/App.app/Contents/Resources/app/node_modules/electron-compile/lib/file-change-cache.js:249:15)

Any idea onto why this is happening?

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:14 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
MarshallOfSoundcommented, Jan 5, 2017

@AhadCove Your JS files must be inside a directory (not just sitting in the top level of your app). I.e. If you move main.js to be somewhere like src/main.js and update your package.json accordingly the packaged version will work.

/cc @malept We should probably catch this issue ourselves

0reactions
ahadcovecommented, Jan 5, 2017

Sadly, it’s not. I’m going to keep picking away at it though. I definitely like the idea of forge though so I may be back when I get this figured out. Thank you for everything

Read more comments on GitHub >

github_iconTop Results From Across the Web

Error while packaging a JavaScript file not in a subfolder #66
Im getting this error after I package my app and then try to run it: Uncaught Exception: Error: Asked for .
Read more >
Cannot load a js file from a different subfolder - Stack Overflow
The rest of the files load as expected. I am using "ejs": "^3.1.6", "ejs-mate": "^3.0.0", "express" ...
Read more >
Working with folders in Node.js
The Node.js fs core module provides many handy methods you can use to work with folders. Check if a folder exists. Use fs.access()...
Read more >
Javascript file is not working with HTML - Get Started - SitePoint
Hello I am fairly new to web design and have been having a lot of trouble sourcing Js files into my html web...
Read more >
Live issues not working in Xcode in subfolders of `Sources ...
In all my Swift packages where I use subfolders in the Sources/MyProject folder, Xcode does show errors immediately for all top-level files ......
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