java.io.FileNotFoundException: Resources/uidata.js

Appcelerator JIRA | Eduardo Gomez | 5 years ago
  1. 0

    h6.Problem java.io.FileNotFoundException thrown when upper case in the .js file names and in the images folder name (under Windows). It seems like when running the simulator under windows it is case insensitive whereas it is case sensitive on the device. h6.Steps to reproduce Trying to load Abc.js when the filename it might be abc.js h6.Work around Use lower case filenames only (to get it working as in the simulator). h6.Console logs {code} 05-10 17:01:44.130: I/TiRootActivity(2147): (main) [0,0] checkpoint, on root activity create, savedInstanceState: null 05-10 17:01:44.840: W/TiApplication(2147): (KrollRuntimeThread) [708,708] Registering module with name already in use. 05-10 17:01:44.840: E/TiApplication(2147): (KrollRuntimeThread) [0,708] APP PROXY: ti.modules.titanium.app.AppModule@4056ee58 05-10 17:01:44.870: W/V8Object(2147): Runtime disposed, cannot set property 'userAgent' 05-10 17:01:45.060: E/TiAssetHelper(2147): Error while reading asset "Resources/uidata.js": 05-10 17:01:45.060: E/TiAssetHelper(2147): java.io.FileNotFoundException: Resources/uidata.js 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.content.res.AssetManager.openAsset(Native Method) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.content.res.AssetManager.open(AssetManager.java:337) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.content.res.AssetManager.open(AssetManager.java:311) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.util.KrollAssetHelper.readAsset(KrollAssetHelper.java:77) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.runtime.v8.V8Runtime.nativeRunModule(Native Method) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.runtime.v8.V8Runtime.doRunModule(V8Runtime.java:134) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.KrollRuntime.handleMessage(KrollRuntime.java:267) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.runtime.v8.V8Runtime.handleMessage(V8Runtime.java:160) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.os.Handler.dispatchMessage(Handler.java:95) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.os.Looper.loop(Looper.java:130) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:104) 05-10 17:01:45.140: D/dalvikvm(2147): GC_CONCURRENT freed 582K, 45% free 3958K/7111K, external 877K/1389K, paused 4ms+6ms 05-10 17:01:45.410: D/dalvikvm(2147): GC_EXTERNAL_ALLOC freed 294K, 48% free 3726K/7111K, external 523K/1022K, paused 50ms 05-10 17:01:45.520: I/TiRootActivity(2147): (main) [0,0] checkpoint, on root activity resume. activity = com.app.cg.CardguardActivity@4064b240 05-10 17:01:45.700: W/TiDrawableReference(2147): (main) [189,189] Bitmap bounds could not be determined. If bitmap is loaded, it won't be scaled. 05-10 17:01:45.710: W/TiDrawableReference(2147): (main) [1,190] Could not open stream to get bitmap 05-10 17:01:45.890: D/TiUIView(2147): (main) [187,377] Nativeview is null 05-10 17:01:45.910: W/TiDrawableReference(2147): (main) [14,391] Bitmap bounds could not be determined. If bitmap is loaded, it won't be scaled. 05-10 17:01:45.910: W/TiDrawableReference(2147): (main) [0,391] Could not open stream to get bitmap 05-10 17:01:45.940: D/TiUIView(2147): (main) [30,421] Nativeview is null {code} h6.Further info This jira ticket isn't necessarily a bug but a report to address it as there is no way to avoid this as the java.io.File API is system-dependent. http://developer.android.com/reference/java/io/File.html ---- h6. DOCUMENTATION ACTION ---- Documentation needs to explicitly state that transitioning from case-insensitive filesystems (FAT32, NTFS, HFS+) to case-sensitive filesystems (Android, possibly MW, possibly BB) may mean that certain files "may not be found". The issue is that the file name referenced in the source does not match the case of the file on the filesystem.

    Appcelerator JIRA | 5 years ago | Eduardo Gomez
    java.io.FileNotFoundException: Resources/uidata.js
  2. 0

    h6.Problem java.io.FileNotFoundException thrown when upper case in the .js file names and in the images folder name (under Windows). It seems like when running the simulator under windows it is case insensitive whereas it is case sensitive on the device. h6.Steps to reproduce Trying to load Abc.js when the filename it might be abc.js h6.Work around Use lower case filenames only (to get it working as in the simulator). h6.Console logs {code} 05-10 17:01:44.130: I/TiRootActivity(2147): (main) [0,0] checkpoint, on root activity create, savedInstanceState: null 05-10 17:01:44.840: W/TiApplication(2147): (KrollRuntimeThread) [708,708] Registering module with name already in use. 05-10 17:01:44.840: E/TiApplication(2147): (KrollRuntimeThread) [0,708] APP PROXY: ti.modules.titanium.app.AppModule@4056ee58 05-10 17:01:44.870: W/V8Object(2147): Runtime disposed, cannot set property 'userAgent' 05-10 17:01:45.060: E/TiAssetHelper(2147): Error while reading asset "Resources/uidata.js": 05-10 17:01:45.060: E/TiAssetHelper(2147): java.io.FileNotFoundException: Resources/uidata.js 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.content.res.AssetManager.openAsset(Native Method) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.content.res.AssetManager.open(AssetManager.java:337) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.content.res.AssetManager.open(AssetManager.java:311) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.util.KrollAssetHelper.readAsset(KrollAssetHelper.java:77) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.runtime.v8.V8Runtime.nativeRunModule(Native Method) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.runtime.v8.V8Runtime.doRunModule(V8Runtime.java:134) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.KrollRuntime.handleMessage(KrollRuntime.java:267) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.runtime.v8.V8Runtime.handleMessage(V8Runtime.java:160) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.os.Handler.dispatchMessage(Handler.java:95) 05-10 17:01:45.060: E/TiAssetHelper(2147): at android.os.Looper.loop(Looper.java:130) 05-10 17:01:45.060: E/TiAssetHelper(2147): at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:104) 05-10 17:01:45.140: D/dalvikvm(2147): GC_CONCURRENT freed 582K, 45% free 3958K/7111K, external 877K/1389K, paused 4ms+6ms 05-10 17:01:45.410: D/dalvikvm(2147): GC_EXTERNAL_ALLOC freed 294K, 48% free 3726K/7111K, external 523K/1022K, paused 50ms 05-10 17:01:45.520: I/TiRootActivity(2147): (main) [0,0] checkpoint, on root activity resume. activity = com.app.cg.CardguardActivity@4064b240 05-10 17:01:45.700: W/TiDrawableReference(2147): (main) [189,189] Bitmap bounds could not be determined. If bitmap is loaded, it won't be scaled. 05-10 17:01:45.710: W/TiDrawableReference(2147): (main) [1,190] Could not open stream to get bitmap 05-10 17:01:45.890: D/TiUIView(2147): (main) [187,377] Nativeview is null 05-10 17:01:45.910: W/TiDrawableReference(2147): (main) [14,391] Bitmap bounds could not be determined. If bitmap is loaded, it won't be scaled. 05-10 17:01:45.910: W/TiDrawableReference(2147): (main) [0,391] Could not open stream to get bitmap 05-10 17:01:45.940: D/TiUIView(2147): (main) [30,421] Nativeview is null {code} h6.Further info This jira ticket isn't necessarily a bug but a report to address it as there is no way to avoid this as the java.io.File API is system-dependent. http://developer.android.com/reference/java/io/File.html ---- h6. DOCUMENTATION ACTION ---- Documentation needs to explicitly state that transitioning from case-insensitive filesystems (FAT32, NTFS, HFS+) to case-sensitive filesystems (Android, possibly MW, possibly BB) may mean that certain files "may not be found". The issue is that the file name referenced in the source does not match the case of the file on the filesystem.

    Appcelerator JIRA | 5 years ago | Eduardo Gomez
    java.io.FileNotFoundException: Resources/uidata.js
  3. 0

    [Android] Service not working

    GitHub | 2 years ago | rotorgames
    java.io.FileNotFoundException: appdata-private://FindMe/services/boot.js
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    h2.Problem When a window with a url property is created from within a CommonJS unit, where the CommonJS unit resides in a subdirectory, includes that are within the window's unit (specified in the url property) used to be (2.1.4 and earlier) treated as relative to the Resources directory. Now (3.0.2.GA) it is treated as relative to the directory of the CommonJS file. If the CommonJS file is in a subdirectory, an error (APP PROXY: ti.modules.titanium.app.AppModule) is generated. This breaks a lot of existing code. Note that in the error message, the "ui" subdirectory is doubled: Error while reading asset "Resources/ui/ui/MyInclude.js" Works in 2.1.4.GA Broken in 3.0.2.GA h2.Testcase Note in this example that the "MakeWin.js" and "MyInclude.js" files are in a "ui" subdirectory. {panel:title=app.js} {code} Ti.UI.setBackgroundColor('#000'); require('ui/MakeWin'); {code} {panel} {panel:title=ui/MakeWin.js} {code} var win1=Ti.UI.createWindow({ title:'Window 1', backgroundColor:'#fff', url:'win1.js' }); win1.open(); {code} {panel} {panel:title=win1.js} {code} Ti.include('ui/MyInclude.js'); var winOne = Ti.UI.currentWindow; var label1 = Ti.UI.createLabel({ color:'#999', text:'I am Window '+MyValue, font:{fontSize:20,fontFamily:'Helvetica Neue'}, textAlign:'center', width:'auto' }); winOne.add(label1); {code} {panel} {panel:title=ui/MyInclude.js} {code} var MyValue=5; {code} {panel} h2.Error Log: [ERROR][TiApplication( 386)] (KrollRuntimeThread) [1417,1417] APP PROXY: ti.modules.titanium.app.AppModule@43e51900 [ERROR][TiAssetHelper( 386)] Error while reading asset "Resources/ui/ui/MyInclude.js": [ERROR][TiAssetHelper( 386)] java.io.FileNotFoundException: Resources/ui/ui/MyInclude.js [ERROR][TiAssetHelper( 386)] at android.content.res.AssetManager.openAsset(Native Method) [ERROR][TiAssetHelper( 386)] at android.content.res.AssetManager.open(AssetManager.java:313) [ERROR][TiAssetHelper( 386)] at android.content.res.AssetManager.open(AssetManager.java:287) [ERROR][TiAssetHelper( 386)] at org.appcelerator.kroll.util.KrollAssetHelper.readAsset(KrollAssetHelper.java:77) [ERROR][TiAssetHelper( 386)] at org.appcelerator.kroll.runtime.v8.V8Runtime.nativeRunModule(Native Method) [ERROR][TiAssetHelper( 386)] at org.appcelerator.kroll.runtime.v8.V8Runtime.doRunModule(V8Runtime.java:140) [ERROR][TiAssetHelper( 386)] at org.appcelerator.kroll.KrollRuntime.handleMessage(KrollRuntime.java:289) [ERROR][TiAssetHelper( 386)] at org.appcelerator.kroll.runtime.v8.V8Runtime.handleMessage(V8Runtime.java:166) [ERROR][TiAssetHelper( 386)] at android.os.Handler.dispatchMessage(Handler.java:95) [ERROR][TiAssetHelper( 386)] at android.os.Looper.loop(Looper.java:123) [ERROR][TiAssetHelper( 386)] at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:112)

    Appcelerator JIRA | 4 years ago | Shawn Lipscomb
    java.io.FileNotFoundException: Resources/ui/ui/MyInclude.js
  6. 0

    h4.Problem When a window is created with the *url* property, that url used to be (2.1.2 and earlier) treated as relative to the Resources directory. Now (2.2.0.v20120904164912) it is treated as relative to the directory of the calling js file. If the calling js file is in a subdirectory, an error (java.io.FileNotFoundException) is generated. This is going to break a lot of existing code. Works in 2.1.2 Broken in 2.2.0.v20120904164912 h4.Testcase Note in this example that the "loader.js" file is in a "ui" subdirectory. {panel:title=app.js} {code} Ti.UI.setBackgroundColor('#000'); Ti.include('ui/loader.js'); {code} {panel} {panel:title=ui/loader.js} {code} var win1=Ti.UI.createWindow({ title:'Window 1', backgroundColor:'#fff', url:'win1.js' }); win1.open(); {code} {panel} {panel:title=win1.js} {code} var winOne = Ti.UI.currentWindow; var label1 = Ti.UI.createLabel({ color:'#999', text:'I am Window 1', font:{fontSize:20,fontFamily:'Helvetica Neue'}, textAlign:'center', width:'auto' }); winOne.add(label1); {code} {panel} h4.Error log ... [ERROR][TiAssetHelper( 345)] Error while reading asset "Resources/ui/win1.js": [ERROR][TiAssetHelper( 345)] java.io.FileNotFoundException: Resources/ui/win1.js [ERROR][TiAssetHelper( 345)] at android.content.res.AssetManager.openAsset(Native Method) [ERROR][TiAssetHelper( 345)] at android.content.res.AssetManager.open(AssetManager.java:313) [ERROR][TiAssetHelper( 345)] at android.content.res.AssetManager.open(AssetManager.java:287) [ERROR][TiAssetHelper( 345)] at org.appcelerator.kroll.util.KrollAssetHelper.readAsset(KrollAssetHelper.java:77) [ERROR][TiAssetHelper( 345)] at org.appcelerator.kroll.runtime.v8.V8Runtime.nativeRunModule(Native Method) [ERROR][TiAssetHelper( 345)] at org.appcelerator.kroll.runtime.v8.V8Runtime.doRunModule(V8Runtime.java:140) [ERROR][TiAssetHelper( 345)] at org.appcelerator.kroll.KrollRuntime.handleMessage(KrollRuntime.java:284) [ERROR][TiAssetHelper( 345)] at org.appcelerator.kroll.runtime.v8.V8Runtime.handleMessage(V8Runtime.java:166) [ERROR][TiAssetHelper( 345)] at android.os.Handler.dispatchMessage(Handler.java:95) [ERROR][TiAssetHelper( 345)] at android.os.Looper.loop(Looper.java:123) [ERROR][TiAssetHelper( 345)] at org.appcelerator.kroll.KrollRuntime$KrollRuntimeThread.run(KrollRuntime.java:108) {panel}

    Appcelerator JIRA | 4 years ago | Shawn Lipscomb
    java.io.FileNotFoundException: Resources/ui/win1.js

  1. malhobayyeb 1 times, last 2 weeks ago
  2. Alexandru Popa 6 times, last 3 weeks ago
  3. Aria Pahlavan 1310 times, last 2 weeks ago
  4. bluebunnty 59 times, last 2 weeks ago
  5. iridic 3 times, last 1 month ago
31 more registered users
1 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.io.FileNotFoundException

    Resources/uidata.js

    at android.content.res.AssetManager.openAsset()
  2. Android Platform
    AssetManager.open
    1. android.content.res.AssetManager.openAsset(Native Method)
    2. android.content.res.AssetManager.open(AssetManager.java:337)
    3. android.content.res.AssetManager.open(AssetManager.java:311)
    3 frames
  3. org.appcelerator.kroll
    V8Runtime.handleMessage
    1. org.appcelerator.kroll.util.KrollAssetHelper.readAsset(KrollAssetHelper.java:77)
    2. org.appcelerator.kroll.runtime.v8.V8Runtime.nativeRunModule(Native Method)
    3. org.appcelerator.kroll.runtime.v8.V8Runtime.doRunModule(V8Runtime.java:134)
    4. org.appcelerator.kroll.KrollRuntime.handleMessage(KrollRuntime.java:267)
    5. org.appcelerator.kroll.runtime.v8.V8Runtime.handleMessage(V8Runtime.java:160)
    5 frames
  4. Android Platform
    Looper.loop
    1. android.os.Handler.dispatchMessage(Handler.java:95)
    2. android.os.Looper.loop(Looper.java:130)
    2 frames