[Sugar-devel] [PATCH Browse] Cancel a download if space is very tight SL #394
Manuel Kaufmann
humitos at gmail.com
Wed Sep 12 08:20:09 EDT 2012
On Tue, Sep 11, 2012 at 10:27 PM, Martin Langhoff
<martin.langhoff at gmail.com> wrote:
> - During datastore.write() -- I truly believe that the
> datastore.write() call doesn't literally make a copy of the file --
> should just create/update the hardlink and associated metadata
> (including progress bar). It is not very likely that we'll run out of
> space during this call, but it should be handled, I believe.
OK. I was taking a look at the datastore source code and I understood
that the file is copied, using the traditional way and when the copy
finishes the source file is unlinked.
Here are the source files that I took a look and how I found this:
sugar-toolkit-gtk3/src/sugar3/datastore/datastore.py L340 (def write)
---> L316 (def _update_ds_entry)
---> L45 (def _get_data_store)
sugar-datastore/src/carquinyol/datastore.py L242 (def update)
src/carquinyol/filestore.py L34 (def store)
---> L215 (def start)
---> L181 (def _copy_block)
Please, let me know if I am wrong.
--
Kaufmann Manuel
Blog: http://humitos.wordpress.com/
Porfolio: http://fotos.mkaufmann.com.ar/
PyAr: http://www.python.com.ar/
More information about the Sugar-devel
mailing list