Quantcast
Channel: JavaScriptMVC Forum
Viewing all articles
Browse latest Browse all 3491

"failed to open file" error on steal build

$
0
0
I've added the i18next library to do some i18n stuff.  Here's my init function.

  1. i18n.init({
  2. lng: 'en',
  3. useCookie: false,
  4. fallbackLng: 'en',
  5. ns: 'resource',
  6. getAsync: false,
  7. resGetPath: './exo/locales/__lng__/__ns__.json'
  8. }, function(t) {
  9. });

The i18next library will make an ajax call to http://<server>/exo/locales/en/resource.json.  Everything works great!

But, I get the following error when I try to build the production files using Steal.

  1. failed to open file  file:////Users/ecarino/p4depot/EricsMacBookAir_ManhattanClient/web/steal/rhino/exo/locales/en/resource.json   JavaException: java.io.FileNotFoundException: /Users/ecarino/p4depot/EricsMacBookAir_ManhattanClient/web/steal/rhino/exo/locales/en/resource.json (No such file or directory) 


Any ideas?  I found this stackoverflow article on the same exact issue.  Their solution is to modify the url path to be an absolute url, or to add a check of "steal.isRhino" on all ajax calls.  I have verified those work, but those aren't elegant solutions.

What should I do?

Viewing all articles
Browse latest Browse all 3491

Trending Articles