kubo/core
Juan Batiz-Benet f105ce439f get: fix bug + improvements
up until now there has been a very annoying bug with get, we would
get halting behavior. I'm not 100% sure this commit fixes it,
but it should. It certainly fixes others found in the process of
digging into the get / tar extractor code. (wish we could repro
the bug reliably enough to make a test case).

This is a much cleaner tar writer. the ad-hoc, error-prone synch
for the tar reader is gone (with i believe was incorrect). it is
replaced with a simple pipe and bufio. The tar logic is now in
tar.Writer, which writes unixfs dag nodes into a tar archive (no
need for synch here). And get's reader is constructed with DagArchive
which sets up the pipe + bufio.

NOTE: this commit also changes this behavior of `get`:
When retrieving a single file, if the file exists, get would fail.
this emulated the behavior of wget by default, which (without opts)
does not overwrite if the file is there. This change makes get
fail if the file is available locally. This seems more intuitive to
me as expected from a unix tool-- though perhaps it should be
discussed more before adopting.

Everything seems to work fine, and i have not been able to reproduce
the get halt bug.

License: MIT
Signed-off-by: Juan Batiz-Benet <juan@benet.ai>
2015-08-05 09:50:33 +02:00
..
commands get: fix bug + improvements 2015-08-05 09:50:33 +02:00
corehttp fix cors: defaults should take the port of the listener 2015-08-02 08:16:51 +02:00
corenet Reorged imports from jbenet/go-ipfs to ipfs/go-ipfs 2015-03-31 12:52:25 -07:00
corerepo make offline commands respect timeout 2015-07-20 14:34:16 -07:00
corerouting Reorged imports from jbenet/go-ipfs to ipfs/go-ipfs 2015-03-31 12:52:25 -07:00
coreunix Change Process interface into object variable 2015-07-04 22:50:23 +07:00
mock core/mock: make sure node has a ctx and proc 2015-07-28 23:35:50 -07:00
.gitignore ignore testdb 2014-07-05 15:04:04 -07:00
bootstrap_test.go Reorged imports from jbenet/go-ipfs to ipfs/go-ipfs 2015-03-31 12:52:25 -07:00
bootstrap.go core: bugfix: bootstrap random permutation 2015-04-20 06:00:42 -07:00
builder.go add option to only hash input 2015-06-22 15:21:53 -07:00
core_test.go Run 'gofmt -s -w' on these files 2015-05-19 06:11:15 +07:00
core.go fuse unmount fixes 2015-07-29 01:36:50 -07:00
pathresolver_test.go Add test to detect invalid path 2015-07-04 02:50:15 +07:00
pathresolver.go Named error for no components 2015-05-22 09:18:49 -07:00