html_url,issue_url,id,node_id,user,created_at,updated_at,author_association,body,reactions,performed_via_github_app,issue https://github.com/pydata/xarray/issues/3227#issuecomment-525325332,https://api.github.com/repos/pydata/xarray/issues/3227,525325332,MDEyOklzc3VlQ29tbWVudDUyNTMyNTMzMg==,868027,2019-08-27T14:24:35Z,2019-08-27T14:24:35Z,CONTRIBUTOR,"Hi @gwgundersen some clarification on those ""extra snippets"", github is not aware of the ipython directive so it prints those out like code snippets. In the actual [built docs](http://xarray.pydata.org/en/stable/dask.html#chunking-and-performance), these don't appear (the `:suppress:` in that block does this). I personally feel that the code that makes these temporary files should be responsible for cleaning it up, especially since it already tries, and they aren't build artifacts needed in other steps. I'd probably reach for the [tempfile.TemporaryDirectory](https://docs.python.org/3.7/library/tempfile.html#tempfile.TemporaryDirectory) in the standard library and bracket the dask docs in a create, cd in, cd out, cleanup type flow. There is already a suppressed setup ipython block at the top of the dask docs too. @max-sixty Any opinions on which option we should go for?","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,482023929 https://github.com/pydata/xarray/issues/3227#issuecomment-522589729,https://api.github.com/repos/pydata/xarray/issues/3227,522589729,MDEyOklzc3VlQ29tbWVudDUyMjU4OTcyOQ==,868027,2019-08-19T14:03:24Z,2019-08-19T14:03:24Z,CONTRIBUTOR,"The files and directories that were not cleaned up by the `make clean` command are all artifacts of the code examples which run in the docs themselves. For example, the `manipulated-example-data.nc` is created in [this section](https://github.com/pydata/xarray/blob/master/doc/dask.rst#reading-and-writing-data). At leas one of these files is cleaned up at the end, [see the ipython block](https://github.com/pydata/xarray/blob/master/doc/dask.rst#chunking-and-performance). I'd probably look into something like a [temporary directory](https://docs.python.org/3/library/tempfile.html#tempfile.TemporaryDirectory) rather than trying to track down all the ""example artifacts"" created during a run. I'm not sure what sort of configuration the IPython blocks have, but there are also some [tempdir utilities in IPython](https://ipython.readthedocs.io/en/stable/api/generated/IPython.utils.tempdir.html#IPython.utils.tempdir.TemporaryWorkingDirectory).","{""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,482023929