{"action":"created","comment":{"url":"https://api.github.com/repos/dimagi/commcare-android/pulls/comments/70894058","id":70894058,"diff_hunk":"@@ -62,7 +63,12 @@ public FormRecordToFileTask(Context c, String formStoragePath) {\n      * Return an int status code from FormUploadUtil corresponding to the outcome of the transfer\r\n      */\r\n     private long copyFileInstanceFromStorage(File formRecordFolder, SecretKeySpec decryptionKey) {\r\n-        File[] files = formRecordFolder.listFiles();\r\n+        File[] files = formRecordFolder.listFiles(new FileFilter() {\r\n+            @Override\r\n+            public boolean accept(File file) {\r\n+                return file.isFile();\r","path":"app/src/org/commcare/tasks/FormRecordToFileTask.java","position":16,"original_position":16,"commit_id":"fe91452064189695d64164209f3fcbffb024fd00","original_commit_id":"fe91452064189695d64164209f3fcbffb024fd00","user":{"login":"wpride","id":2293064,"avatar_url":"https://avatars.githubusercontent.com/u/2293064?v=3","gravatar_id":"","url":"https://api.github.com/users/wpride","html_url":"https://github.com/wpride","followers_url":"https://api.github.com/users/wpride/followers","following_url":"https://api.github.com/users/wpride/following{/other_user}","gists_url":"https://api.github.com/users/wpride/gists{/gist_id}","starred_url":"https://api.github.com/users/wpride/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wpride/subscriptions","organizations_url":"https://api.github.com/users/wpride/orgs","repos_url":"https://api.github.com/users/wpride/repos","events_url":"https://api.github.com/users/wpride/events{/privacy}","received_events_url":"https://api.github.com/users/wpride/received_events","type":"User","site_admin":false},"body":"also filters out folders","created_at":"2016-07-14T22:15:56Z","updated_at":"2016-07-14T22:15:56Z","html_url":"https://github.com/dimagi/commcare-android/pull/1390#discussion_r70894058","pull_request_url":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390","_links":{"self":{"href":"https://api.github.com/repos/dimagi/commcare-android/pulls/comments/70894058"},"html":{"href":"https://github.com/dimagi/commcare-android/pull/1390#discussion_r70894058"},"pull_request":{"href":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390"}}},"pull_request":{"url":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390","id":77534461,"html_url":"https://github.com/dimagi/commcare-android/pull/1390","diff_url":"https://github.com/dimagi/commcare-android/pull/1390.diff","patch_url":"https://github.com/dimagi/commcare-android/pull/1390.patch","issue_url":"https://api.github.com/repos/dimagi/commcare-android/issues/1390","number":1390,"state":"open","locked":false,"title":"Wsp/sd fix 228","user":{"login":"wpride","id":2293064,"avatar_url":"https://avatars.githubusercontent.com/u/2293064?v=3","gravatar_id":"","url":"https://api.github.com/users/wpride","html_url":"https://github.com/wpride","followers_url":"https://api.github.com/users/wpride/followers","following_url":"https://api.github.com/users/wpride/following{/other_user}","gists_url":"https://api.github.com/users/wpride/gists{/gist_id}","starred_url":"https://api.github.com/users/wpride/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wpride/subscriptions","organizations_url":"https://api.github.com/users/wpride/orgs","repos_url":"https://api.github.com/users/wpride/repos","events_url":"https://api.github.com/users/wpride/events{/privacy}","received_events_url":"https://api.github.com/users/wpride/received_events","type":"User","site_admin":false},"body":"Two bugs:\r\nFirst, when there was a subdirectory in the form instance directory, the activity would fail here but create the impression that it was successful. No potential for data loss, but misleading and non functional. The solution was the filter folders out before performing the copy.\r\n\r\nSecond, the name of files to be zipped was reversed so instead of folder/name it would be name/folder. https://github.com/dimagi/commcare-android/pull/1386/files#diff-af6d6e22c0533d597d5358277debfedeR100. Not clear why this sometimes works and sometimes does not. Investigating further. Should be hotfixed ASA","created_at":"2016-07-14T22:08:33Z","updated_at":"2016-07-14T22:15:56Z","closed_at":null,"merged_at":null,"merge_commit_sha":"22cfce44fb89e66e9b54fc4090c1b0559645a2e3","assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/dimagi/commcare-android/milestones/8","html_url":"https://github.com/dimagi/commcare-android/milestones/commcare_2.28","labels_url":"https://api.github.com/repos/dimagi/commcare-android/milestones/8/labels","id":1652574,"number":8,"title":"commcare_2.28","description":null,"creator":{"login":"phillipm","id":94817,"avatar_url":"https://avatars.githubusercontent.com/u/94817?v=3","gravatar_id":"","url":"https://api.github.com/users/phillipm","html_url":"https://github.com/phillipm","followers_url":"https://api.github.com/users/phillipm/followers","following_url":"https://api.github.com/users/phillipm/following{/other_user}","gists_url":"https://api.github.com/users/phillipm/gists{/gist_id}","starred_url":"https://api.github.com/users/phillipm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/phillipm/subscriptions","organizations_url":"https://api.github.com/users/phillipm/orgs","repos_url":"https://api.github.com/users/phillipm/repos","events_url":"https://api.github.com/users/phillipm/events{/privacy}","received_events_url":"https://api.github.com/users/phillipm/received_events","type":"User","site_admin":false},"open_issues":1,"closed_issues":133,"state":"open","created_at":"2016-03-18T01:54:03Z","updated_at":"2016-07-14T22:08:36Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390/commits","review_comments_url":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390/comments","review_comment_url":"https://api.github.com/repos/dimagi/commcare-android/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dimagi/commcare-android/issues/1390/comments","statuses_url":"https://api.github.com/repos/dimagi/commcare-android/statuses/fe91452064189695d64164209f3fcbffb024fd00","head":{"label":"dimagi:wsp/sd-fix-228","ref":"wsp/sd-fix-228","sha":"fe91452064189695d64164209f3fcbffb024fd00","user":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"repo":{"id":20939877,"name":"commcare-android","full_name":"dimagi/commcare-android","owner":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dimagi/commcare-android","description":"The best open source form management tool in town","fork":false,"url":"https://api.github.com/repos/dimagi/commcare-android","forks_url":"https://api.github.com/repos/dimagi/commcare-android/forks","keys_url":"https://api.github.com/repos/dimagi/commcare-android/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dimagi/commcare-android/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dimagi/commcare-android/teams","hooks_url":"https://api.github.com/repos/dimagi/commcare-android/hooks","issue_events_url":"https://api.github.com/repos/dimagi/commcare-android/issues/events{/number}","events_url":"https://api.github.com/repos/dimagi/commcare-android/events","assignees_url":"https://api.github.com/repos/dimagi/commcare-android/assignees{/user}","branches_url":"https://api.github.com/repos/dimagi/commcare-android/branches{/branch}","tags_url":"https://api.github.com/repos/dimagi/commcare-android/tags","blobs_url":"https://api.github.com/repos/dimagi/commcare-android/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dimagi/commcare-android/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dimagi/commcare-android/git/refs{/sha}","trees_url":"https://api.github.com/repos/dimagi/commcare-android/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dimagi/commcare-android/statuses/{sha}","languages_url":"https://api.github.com/repos/dimagi/commcare-android/languages","stargazers_url":"https://api.github.com/repos/dimagi/commcare-android/stargazers","contributors_url":"https://api.github.com/repos/dimagi/commcare-android/contributors","subscribers_url":"https://api.github.com/repos/dimagi/commcare-android/subscribers","subscription_url":"https://api.github.com/repos/dimagi/commcare-android/subscription","commits_url":"https://api.github.com/repos/dimagi/commcare-android/commits{/sha}","git_commits_url":"https://api.github.com/repos/dimagi/commcare-android/git/commits{/sha}","comments_url":"https://api.github.com/repos/dimagi/commcare-android/comments{/number}","issue_comment_url":"https://api.github.com/repos/dimagi/commcare-android/issues/comments{/number}","contents_url":"https://api.github.com/repos/dimagi/commcare-android/contents/{+path}","compare_url":"https://api.github.com/repos/dimagi/commcare-android/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dimagi/commcare-android/merges","archive_url":"https://api.github.com/repos/dimagi/commcare-android/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dimagi/commcare-android/downloads","issues_url":"https://api.github.com/repos/dimagi/commcare-android/issues{/number}","pulls_url":"https://api.github.com/repos/dimagi/commcare-android/pulls{/number}","milestones_url":"https://api.github.com/repos/dimagi/commcare-android/milestones{/number}","notifications_url":"https://api.github.com/repos/dimagi/commcare-android/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dimagi/commcare-android/labels{/name}","releases_url":"https://api.github.com/repos/dimagi/commcare-android/releases{/id}","deployments_url":"https://api.github.com/repos/dimagi/commcare-android/deployments","created_at":"2014-06-17T21:17:26Z","updated_at":"2016-06-26T22:34:57Z","pushed_at":"2016-07-14T22:08:33Z","git_url":"git://github.com/dimagi/commcare-android.git","ssh_url":"git@github.com:dimagi/commcare-android.git","clone_url":"https://github.com/dimagi/commcare-android.git","svn_url":"https://github.com/dimagi/commcare-android","homepage":"https://play.google.com/store/apps/details?id=org.commcare.dalvik&hl=en","size":77372,"stargazers_count":9,"watchers_count":9,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":20,"forks":10,"open_issues":20,"watchers":9,"default_branch":"master"}},"base":{"label":"dimagi:commcare_2.28","ref":"commcare_2.28","sha":"632c0ef2051c1738ade09320b8a5319a427af03d","user":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"repo":{"id":20939877,"name":"commcare-android","full_name":"dimagi/commcare-android","owner":{"login":"dimagi","id":94514,"avatar_url":"https://avatars.githubusercontent.com/u/94514?v=3","gravatar_id":"","url":"https://api.github.com/users/dimagi","html_url":"https://github.com/dimagi","followers_url":"https://api.github.com/users/dimagi/followers","following_url":"https://api.github.com/users/dimagi/following{/other_user}","gists_url":"https://api.github.com/users/dimagi/gists{/gist_id}","starred_url":"https://api.github.com/users/dimagi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dimagi/subscriptions","organizations_url":"https://api.github.com/users/dimagi/orgs","repos_url":"https://api.github.com/users/dimagi/repos","events_url":"https://api.github.com/users/dimagi/events{/privacy}","received_events_url":"https://api.github.com/users/dimagi/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dimagi/commcare-android","description":"The best open source form management tool in town","fork":false,"url":"https://api.github.com/repos/dimagi/commcare-android","forks_url":"https://api.github.com/repos/dimagi/commcare-android/forks","keys_url":"https://api.github.com/repos/dimagi/commcare-android/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dimagi/commcare-android/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dimagi/commcare-android/teams","hooks_url":"https://api.github.com/repos/dimagi/commcare-android/hooks","issue_events_url":"https://api.github.com/repos/dimagi/commcare-android/issues/events{/number}","events_url":"https://api.github.com/repos/dimagi/commcare-android/events","assignees_url":"https://api.github.com/repos/dimagi/commcare-android/assignees{/user}","branches_url":"https://api.github.com/repos/dimagi/commcare-android/branches{/branch}","tags_url":"https://api.github.com/repos/dimagi/commcare-android/tags","blobs_url":"https://api.github.com/repos/dimagi/commcare-android/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dimagi/commcare-android/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dimagi/commcare-android/git/refs{/sha}","trees_url":"https://api.github.com/repos/dimagi/commcare-android/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dimagi/commcare-android/statuses/{sha}","languages_url":"https://api.github.com/repos/dimagi/commcare-android/languages","stargazers_url":"https://api.github.com/repos/dimagi/commcare-android/stargazers","contributors_url":"https://api.github.com/repos/dimagi/commcare-android/contributors","subscribers_url":"https://api.github.com/repos/dimagi/commcare-android/subscribers","subscription_url":"https://api.github.com/repos/dimagi/commcare-android/subscription","commits_url":"https://api.github.com/repos/dimagi/commcare-android/commits{/sha}","git_commits_url":"https://api.github.com/repos/dimagi/commcare-android/git/commits{/sha}","comments_url":"https://api.github.com/repos/dimagi/commcare-android/comments{/number}","issue_comment_url":"https://api.github.com/repos/dimagi/commcare-android/issues/comments{/number}","contents_url":"https://api.github.com/repos/dimagi/commcare-android/contents/{+path}","compare_url":"https://api.github.com/repos/dimagi/commcare-android/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dimagi/commcare-android/merges","archive_url":"https://api.github.com/repos/dimagi/commcare-android/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dimagi/commcare-android/downloads","issues_url":"https://api.github.com/repos/dimagi/commcare-android/issues{/number}","pulls_url":"https://api.github.com/repos/dimagi/commcare-android/pulls{/number}","milestones_url":"https://api.github.com/repos/dimagi/commcare-android/milestones{/number}","notifications_url":"https://api.github.com/repos/dimagi/commcare-android/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dimagi/commcare-android/labels{/name}","releases_url":"https://api.github.com/repos/dimagi/commcare-android/releases{/id}","deployments_url":"https://api.github.com/repos/dimagi/commcare-android/deployments","created_at":"2014-06-17T21:17:26Z","updated_at":"2016-06-26T22:34:57Z","pushed_at":"2016-07-14T22:08:33Z","git_url":"git://github.com/dimagi/commcare-android.git","ssh_url":"git@github.com:dimagi/commcare-android.git","clone_url":"https://github.com/dimagi/commcare-android.git","svn_url":"https://github.com/dimagi/commcare-android","homepage":"https://play.google.com/store/apps/details?id=org.commcare.dalvik&hl=en","size":77372,"stargazers_count":9,"watchers_count":9,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":20,"forks":10,"open_issues":20,"watchers":9,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390"},"html":{"href":"https://github.com/dimagi/commcare-android/pull/1390"},"issue":{"href":"https://api.github.com/repos/dimagi/commcare-android/issues/1390"},"comments":{"href":"https://api.github.com/repos/dimagi/commcare-android/issues/1390/comments"},"review_comments":{"href":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390/comments"},"review_comment":{"href":"https://api.github.com/repos/dimagi/commcare-android/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dimagi/commcare-android/pulls/1390/commits"},"statuses":{"href":"https://api.github.com/repos/dimagi/commcare-android/statuses/fe91452064189695d64164209f3fcbffb024fd00"}}}}
{"actor":{"display_login":"wpride"}}