Skip to content

Commit 33ff595

Browse files
authored
Merge pull request #465 from ipfs/release-v0.13.0
Release v0.13.0
2 parents c540780 + f0ff3ce commit 33ff595

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

58 files changed

+1781
-1513
lines changed

.github/workflows/gateway-conformance.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- name: Setup Go
2626
uses: actions/setup-go@v3
2727
with:
28-
go-version: 1.19.x
28+
go-version: 1.21.x
2929
- name: Checkout boxo
3030
uses: actions/checkout@v3
3131
with:

.github/workflows/gateway-sharness.yml

+2-6
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,9 @@ jobs:
1616
shell: bash
1717
steps:
1818
- name: Setup Go
19-
uses: actions/setup-go@v3
19+
uses: actions/setup-go@v4
2020
with:
21-
go-version: 1.19.1
21+
go-version: 1.21.x
2222
- name: Checkout boxo
2323
uses: actions/checkout@v3
2424
with:
@@ -30,10 +30,6 @@ jobs:
3030
path: kubo
3131
- name: Install Missing Tools
3232
run: sudo apt install -y socat net-tools fish libxml2-utils
33-
- name: Restore Go Cache
34-
uses: protocol/cache-go-action@v1
35-
with:
36-
name: ${{ github.job }}
3733
- name: Replace boxo in Kubo go.mod
3834
run: |
3935
go mod edit -replace=github.com/ipfs/boxo=../boxo

CHANGELOG.md

+32-1
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,37 @@ The following emojis are used to highlight certain changes:
2424

2525
### Security
2626

27+
## [v0.13.0]
28+
29+
### Added
30+
31+
* ✨ The `routing/http` implements Delegated Peer Routing introduced in [IPIP-417](https://github.com/ipfs/specs/pull/417).
32+
33+
### Changed
34+
35+
* 🛠 The `routing/http` package received the following modifications:
36+
* Client `GetIPNSRecord` and `PutIPNSRecord` have been renamed to `GetIPNS` and
37+
`PutIPNS`, respectively. Similarly, the required function names in the server
38+
`ContentRouter` have also been updated.
39+
* `ReadBitswapProviderRecord` has been renamed to `BitswapRecord` and marked as deprecated.
40+
From now on, please use the protocol-agnostic `PeerRecord` for most use cases. The new
41+
Peer Schema has been introduced in [IPIP-417](https://github.com/ipfs/specs/pull/417).
42+
43+
### Removed
44+
45+
* 🛠 The `routing/http` package experienced following removals:
46+
* Server and client no longer support the experimental `Provide` method.
47+
`ProvideBitswap` is still usable, but marked as deprecated. A protocol-agnostic
48+
provide mechanism is being worked on in [IPIP-378](https://github.com/ipfs/specs/pull/378).
49+
* Server no longer exports `FindProvidersPath` and `ProvidePath`.
50+
51+
### Fixed
52+
53+
* The normalization of DNSLink identifiers in `gateway` has been corrected in the edge
54+
case where the value passed to the path component of the URL is already normalized.
55+
56+
### Security
57+
2758
## [v0.12.0]
2859

2960
### Added
@@ -32,7 +63,7 @@ The following emojis are used to highlight certain changes:
3263
as per [IPIP-379](https://specs.ipfs.tech/ipips/ipip-0379/).
3364
* 🛠 The `verifycid` package has been updated with the new Allowlist interface as part of
3465
reducing globals efforts.
35-
* The `blockservice` and `provider` packages has been updated to accommodate for
66+
* The `blockservice` and `provider` packages has been updated to accommodate for
3667
changes in `verifycid`.
3768

3869
### Changed

bitswap/bitswap_test.go

-35
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ import (
1414
"github.com/ipfs/boxo/bitswap/server"
1515
testinstance "github.com/ipfs/boxo/bitswap/testinstance"
1616
tn "github.com/ipfs/boxo/bitswap/testnet"
17-
"github.com/ipfs/boxo/internal/test"
1817
mockrouting "github.com/ipfs/boxo/routing/mock"
1918
blocks "github.com/ipfs/go-block-format"
2019
cid "github.com/ipfs/go-cid"
@@ -49,8 +48,6 @@ func addBlock(t *testing.T, ctx context.Context, inst testinstance.Instance, blk
4948
const kNetworkDelay = 0 * time.Millisecond
5049

5150
func TestClose(t *testing.T) {
52-
test.Flaky(t)
53-
5451
vnet := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
5552
ig := testinstance.NewTestInstanceGenerator(vnet, nil, nil)
5653
defer ig.Close()
@@ -67,8 +64,6 @@ func TestClose(t *testing.T) {
6764
}
6865

6966
func TestProviderForKeyButNetworkCannotFind(t *testing.T) { // TODO revisit this
70-
test.Flaky(t)
71-
7267
rs := mockrouting.NewServer()
7368
net := tn.VirtualNetwork(rs, delay.Fixed(kNetworkDelay))
7469
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
@@ -94,8 +89,6 @@ func TestProviderForKeyButNetworkCannotFind(t *testing.T) { // TODO revisit this
9489
}
9590

9691
func TestGetBlockFromPeerAfterPeerAnnounces(t *testing.T) {
97-
test.Flaky(t)
98-
9992
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
10093
block := blocks.NewBlock([]byte("block"))
10194
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
@@ -124,8 +117,6 @@ func TestGetBlockFromPeerAfterPeerAnnounces(t *testing.T) {
124117
}
125118

126119
func TestDoesNotProvideWhenConfiguredNotTo(t *testing.T) {
127-
test.Flaky(t)
128-
129120
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
130121
block := blocks.NewBlock([]byte("block"))
131122
bsOpts := []bitswap.Option{bitswap.ProvideEnabled(false), bitswap.ProviderSearchDelay(50 * time.Millisecond)}
@@ -158,8 +149,6 @@ func TestDoesNotProvideWhenConfiguredNotTo(t *testing.T) {
158149
// Tests that a received block is not stored in the blockstore if the block was
159150
// not requested by the client
160151
func TestUnwantedBlockNotAdded(t *testing.T) {
161-
test.Flaky(t)
162-
163152
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
164153
block := blocks.NewBlock([]byte("block"))
165154
bsMessage := bsmsg.New(true)
@@ -195,8 +184,6 @@ func TestUnwantedBlockNotAdded(t *testing.T) {
195184
//
196185
// (because the live request queue is full)
197186
func TestPendingBlockAdded(t *testing.T) {
198-
test.Flaky(t)
199-
200187
ctx := context.Background()
201188
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
202189
bg := blocksutil.NewBlockGenerator()
@@ -245,8 +232,6 @@ func TestPendingBlockAdded(t *testing.T) {
245232
}
246233

247234
func TestLargeSwarm(t *testing.T) {
248-
test.Flaky(t)
249-
250235
if testing.Short() {
251236
t.SkipNow()
252237
}
@@ -279,8 +264,6 @@ func TestLargeFile(t *testing.T) {
279264
}
280265

281266
func TestLargeFileTwoPeers(t *testing.T) {
282-
test.Flaky(t)
283-
284267
if testing.Short() {
285268
t.SkipNow()
286269
}
@@ -290,8 +273,6 @@ func TestLargeFileTwoPeers(t *testing.T) {
290273
}
291274

292275
func PerformDistributionTest(t *testing.T, numInstances, numBlocks int) {
293-
test.Flaky(t)
294-
295276
ctx := context.Background()
296277
if testing.Short() {
297278
t.SkipNow()
@@ -349,8 +330,6 @@ func PerformDistributionTest(t *testing.T, numInstances, numBlocks int) {
349330

350331
// TODO simplify this test. get to the _essence_!
351332
func TestSendToWantingPeer(t *testing.T) {
352-
test.Flaky(t)
353-
354333
if testing.Short() {
355334
t.SkipNow()
356335
}
@@ -393,8 +372,6 @@ func TestSendToWantingPeer(t *testing.T) {
393372
}
394373

395374
func TestEmptyKey(t *testing.T) {
396-
test.Flaky(t)
397-
398375
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
399376
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
400377
defer ig.Close()
@@ -428,8 +405,6 @@ func assertStat(t *testing.T, st *bitswap.Stat, sblks, rblks, sdata, rdata uint6
428405
}
429406

430407
func TestBasicBitswap(t *testing.T) {
431-
test.Flaky(t)
432-
433408
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
434409
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
435410
defer ig.Close()
@@ -502,8 +477,6 @@ func TestBasicBitswap(t *testing.T) {
502477
}
503478

504479
func TestDoubleGet(t *testing.T) {
505-
test.Flaky(t)
506-
507480
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
508481
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
509482
defer ig.Close()
@@ -569,8 +542,6 @@ func TestDoubleGet(t *testing.T) {
569542
}
570543

571544
func TestWantlistCleanup(t *testing.T) {
572-
test.Flaky(t)
573-
574545
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
575546
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
576547
defer ig.Close()
@@ -693,8 +664,6 @@ func newReceipt(sent, recv, exchanged uint64) *server.Receipt {
693664
}
694665

695666
func TestBitswapLedgerOneWay(t *testing.T) {
696-
test.Flaky(t)
697-
698667
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
699668
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
700669
defer ig.Close()
@@ -744,8 +713,6 @@ func TestBitswapLedgerOneWay(t *testing.T) {
744713
}
745714

746715
func TestBitswapLedgerTwoWay(t *testing.T) {
747-
test.Flaky(t)
748-
749716
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
750717
ig := testinstance.NewTestInstanceGenerator(net, nil, nil)
751718
defer ig.Close()
@@ -834,8 +801,6 @@ func (tsl *testingScoreLedger) Stop() {
834801

835802
// Tests start and stop of a custom decision logic
836803
func TestWithScoreLedger(t *testing.T) {
837-
test.Flaky(t)
838-
839804
tsl := newTestingScoreLedger()
840805
net := tn.VirtualNetwork(mockrouting.NewServer(), delay.Fixed(kNetworkDelay))
841806
bsOpts := []bitswap.Option{bitswap.WithScoreLedger(tsl)}

bitswap/client/bitswap_with_sessions_test.go

-19
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import (
1111
"github.com/ipfs/boxo/bitswap/client/traceability"
1212
testinstance "github.com/ipfs/boxo/bitswap/testinstance"
1313
tn "github.com/ipfs/boxo/bitswap/testnet"
14-
"github.com/ipfs/boxo/internal/test"
1514
mockrouting "github.com/ipfs/boxo/routing/mock"
1615
blocks "github.com/ipfs/go-block-format"
1716
cid "github.com/ipfs/go-cid"
@@ -40,8 +39,6 @@ func addBlock(t *testing.T, ctx context.Context, inst testinstance.Instance, blk
4039
}
4140

4241
func TestBasicSessions(t *testing.T) {
43-
test.Flaky(t)
44-
4542
ctx, cancel := context.WithCancel(context.Background())
4643
defer cancel()
4744

@@ -109,8 +106,6 @@ func assertBlockListsFrom(from peer.ID, got, exp []blocks.Block) error {
109106
}
110107

111108
func TestSessionBetweenPeers(t *testing.T) {
112-
test.Flaky(t)
113-
114109
ctx, cancel := context.WithCancel(context.Background())
115110
defer cancel()
116111

@@ -171,8 +166,6 @@ func TestSessionBetweenPeers(t *testing.T) {
171166
}
172167

173168
func TestSessionSplitFetch(t *testing.T) {
174-
test.Flaky(t)
175-
176169
ctx, cancel := context.WithCancel(context.Background())
177170
defer cancel()
178171

@@ -217,8 +210,6 @@ func TestSessionSplitFetch(t *testing.T) {
217210
}
218211

219212
func TestFetchNotConnected(t *testing.T) {
220-
test.Flaky(t)
221-
222213
ctx, cancel := context.WithTimeout(context.Background(), 2*time.Second)
223214
defer cancel()
224215

@@ -262,8 +253,6 @@ func TestFetchNotConnected(t *testing.T) {
262253
}
263254

264255
func TestFetchAfterDisconnect(t *testing.T) {
265-
test.Flaky(t)
266-
267256
ctx, cancel := context.WithTimeout(context.Background(), 2*time.Second)
268257
defer cancel()
269258

@@ -342,8 +331,6 @@ func TestFetchAfterDisconnect(t *testing.T) {
342331
}
343332

344333
func TestInterestCacheOverflow(t *testing.T) {
345-
test.Flaky(t)
346-
347334
ctx, cancel := context.WithCancel(context.Background())
348335
defer cancel()
349336

@@ -394,8 +381,6 @@ func TestInterestCacheOverflow(t *testing.T) {
394381
}
395382

396383
func TestPutAfterSessionCacheEvict(t *testing.T) {
397-
test.Flaky(t)
398-
399384
ctx, cancel := context.WithCancel(context.Background())
400385
defer cancel()
401386

@@ -434,8 +419,6 @@ func TestPutAfterSessionCacheEvict(t *testing.T) {
434419
}
435420

436421
func TestMultipleSessions(t *testing.T) {
437-
test.Flaky(t)
438-
439422
ctx, cancel := context.WithCancel(context.Background())
440423
defer cancel()
441424

@@ -477,8 +460,6 @@ func TestMultipleSessions(t *testing.T) {
477460
}
478461

479462
func TestWantlistClearsOnCancel(t *testing.T) {
480-
test.Flaky(t)
481-
482463
ctx, cancel := context.WithTimeout(context.Background(), time.Second*5)
483464
defer cancel()
484465

bitswap/client/internal/blockpresencemanager/blockpresencemanager_test.go

-7
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@ import (
44
"testing"
55

66
"github.com/ipfs/boxo/bitswap/internal/testutil"
7-
"github.com/ipfs/boxo/internal/test"
87
cid "github.com/ipfs/go-cid"
98
peer "github.com/libp2p/go-libp2p/core/peer"
109
)
@@ -17,8 +16,6 @@ const (
1716
)
1817

1918
func TestBlockPresenceManager(t *testing.T) {
20-
test.Flaky(t)
21-
2219
bpm := New()
2320

2421
p := testutil.GeneratePeers(1)[0]
@@ -99,8 +96,6 @@ func TestBlockPresenceManager(t *testing.T) {
9996
}
10097

10198
func TestAddRemoveMulti(t *testing.T) {
102-
test.Flaky(t)
103-
10499
bpm := New()
105100

106101
peers := testutil.GeneratePeers(2)
@@ -184,8 +179,6 @@ func TestAddRemoveMulti(t *testing.T) {
184179
}
185180

186181
func TestAllPeersDoNotHaveBlock(t *testing.T) {
187-
test.Flaky(t)
188-
189182
bpm := New()
190183

191184
peers := testutil.GeneratePeers(3)

0 commit comments

Comments
 (0)