{"action":"created","issue":{"url":"https://api.github.com/repos/quamotion/madb/issues/37","repository_url":"https://api.github.com/repos/quamotion/madb","labels_url":"https://api.github.com/repos/quamotion/madb/issues/37/labels{/name}","comments_url":"https://api.github.com/repos/quamotion/madb/issues/37/comments","events_url":"https://api.github.com/repos/quamotion/madb/issues/37/events","html_url":"https://github.com/quamotion/madb/issues/37","id":150939441,"number":37,"title":"File upload failed","user":{"login":"siterui","id":17012320,"avatar_url":"https://avatars.githubusercontent.com/u/17012320?v=3","gravatar_id":"","url":"https://api.github.com/users/siterui","html_url":"https://github.com/siterui","followers_url":"https://api.github.com/users/siterui/followers","following_url":"https://api.github.com/users/siterui/following{/other_user}","gists_url":"https://api.github.com/users/siterui/gists{/gist_id}","starred_url":"https://api.github.com/users/siterui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/siterui/subscriptions","organizations_url":"https://api.github.com/users/siterui/orgs","repos_url":"https://api.github.com/users/siterui/repos","events_url":"https://api.github.com/users/siterui/events{/privacy}","received_events_url":"https://api.github.com/users/siterui/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/quamotion/madb/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":{"login":"qmfrederik","id":9918129,"avatar_url":"https://avatars.githubusercontent.com/u/9918129?v=3","gravatar_id":"","url":"https://api.github.com/users/qmfrederik","html_url":"https://github.com/qmfrederik","followers_url":"https://api.github.com/users/qmfrederik/followers","following_url":"https://api.github.com/users/qmfrederik/following{/other_user}","gists_url":"https://api.github.com/users/qmfrederik/gists{/gist_id}","starred_url":"https://api.github.com/users/qmfrederik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qmfrederik/subscriptions","organizations_url":"https://api.github.com/users/qmfrederik/orgs","repos_url":"https://api.github.com/users/qmfrederik/repos","events_url":"https://api.github.com/users/qmfrederik/events{/privacy}","received_events_url":"https://api.github.com/users/qmfrederik/received_events","type":"User","site_admin":false},"milestone":null,"comments":0,"created_at":"2016-04-25T18:01:02Z","updated_at":"2016-05-03T09:38:47Z","closed_at":null,"body":"**Minicap is a file, not a folder.\r\nFile no suffix, upload failed**\r\n**Error prompt:**\r\n`Failed to pull '/data/local/tmp/minicap'. No such file or directory`\r\n```\r\n   public void pushFile(string localpath, string devicepath)\r\n        {\r\n\t    //localpath：Lib/minicap/bin/armeabi-v7a/minicap\r\n\t    //devicepath：/data/local/tmp\r\n            var filename = new FileInfo(localpath).Name;\r\n            var remotepath = devicepath + @\"/\" + filename;\r\n            using (ISyncService service = Factories.SyncServiceFactory(device))\r\n            {\r\n                var stat = service.Stat(remotpath);\r\n                if (stat.Size == 0)\r\n                {\r\n                    using (Stream stream = File.OpenWrite(localpath))\r\n                    {\r\n                        service.Pull(remotepath, stream, null, CancellationToken.None);\r\n                    }\r\n                }\r\n            }\r\n        }\r\n```"},"comment":{"url":"https://api.github.com/repos/quamotion/madb/issues/comments/216480814","html_url":"https://github.com/quamotion/madb/issues/37#issuecomment-216480814","issue_url":"https://api.github.com/repos/quamotion/madb/issues/37","id":216480814,"user":{"login":"qmfrederik","id":9918129,"avatar_url":"https://avatars.githubusercontent.com/u/9918129?v=3","gravatar_id":"","url":"https://api.github.com/users/qmfrederik","html_url":"https://github.com/qmfrederik","followers_url":"https://api.github.com/users/qmfrederik/followers","following_url":"https://api.github.com/users/qmfrederik/following{/other_user}","gists_url":"https://api.github.com/users/qmfrederik/gists{/gist_id}","starred_url":"https://api.github.com/users/qmfrederik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qmfrederik/subscriptions","organizations_url":"https://api.github.com/users/qmfrederik/orgs","repos_url":"https://api.github.com/users/qmfrederik/repos","events_url":"https://api.github.com/users/qmfrederik/events{/privacy}","received_events_url":"https://api.github.com/users/qmfrederik/received_events","type":"User","site_admin":false},"created_at":"2016-05-03T09:38:47Z","updated_at":"2016-05-03T09:38:47Z","body":"Are you trying to upload a file to the device? If so, you should use `service.Push` instead of `service.Pull`.\r\n\r\nLet me know how it goes."}}