{"action":"created","issue":{"url":"https://api.github.com/repos/endrebak/epic/issues/41","repository_url":"https://api.github.com/repos/endrebak/epic","labels_url":"https://api.github.com/repos/endrebak/epic/issues/41/labels{/name}","comments_url":"https://api.github.com/repos/endrebak/epic/issues/41/comments","events_url":"https://api.github.com/repos/endrebak/epic/issues/41/events","html_url":"https://github.com/endrebak/epic/pull/41","id":180427503,"number":41,"title":"Improvements to file, tempdir, and command handling","user":{"login":"DarwinAwardWinner","id":228145,"avatar_url":"https://avatars.githubusercontent.com/u/228145?v=3","gravatar_id":"","url":"https://api.github.com/users/DarwinAwardWinner","html_url":"https://github.com/DarwinAwardWinner","followers_url":"https://api.github.com/users/DarwinAwardWinner/followers","following_url":"https://api.github.com/users/DarwinAwardWinner/following{/other_user}","gists_url":"https://api.github.com/users/DarwinAwardWinner/gists{/gist_id}","starred_url":"https://api.github.com/users/DarwinAwardWinner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/DarwinAwardWinner/subscriptions","organizations_url":"https://api.github.com/users/DarwinAwardWinner/orgs","repos_url":"https://api.github.com/users/DarwinAwardWinner/repos","events_url":"https://api.github.com/users/DarwinAwardWinner/events{/privacy}","received_events_url":"https://api.github.com/users/DarwinAwardWinner/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2016-10-01T00:31:19Z","updated_at":"2016-10-03T12:53:41Z","closed_at":"2016-10-03T12:53:41Z","pull_request":{"url":"https://api.github.com/repos/endrebak/epic/pulls/41","html_url":"https://github.com/endrebak/epic/pull/41","diff_url":"https://github.com/endrebak/epic/pull/41.diff","patch_url":"https://github.com/endrebak/epic/pull/41.patch"},"body":"I've made a number of improvements to file handling, tempdir handling, and command handling. In the files I edited:\r\n\r\n- Temporary directory handling is delegated to the `tempfile` module.\r\n- `subprocess.check_call` is used instead of `subprocess.call`, so that if a command fails, the program will abort.\r\n- bedgraph paths are converted into bigwig paths via `os.path` functions instead of string replacement\r\n- `os.makedirs` is used in place of `call(\"mkdir -p\")`.\r\n\r\nMy original motivation for making these fixes was noticing that every invocation of epic used the same temporary directory for bedgraph files, which meant that if multiple instances of the script were running at once, it was possible that they could overwrite each others' temporary files, causing bigwig files to get associated with the wrong samples. This should no longer be an issue, since each invoocation creates its own randomly-named temporary directory."},"comment":{"url":"https://api.github.com/repos/endrebak/epic/issues/comments/251098219","html_url":"https://github.com/endrebak/epic/pull/41#issuecomment-251098219","issue_url":"https://api.github.com/repos/endrebak/epic/issues/41","id":251098219,"user":{"login":"endrebak","id":17778898,"avatar_url":"https://avatars.githubusercontent.com/u/17778898?v=3","gravatar_id":"","url":"https://api.github.com/users/endrebak","html_url":"https://github.com/endrebak","followers_url":"https://api.github.com/users/endrebak/followers","following_url":"https://api.github.com/users/endrebak/following{/other_user}","gists_url":"https://api.github.com/users/endrebak/gists{/gist_id}","starred_url":"https://api.github.com/users/endrebak/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/endrebak/subscriptions","organizations_url":"https://api.github.com/users/endrebak/orgs","repos_url":"https://api.github.com/users/endrebak/repos","events_url":"https://api.github.com/users/endrebak/events{/privacy}","received_events_url":"https://api.github.com/users/endrebak/received_events","type":"User","site_admin":false},"created_at":"2016-10-03T12:53:41Z","updated_at":"2016-10-03T12:53:41Z","body":"Thanks for this, but in 0.1.19 I've improved the handling of bigwigs. Furthermore, your tests failed for `2.7` :)"}}
{"actor":{"display_login":"endrebak"}}