Commit Graph

2703 Commits

Author SHA1 Message Date
Matt Joiner a22c1334c6 Include webseed urls in MetaInfo.Magnet output
Fixes #469.
2021-02-24 12:11:47 +11:00
Matt Joiner 35464677ef Improve metainfo.MetaInfo.Magnet interface and add tests 2021-02-24 12:11:47 +11:00
Yaroslav Kolomiiets d8d71addfc PEX: impede full-meching in tracker-less swarms by adding a cooldown minute 2021-02-24 08:29:18 +11:00
Matt Joiner f00f513706 Add missing closeMu use in ReadConsecutiveChunks 2021-02-22 16:39:21 +11:00
Matt Joiner ac05b69e11 Only write update bolt piece completion if the existing value differs 2021-02-22 14:51:34 +11:00
Matt Joiner 7f7c59d52e Replace internal/tmproot with Testing.TB.TempDir 2021-02-22 14:30:09 +11:00
Matt Joiner 91454b65fa Merge Sean-Der's webrtc/v3 update 2021-02-22 11:22:49 +11:00
Matt Joiner cbdc2b8263 Comment and log change on torrentfs behaviour change 2021-02-22 10:10:43 +11:00
Matt Joiner 4bb2233b46 Merge branch 'fuse-email-issue' 2021-02-22 10:05:32 +11:00
Matt Joiner f959d32cef go mod tidy 2021-02-22 10:01:56 +11:00
Matt Joiner ea8d5ff1ac Pull dht peer store interface 2021-02-22 10:00:51 +11:00
Sean DuBois 8749bd9697 Upgrade to pion/webrtc@v3 2021-02-21 13:46:37 -08:00
Matt Joiner 051093ca31 Add PeerStorer interface 2021-02-21 17:17:57 +11:00
Matt Joiner cff461c898 Add ClientConfig.ConfigureAnacrolixDhtServer 2021-02-20 22:16:54 +11:00
Matt Joiner 28f17be267 Close all peer types when Torrent closed 2021-02-19 12:58:20 +11:00
Matt Joiner 86a2b71c47 Code comment 2021-02-19 12:37:26 +11:00
Matt Joiner 6cfce3214f Create codeql-analysis.yml 2021-02-18 14:48:15 +11:00
Matt Joiner 7e2c2106e6 Include webseed URLs in output of Torrent.Metainfo 2021-02-18 14:37:06 +11:00
Matt Joiner af0ade5496 Treat 404 responses from webseed peers as fatal
Fixes #464.
2021-02-18 14:36:08 +11:00
Matt Joiner d5c6ca0485 Add test case for #464 2021-02-18 14:34:42 +11:00
Matt Joiner 2c62206103 Install godo 2021-02-15 21:44:52 +11:00
Matt Joiner 90b2932fe7 Run torrentfs without race 2021-02-15 21:44:35 +11:00
Matt Joiner 2dd566a24c Add new debian torrent testdata file 2021-02-15 16:12:58 +11:00
Matt Joiner 7990eef91d Use io.ReadFull in fs reads 2021-02-15 15:53:32 +11:00
Matt Joiner a5439836d9 fs/test.sh: Use godo for out of tree go run 2021-02-15 15:45:07 +11:00
Matt Joiner e3cfd3d033 Rework fs/test.sh
Updates to use newer debian file, and operate in working directory. Temporary directory management should be done by the caller (such as in CI maybe).
2021-02-12 19:21:28 +11:00
Matt Joiner 927866e881 Limit conns per host across webseed clients 2021-02-09 19:22:38 +11:00
Matt Joiner 0cc655deed Fix closing of webseed peers 2021-02-09 19:21:54 +11:00
Matt Joiner 549ab3c160 Buff issue 465 test command 2021-02-09 19:17:22 +11:00
Matt Joiner ce44a4c3f2 Add minimal reproducing code for issue 465
From https://github.com/anacrolix/torrent/issues/465#issuecomment-774869977.
2021-02-09 17:05:02 +11:00
Matt Joiner 579925fa94 Fix panic in benchmark 2021-02-05 10:01:33 +11:00
Matt Joiner bc0936c44a Use locks on piece per resource pieces to prevent races in reading incomplete data 2021-02-04 19:18:59 +11:00
Matt Joiner 78c77c0b45 Expose mmap_size in sqlite storage, and change default to 8 MiB 2021-02-04 18:29:40 +11:00
Matt Joiner c714cb6992 Fix some go vet warnings 2021-02-03 19:42:46 +11:00
Matt Joiner 371d54ab76 Fix Close race in sqlite storage when batch writes disabled 2021-02-03 19:27:26 +11:00
Matt Joiner 6bc2a2a6ac Revert "Fix stalls for responsive transfer tests"
This reverts commit d48c6ae6dc.
2021-02-03 18:55:54 +11:00
Matt Joiner 6f9c2fed61 Add batch writes cases to sqlite storage benchmarks 2021-02-03 18:55:14 +11:00
Matt Joiner f3cd7007eb Update deps 2021-02-02 10:47:38 +11:00
Matt Joiner 48843c0b87 Fix for go<1.16 2021-02-02 10:41:39 +11:00
Matt Joiner 15ccbc95c6 Fix sqlite storage for numconns 1 2021-02-02 10:41:39 +11:00
Matt Joiner d48c6ae6dc Fix stalls for responsive transfer tests
Looks like there's a timing issue between marking things complete, and already having decided to read the data from incomplete chunks.
2021-02-02 10:41:39 +11:00
Matt Joiner 270a2ba1ae Switch to reading consecutive incomplete chunks
This fixes a race where a sqlite conn isn't reserved for the read part of a MarkComplete operation after the write has already begun.
2021-02-02 10:41:38 +11:00
Matt Joiner 4ae8a1bc52 Add tests for numconns 2 2021-02-02 10:41:38 +11:00
Matt Joiner ad2ea89961 Use go1.16 release branch in CI 2021-02-02 10:41:38 +11:00
Shubhendra Singh Chauhan 0cdb33ede0 fixed code quality issues using DeepSource
* Added .deepsource.toml

* Removed empty default in select

* Removed unnecessary use of slice

* Fixed check for empty string
2021-01-30 15:23:49 +11:00
Matt Joiner f5915ad12c Use iotest.TestReader 2021-01-29 23:32:01 +11:00
Matt Joiner 887db4a276 Some deps got tagged 2021-01-29 22:05:09 +11:00
Matt Joiner 840f2ff3e9 Update crawshaw.io/sqlite
Now includes the fix for the pool race. I've removed the replace, the only thing left in the getlantern fork is the linking fix, and I forget when it's an issue.
2021-01-29 17:59:56 +11:00
Matt Joiner 68d8604c20 We're not expecting chunks if we have no outstanding requests 2021-01-29 16:14:08 +11:00
Matt Joiner 43a2942b98 Set not interested when we have no pending requests 2021-01-29 16:13:46 +11:00