{"action":"created","issue":{"url":"https://api.github.com/repos/DynamoDS/Dynamo/issues/5877","labels_url":"https://api.github.com/repos/DynamoDS/Dynamo/issues/5877/labels{/name}","comments_url":"https://api.github.com/repos/DynamoDS/Dynamo/issues/5877/comments","events_url":"https://api.github.com/repos/DynamoDS/Dynamo/issues/5877/events","html_url":"https://github.com/DynamoDS/Dynamo/pull/5877","id":123457960,"number":5877,"title":"Remove all backup files and folders before uploading a package version","user":{"login":"ellensi","id":6386550,"avatar_url":"https://avatars.githubusercontent.com/u/6386550?v=3","gravatar_id":"","url":"https://api.github.com/users/ellensi","html_url":"https://github.com/ellensi","followers_url":"https://api.github.com/users/ellensi/followers","following_url":"https://api.github.com/users/ellensi/following{/other_user}","gists_url":"https://api.github.com/users/ellensi/gists{/gist_id}","starred_url":"https://api.github.com/users/ellensi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ellensi/subscriptions","organizations_url":"https://api.github.com/users/ellensi/orgs","repos_url":"https://api.github.com/users/ellensi/repos","events_url":"https://api.github.com/users/ellensi/events{/privacy}","received_events_url":"https://api.github.com/users/ellensi/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/DynamoDS/Dynamo/labels/Requires%20Changes","name":"Requires Changes","color":"eb6420"}],"state":"open","locked":false,"assignee":{"login":"pboyer","id":916345,"avatar_url":"https://avatars.githubusercontent.com/u/916345?v=3","gravatar_id":"","url":"https://api.github.com/users/pboyer","html_url":"https://github.com/pboyer","followers_url":"https://api.github.com/users/pboyer/followers","following_url":"https://api.github.com/users/pboyer/following{/other_user}","gists_url":"https://api.github.com/users/pboyer/gists{/gist_id}","starred_url":"https://api.github.com/users/pboyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pboyer/subscriptions","organizations_url":"https://api.github.com/users/pboyer/orgs","repos_url":"https://api.github.com/users/pboyer/repos","events_url":"https://api.github.com/users/pboyer/events{/privacy}","received_events_url":"https://api.github.com/users/pboyer/received_events","type":"User","site_admin":false},"milestone":null,"comments":3,"created_at":"2015-12-22T10:49:50Z","updated_at":"2016-01-18T10:16:44Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/DynamoDS/Dynamo/pulls/5877","html_url":"https://github.com/DynamoDS/Dynamo/pull/5877","diff_url":"https://github.com/DynamoDS/Dynamo/pull/5877.diff","patch_url":"https://github.com/DynamoDS/Dynamo/pull/5877.patch"},"body":"### Purpose\r\n\r\nReferences:\r\n- [MAGN-7676](http://adsk-oss.myjetbrains.com/youtrack/issue/MAGN-7676) Do not include backup folders when uploading a package\r\n- #4699 Disregard backup folders when uploading a new package version\r\n\r\nWhen uploading a package, PackageManager copies selected files from their respective original locations to the target package folder and then zips the whole package folder for upload.\r\n\r\nFor the case when the user performs Publish Version, the original location is the same as the target package folder. PackageManager automatically selects and sorts the files in the old folder (skipping the backup files), but the files that have been skipped during the listing here will still reside in this folder, hence they will be included for zip and upload.\r\n\r\nAn implementation using `IFileSystem` has been added to delete the files in the package folder which are already not selected. All sub-folders named \"backup\" will also be deleted entirely before zipping the package folder.\r\n\r\nA test case for this defect has also been added.\r\n\r\n### Declarations\r\n\r\n- [x] The level of testing this PR includes is appropriate\r\n- [x] All tests pass using the self-service CI.\r\n\r\n### Reviewers\r\n\r\n@pboyer @Benglin \r\n\r\n### FYIs\r\n\r\n@riteshchandawar @kronz "},"comment":{"url":"https://api.github.com/repos/DynamoDS/Dynamo/issues/comments/172488165","html_url":"https://github.com/DynamoDS/Dynamo/pull/5877#issuecomment-172488165","issue_url":"https://api.github.com/repos/DynamoDS/Dynamo/issues/5877","id":172488165,"user":{"login":"ellensi","id":6386550,"avatar_url":"https://avatars.githubusercontent.com/u/6386550?v=3","gravatar_id":"","url":"https://api.github.com/users/ellensi","html_url":"https://github.com/ellensi","followers_url":"https://api.github.com/users/ellensi/followers","following_url":"https://api.github.com/users/ellensi/following{/other_user}","gists_url":"https://api.github.com/users/ellensi/gists{/gist_id}","starred_url":"https://api.github.com/users/ellensi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ellensi/subscriptions","organizations_url":"https://api.github.com/users/ellensi/orgs","repos_url":"https://api.github.com/users/ellensi/repos","events_url":"https://api.github.com/users/ellensi/events{/privacy}","received_events_url":"https://api.github.com/users/ellensi/received_events","type":"User","site_admin":false},"created_at":"2016-01-18T10:16:44Z","updated_at":"2016-01-18T10:16:44Z","body":"Hi @pboyer,\r\n\r\nAddressing your previous comments, I have introduced `GetFiles()` and `GetDirectories()` methods under `IFileSystem` and added a unit test case for this defect.\r\n\r\nPlease let me know if you have any more comments about this. Thank you!"}}