Due to SO_REUSE_PORT it is possible for a localhost:0
address to repeat. This causes failure in DHT tests
where we spun up a lot of nodes inside test.
As for a birthday paradox it is enough to use 140
ports to get 20% chance for collision which was causing
failure in our case.
The fix is to disable REUSE_PORT routine for the
tests and leave it running for sharness tests where
not that many addresses are used at the same time.
License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
Right now bin/dist_get trusts whatever DNS resolver is active.
This change enables it to verify what it downloads.
Verification itself remains TODO.
This will work best with a unixfs-hash tool which is TODO too.
It'd just do the equivalent of `ipfs add -n -r <dirOrFile>`.
License: MIT
Signed-off-by: Lars Gierth <larsg@systemli.org>
Move the go commands that should run under cmd/ipfs in the Makefile in
cmd/ipfs rather than doing a "cd cmd/ipfs && go ..." in the root
Makefile.
The "cd cmd/ipfs && go ..." lines causes problems with GNU Emacs's
compilation mode. With the current setup Emacs is unable to jump to
the location of the error outputted by go compiler as it can not find
the source file. The problem is that the embedded "cd" command causes
Emacs's compilation mode to lose track of the current directory and
thus attempts to look for the source file in the wrong directory.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
Build scripts should never touch user's environment.
This patch intoduces existance and version check for gx and gx-go
Prints nice error message if they are missing or outdated.
License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@gmail.com>
After losing jenkins, it's been difficult to test all commits
manually. This commit adds a Makefile target that makes travis do it.
Unfortunately, this is way too slow. It takes longer than the
allotted 10min.
After asking the travis people what to do, someone suggested making
sure that each commit is pushed to github independently. This makes
travis run CI on every single commit in the PR, and gives us nice
status indicators on each one (so we know which ones did not pass).
This approach means that we need to push a branch to the repo for
each commit in the PR-- otherwise travis may cancel its run if it
detects that the branch is no longer there. We could automate this
with a bot that essentially does:
for each PR:
git fetch the PR branch
push a branch per commit: <branch>-<commit>
for each closed PR:
delete all branches with pattern <branch>-<commit>
The dockertest/ directory has been moved into test/ and
it has been renamed 3nodetest/ in commit 28cf220d
(dockertest -> test/3nodetest).
License: MIT
Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
We use make test as the measure of correctness.
This laxity has let bugs creep into several systems.
This commit changes our target to always run expensive
tests, unless one specifically runs `make test_short`
(we would do well to remove most if not all timing--
that's usually what makes tests take a long time.)