[ https://issues.apache.org/jira/browse/CB-6428?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14364230#comment-14364230 ]
Jacob G edited comment on CB-6428 at 3/17/15 1:08 AM: ------------------------------------------------------ That's exactly the error I'm getting also when downloading to directory (cordova.file.dataDirectory + 'wwwTmp/'). This is my log: {noformat} 03-16 20:38:33.961 31560-31859/com.fareclock.tc E/FileTransfer﹕ {"code":3,"source":"https:\/\/localdev.f.com\/static\/tc\/resources\/css\/app.css","target":"file:\/\/\/data\/data\/com.f.tc\/files\/wwwTmp\/resources\/css\/app.css","http_status":200,"exception":"Attempt to read from field 'java.lang.String org.apache.cordova.file.LocalFilesystemURL.path' on a null object reference"} java.lang.NullPointerException: Attempt to read from field 'java.lang.String org.apache.cordova.file.LocalFilesystemURL.path' on a null object reference at org.apache.cordova.file.Filesystem.makeEntryForURL(Filesystem.java:56) at org.apache.cordova.file.Filesystem.makeEntryForNativeUri(Filesystem.java:91) at org.apache.cordova.file.Filesystem.makeEntryForFile(Filesystem.java:99) at org.apache.cordova.file.FileUtils.getEntryForFile(FileUtils.java:895) at org.apache.cordova.filetransfer.FileTransfer$4.run(FileTransfer.java:902) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) at java.lang.Thread.run(Thread.java:818) {noformat} The error code is 3 = FileTransferError.CONNECTION_ERR. I have to dig into this further to find the bug. was (Author: jacobgu): That's exactly the error I'm getting also when downloading to directory (cordova.file.dataDirectory + 'wwwTmp/'). This is my log: 03-16 20:38:33.961 31560-31859/com.fareclock.tc E/FileTransfer﹕ {"code":3,"source":"https:\/\/localdev.f.com\/static\/tc\/resources\/css\/app.css","target":"file:\/\/\/data\/data\/com.f.tc\/files\/wwwTmp\/resources\/css\/app.css","http_status":200,"exception":"Attempt to read from field 'java.lang.String org.apache.cordova.file.LocalFilesystemURL.path' on a null object reference"} java.lang.NullPointerException: Attempt to read from field 'java.lang.String org.apache.cordova.file.LocalFilesystemURL.path' on a null object reference at org.apache.cordova.file.Filesystem.makeEntryForURL(Filesystem.java:56) at org.apache.cordova.file.Filesystem.makeEntryForNativeUri(Filesystem.java:91) at org.apache.cordova.file.Filesystem.makeEntryForFile(Filesystem.java:99) at org.apache.cordova.file.FileUtils.getEntryForFile(FileUtils.java:895) at org.apache.cordova.filetransfer.FileTransfer$4.run(FileTransfer.java:902) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) at java.lang.Thread.run(Thread.java:818) The error code is 3 = FileTransferError.CONNECTION_ERR. I have to dig into this further to find the bug. > Unable to read android_asset directory through File API > ------------------------------------------------------- > > Key: CB-6428 > URL: https://issues.apache.org/jira/browse/CB-6428 > Project: Apache Cordova > Issue Type: Bug > Components: Plugin File > Affects Versions: 3.3.0 > Environment: Android 4.4.2 / Samsung Galaxy S4 > Reporter: Matt Grande > Assignee: Andrew Grieve > Labels: android, file > > Attempting to read the 'android_asset' folder through the File API results in > Error Code 5 (FileError.ENCODING_ERR). I've tried accessing via > resolveLocalFileSystemURL, and by creating a directory reader and calling > readEntries(). > > window.resolveLocalFileSystemURL('file:///android_asset/www/my_asset_folder', > success, fail); > var sourceDir = new DirectoryEntry( { fullPath: > 'file:///android_asset/www/my_asset_folder' } ); > var reader = sourceDir.createReader(); > reader.readEntries(success, fail); > (I have also tried with the URLs being '/android_asset/www/my_asset_folder'; > same result) -- This message was sent by Atlassian JIRA (v6.3.4#6332) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@cordova.apache.org For additional commands, e-mail: issues-h...@cordova.apache.org