mirror of
https://github.com/ipfs/kubo.git
synced 2026-02-21 18:37:45 +08:00
Merge branch 'master' into merge-release-v0.19.0
This commit is contained in:
commit
eb7d6f98df
4
.github/workflows/codeql-analysis.yml
vendored
4
.github/workflows/codeql-analysis.yml
vendored
@ -11,6 +11,10 @@ on:
|
||||
schedule:
|
||||
- cron: '30 12 * * 2'
|
||||
|
||||
permissions:
|
||||
contents: read # to fetch code (actions/checkout)
|
||||
security-events: write # (github/codeql-action/autobuild)
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
if: github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
3
.github/workflows/docker-image.yml
vendored
3
.github/workflows/docker-image.yml
vendored
@ -9,6 +9,9 @@ on:
|
||||
tags:
|
||||
- 'v*'
|
||||
|
||||
permissions:
|
||||
contents: read # to fetch code (actions/checkout)
|
||||
|
||||
jobs:
|
||||
push_to_registry:
|
||||
if: github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
3
.github/workflows/golang-analysis.yml
vendored
3
.github/workflows/golang-analysis.yml
vendored
@ -7,6 +7,9 @@ on:
|
||||
branches:
|
||||
- 'master'
|
||||
|
||||
permissions:
|
||||
contents: read # to fetch code (actions/checkout)
|
||||
|
||||
jobs:
|
||||
unit:
|
||||
if: github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
54
.github/workflows/gotest.yml
vendored
54
.github/workflows/gotest.yml
vendored
@ -23,22 +23,28 @@ jobs:
|
||||
run:
|
||||
shell: bash
|
||||
steps:
|
||||
- uses: actions/setup-go@v3
|
||||
- name: Set up Go
|
||||
uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: 1.19.1
|
||||
- uses: actions/checkout@v3
|
||||
- uses: protocol/cache-go-action@v1
|
||||
- name: Check out Kubo
|
||||
uses: actions/checkout@v3
|
||||
- name: Restore Go cache
|
||||
uses: protocol/cache-go-action@v1
|
||||
with:
|
||||
name: ${{ github.job }}
|
||||
- run: |
|
||||
- name: 👉️ If this step failed, go to «Summary» (top left) → inspect the «Failures/Errors» table
|
||||
run: |
|
||||
make -j 1 test/unit/gotest.junit.xml &&
|
||||
[[ ! $(jq -s -c 'map(select(.Action == "fail")) | .[]' test/unit/gotest.json) ]]
|
||||
- uses: codecov/codecov-action@81cd2dc8148241f03f5839d295e000b8f761e378 # v3.1.0
|
||||
if: always()
|
||||
- name: Upload coverage to Codecov
|
||||
uses: codecov/codecov-action@81cd2dc8148241f03f5839d295e000b8f761e378 # v3.1.0
|
||||
if: failure() || success()
|
||||
with:
|
||||
name: unittests
|
||||
files: coverage/unit_tests.coverprofile
|
||||
- run: |
|
||||
- name: Test kubo-as-a-library example
|
||||
run: |
|
||||
# we want to first test with the kubo version in the go.mod file
|
||||
go test -v ./...
|
||||
|
||||
@ -59,8 +65,38 @@ jobs:
|
||||
mv go.mod.bak go.mod
|
||||
mv go.sum.bak go.sum
|
||||
working-directory: docs/examples/kubo-as-a-library
|
||||
- uses: actions/upload-artifact@v3
|
||||
- name: Create a proper JUnit XML report
|
||||
uses: pl-strflt/gotest-json-to-junit-xml@v1
|
||||
with:
|
||||
input: test/unit/gotest.json
|
||||
output: test/unit/gotest.junit.xml
|
||||
if: failure() || success()
|
||||
- name: Archive the JUnit XML report
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: unit
|
||||
path: test/unit/gotest.junit.xml
|
||||
if: always()
|
||||
if: failure() || success()
|
||||
- name: Create a HTML report
|
||||
uses: pl-strflt/junit-xml-to-html@v1
|
||||
with:
|
||||
mode: no-frames
|
||||
input: test/unit/gotest.junit.xml
|
||||
output: test/unit/gotest.html
|
||||
if: failure() || success()
|
||||
- name: Archive the HTML report
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: html
|
||||
path: test/unit/gotest.html
|
||||
if: failure() || success()
|
||||
- name: Create a Markdown report
|
||||
uses: pl-strflt/junit-xml-to-html@v1
|
||||
with:
|
||||
mode: summary
|
||||
input: test/unit/gotest.junit.xml
|
||||
output: test/unit/gotest.md
|
||||
if: failure() || success()
|
||||
- name: Set the summary
|
||||
run: cat test/unit/gotest.md >> $GITHUB_STEP_SUMMARY
|
||||
if: failure() || success()
|
||||
|
||||
3
.github/workflows/sync-release-assets.yml
vendored
3
.github/workflows/sync-release-assets.yml
vendored
@ -9,6 +9,9 @@ concurrency:
|
||||
group: release-assets-dist-sync
|
||||
cancel-in-progress: true
|
||||
|
||||
permissions:
|
||||
contents: write # to upload release asset
|
||||
|
||||
jobs:
|
||||
sync-github-and-dist-ipfs-tech:
|
||||
if: github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch'
|
||||
|
||||
@ -93,7 +93,7 @@ Checklist:
|
||||
- PR will be merged automatically once the diff is approved
|
||||
- `master` build will publish the artifacts to https://dist.ipfs.io in around 30 minutes
|
||||
- [ ] Ensure that the artifacts are available at https://dist.ipfs.io
|
||||
- [ ] Publish the RC to [the NPM package](https://www.npmjs.com/package/go-ipfs?activeTab=versions) by running https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml (it happens automatically but it is safe to speed up the process and kick of a run manually)
|
||||
- [ ] Publish the RC to [the NPM package](https://www.npmjs.com/package/go-ipfs?activeTab=versions) by running https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml (it happens automatically but it is safe to speed up the process and kick off a run manually)
|
||||
- [ ] Cut a pre-release on [GitHub](https://github.com/ipfs/kubo/releases) ([instructions](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository#creating-a-release), [example](https://github.com/ipfs/kubo/releases/tag/v0.17.0-rc1))
|
||||
- Use `vX.Y.Z-rcN` as the tag.
|
||||
- Link to the release issue in the description.
|
||||
@ -120,7 +120,7 @@ Checklist:
|
||||
- [ ] [Optional] Reply under a message about the issue in the #bifrost channel on FIL Slack once the RC is out. Send the message to the channel.
|
||||
- [ ] Check [metrics](https://protocollabs.grafana.net/d/8zlhkKTZk/gateway-slis-precomputed?orgId=1) every day.
|
||||
- Compare the metrics trends week over week.
|
||||
- If there is an unexpected variation in the trend, message the #bifrost channel on FIL Slack and ask for help investigation the cause.
|
||||
- If there is an unexpected variation in the trend, message the #bifrost channel on FIL Slack and ask for help investigating the cause.
|
||||
- [ ] IPFS Application Testing.
|
||||
- [ ] [IPFS Desktop](https://github.com/ipfs-shipyard/ipfs-desktop)
|
||||
- [ ] Upgrade to the RC in [ipfs-desktop](https://github.com/ipfs-shipyard/ipfs-desktop)
|
||||
@ -133,13 +133,13 @@ Checklist:
|
||||
- [ ] Start a fresh chromium or chrome instance using `chromium --user-data-dir=$(mktemp -d)` (macos `/Applications/Google\ Chrome.app/Contents/MacOS/Google\ Chrome --user-data-dir=$(mktemp -d)`)
|
||||
- [ ] Start a fresh firefox instance using `firefox --profile $(mktemp -d)` (macos `/Applications/Firefox.app/Contents/MacOS/firefox --profile $(mktemp -d)`)
|
||||
- [ ] Install IPFS Companion from [vendor-specific store](https://github.com/ipfs/ipfs-companion/#readme).
|
||||
- [ ] Check that the comunication between Kubo daemon and IPFS companion is working properly checking if the number of connected peers changes.
|
||||
- [ ] Check that the communication between Kubo daemon and IPFS companion is working properly checking if the number of connected peers changes.
|
||||
- [ ] **Stage 5 - Release** - _ONLY FOR FINAL RELEASE_
|
||||
- [ ] Prepare the `release` branch.
|
||||
- [ ] Bump the version in `version.go` in the `release-vX.Y.Z` branch to `X.Y.Z`.
|
||||
- [ ] Update the [docs/changelogs/vX.Y.md](docs/changelogs) with the new commits and contributors.
|
||||
- [ ] Run `./bin/mkreleaselog` twice to generate the changelog and copy the output.
|
||||
- The first run of the script might be poluted with `git clone` output.
|
||||
- The first run of the script might be polluted with `git clone` output.
|
||||
- [ ] Paste the output into the `### Changelog` section of the changelog file inside the `<details><summary></summary></details>` block.
|
||||
- [ ] Commit the changelog changes.
|
||||
- [ ] Push the `release-vX.Y.Z` branch to GitHub (`git push origin release-vX.Y.Z`)
|
||||
@ -169,7 +169,7 @@ Checklist:
|
||||
- PR will be merged automatically once the diff is approved
|
||||
- `master` build will publish the artifacts to https://dist.ipfs.io in around 30 minutes
|
||||
- [ ] Ensure that the artifacts are available at https://dist.ipfs.io
|
||||
- [ ] Publish the release to [the NPM package](https://www.npmjs.com/package/go-ipfs?activeTab=versions) by running https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml (it happens automatically but it is safe to speed up the process and kick of a run manually)
|
||||
- [ ] Publish the release to [the NPM package](https://www.npmjs.com/package/go-ipfs?activeTab=versions) by running https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml (it happens automatically but it is safe to speed up the process and kick off a run manually)
|
||||
- [ ] Cut the release on [GitHub](https://github.com/ipfs/kubo/releases) ([instructions](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository#creating-a-release), [example](https://github.com/ipfs/kubo/releases/tag/v0.17.0))
|
||||
- Use `vX.Y.Z` as the tag.
|
||||
- Copy the relevant [changelog](https://github.com/ipfs/kubo/blob/release/docs/changelogs/) into the release description.
|
||||
|
||||
@ -88,22 +88,22 @@ Below is an outline of all that is in this release, so you get a sense of all th
|
||||
|
||||
<!-- TOC depthfrom:3 -->
|
||||
|
||||
- [Overview](#overview)
|
||||
- [🔦 Highlights](#-highlights)
|
||||
- [Content routing](#content-routing)
|
||||
- [Default InterPlanetary Network Indexer](#default-interplanetary-network-indexer)
|
||||
- [Increase provider record republish interval and expiration](#increase-provider-record-republish-interval-and-expiration)
|
||||
- [Gateways](#gateways)
|
||||
- [(DAG-)JSON and (DAG-)CBOR response formats](#dag-json-and-dag-cbor-response-formats)
|
||||
- [🐎 Fast directory listings with DAG sizes](#-fast-directory-listings-with-dag-sizes)
|
||||
- [QUIC and WebTransport](#quic-and-webtransport)
|
||||
- [WebTransport enabled by default](#webtransport-enabled-by-default)
|
||||
- [QUIC and WebTransport share a single port](#quic-and-webtransport-share-a-single-port)
|
||||
- [Differentiating QUIC versions](#differentiating-quic-versions)
|
||||
- [QUICv1 and WebTransport config migration](#quicv1-and-webtransport-config-migration)
|
||||
- [Improving libp2p resource management integration](#improving-libp2p-resource-management-integration)
|
||||
- [📝 Changelog](#-changelog)
|
||||
- [👨👩👧👦 Contributors](#-contributors)
|
||||
- [Overview](#overview)
|
||||
- [🔦 Highlights](#-highlights)
|
||||
- [Content routing](#content-routing)
|
||||
- [Default InterPlanetary Network Indexer](#default-interplanetary-network-indexer)
|
||||
- [Increase provider record republish interval and expiration](#increase-provider-record-republish-interval-and-expiration)
|
||||
- [Gateways](#gateways)
|
||||
- [(DAG-)JSON and (DAG-)CBOR response formats](#dag-json-and-dag-cbor-response-formats)
|
||||
- [🐎 Fast directory listings with DAG sizes](#-fast-directory-listings-with-dag-sizes)
|
||||
- [QUIC and WebTransport](#quic-and-webtransport)
|
||||
- [WebTransport enabled by default](#webtransport-enabled-by-default)
|
||||
- [QUIC and WebTransport share a single port](#quic-and-webtransport-share-a-single-port)
|
||||
- [Differentiating QUIC versions](#differentiating-quic-versions)
|
||||
- [QUICv1 and WebTransport config migration](#quicv1-and-webtransport-config-migration)
|
||||
- [Improving libp2p resource management integration](#improving-libp2p-resource-management-integration)
|
||||
- [📝 Changelog](#-changelog)
|
||||
- [👨👩👧👦 Contributors](#-contributors)
|
||||
|
||||
<!-- /TOC -->
|
||||
|
||||
|
||||
@ -7,7 +7,6 @@
|
||||
- [Overview](#overview)
|
||||
- [🔦 Highlights](#-highlights)
|
||||
- [Improving the libp2p resource management integration](#improving-the-libp2p-resource-management-integration)
|
||||
- [PubSub message caching improvements](#pubsub-message-caching-improvements)
|
||||
- [Gateways](#gateways)
|
||||
- [Signed IPNS Record response format](#signed-ipns-record-response-format)
|
||||
- [Example fetch and inspect IPNS record](#example-fetch-and-inspect-ipns-record)
|
||||
@ -21,6 +20,7 @@
|
||||
### 🔦 Highlights
|
||||
|
||||
#### Improving the libp2p resource management integration
|
||||
|
||||
There are further followups up on libp2p resource manager improvements in Kubo [0.18.0](https://github.com/ipfs/kubo/blob/master/docs/changelogs/v0.18.md#improving-libp2p-resource-management-integration-1)
|
||||
and [0.18.1](https://github.com/ipfs/kubo/blob/master/docs/changelogs/v0.18.md#improving-libp2p-resource-management-integration):
|
||||
1. `ipfs swarm limits` and `ipfs swarm stats` have been replaced by `ipfs swarm resources` to provide a single/combined view for limits and their current usage in a more intuitive ordering.
|
||||
@ -28,10 +28,6 @@ and [0.18.1](https://github.com/ipfs/kubo/blob/master/docs/changelogs/v0.18.md#i
|
||||
- Note: we don't expect most users to need these capablities, but they are there if so.
|
||||
1. [Doc updates](https://github.com/ipfs/kubo/blob/master/docs/libp2p-resource-management.md).
|
||||
|
||||
#### PubSub message caching improvements
|
||||
|
||||
The PubSub message cache will now [prune messages after TTL is exhausted](https://github.com/ipfs/kubo/blob/master/docs/config.md#pubsubseenmessagesttl), [either based on the last time a message was seen or the first time it was seen](https://github.com/ipfs/kubo/blob/master/docs/config.md#pubsubseenmessagesstrategy).
|
||||
|
||||
#### Gateways
|
||||
|
||||
##### Signed IPNS Record response format
|
||||
|
||||
@ -454,7 +454,7 @@ Type: `string` (one of `"enabled"` or `"disabled"`)
|
||||
|
||||
### `AutoNAT.Throttle`
|
||||
|
||||
When set, this option configure's the AutoNAT services throttling behavior. By
|
||||
When set, this option configures the AutoNAT services throttling behavior. By
|
||||
default, Kubo will rate-limit the number of NAT checks performed for other
|
||||
nodes to 30 per minute, and 3 per peer.
|
||||
|
||||
@ -616,7 +616,7 @@ Type: `bool`
|
||||
|
||||
#### `Discovery.MDNS.Interval`
|
||||
|
||||
**REMOVED:** this is not configurable any more
|
||||
**REMOVED:** this is not configurable anymore
|
||||
in the [new mDNS implementation](https://github.com/libp2p/zeroconf#readme).
|
||||
|
||||
## `Experimental`
|
||||
@ -966,7 +966,7 @@ Type: `optionalInteger` (thread count, `null` means default which is 8)
|
||||
#### `Internal.Bitswap.MaxOutstandingBytesPerPeer`
|
||||
|
||||
Maximum number of bytes (across all tasks) pending to be processed and sent to any individual peer.
|
||||
This number controls fairness and can very from 250Kb (very fair) to 10Mb (less fair, with more work
|
||||
This number controls fairness and can vary from 250Kb (very fair) to 10Mb (less fair, with more work
|
||||
dedicated to peers who ask for more). Values below 250Kb could cause thrashing.
|
||||
Values above 10Mb open the potential for aggressively-wanting peers to consume all resources and
|
||||
deteriorate the quality provided to less aggressively-wanting peers.
|
||||
|
||||
@ -13,7 +13,7 @@ Now we need a better way to add different routers using different protocols like
|
||||
|
||||
## Motivation
|
||||
|
||||
The actual routing implementation is not enough. Some users needs to have more options when configuring the routing system. The new implementations should be able to:
|
||||
The actual routing implementation is not enough. Some users need to have more options when configuring the routing system. The new implementations should be able to:
|
||||
|
||||
- [x] Be user-friendly and easy enough to configure, but also versatile
|
||||
- [x] Configurable Router execution order
|
||||
|
||||
@ -7,7 +7,7 @@ go 1.18
|
||||
replace github.com/ipfs/kubo => ./../../..
|
||||
|
||||
require (
|
||||
github.com/ipfs/go-libipfs v0.6.2
|
||||
github.com/ipfs/go-libipfs v0.7.0
|
||||
github.com/ipfs/interface-go-ipfs-core v0.11.0
|
||||
github.com/ipfs/kubo v0.0.0-00010101000000-000000000000
|
||||
github.com/libp2p/go-libp2p v0.26.3
|
||||
@ -65,7 +65,7 @@ require (
|
||||
github.com/ipfs/go-bitfield v1.1.0 // indirect
|
||||
github.com/ipfs/go-block-format v0.1.1 // indirect
|
||||
github.com/ipfs/go-blockservice v0.5.0 // indirect
|
||||
github.com/ipfs/go-cid v0.3.2 // indirect
|
||||
github.com/ipfs/go-cid v0.4.0 // indirect
|
||||
github.com/ipfs/go-cidutil v0.1.0 // indirect
|
||||
github.com/ipfs/go-datastore v0.6.0 // indirect
|
||||
github.com/ipfs/go-delegated-routing v0.7.0 // indirect
|
||||
|
||||
@ -460,8 +460,8 @@ github.com/ipfs/go-cid v0.0.5/go.mod h1:plgt+Y5MnOey4vO4UlUazGqdbEXuFYitED67Fexh
|
||||
github.com/ipfs/go-cid v0.0.6/go.mod h1:6Ux9z5e+HpkQdckYoX1PG/6xqKspzlEIR5SDmgqgC/I=
|
||||
github.com/ipfs/go-cid v0.0.7/go.mod h1:6Ux9z5e+HpkQdckYoX1PG/6xqKspzlEIR5SDmgqgC/I=
|
||||
github.com/ipfs/go-cid v0.1.0/go.mod h1:rH5/Xv83Rfy8Rw6xG+id3DYAMUVmem1MowoKwdXmN2o=
|
||||
github.com/ipfs/go-cid v0.3.2 h1:OGgOd+JCFM+y1DjWPmVH+2/4POtpDzwcr7VgnB7mZXc=
|
||||
github.com/ipfs/go-cid v0.3.2/go.mod h1:gQ8pKqT/sUxGY+tIwy1RPpAojYu7jAyCp5Tz1svoupw=
|
||||
github.com/ipfs/go-cid v0.4.0 h1:a4pdZq0sx6ZSxbCizebnKiMCx/xI/aBBFlB73IgH4rA=
|
||||
github.com/ipfs/go-cid v0.4.0/go.mod h1:uQHwDeX4c6CtyrFwdqyhpNcxVewur1M7l7fNU7LKwZk=
|
||||
github.com/ipfs/go-cidutil v0.1.0 h1:RW5hO7Vcf16dplUU60Hs0AKDkQAVPVplr7lk97CFL+Q=
|
||||
github.com/ipfs/go-cidutil v0.1.0/go.mod h1:e7OEVBMIv9JaOxt9zaGEmAoSlXW9jdFZ5lP/0PwcfpA=
|
||||
github.com/ipfs/go-datastore v0.0.1/go.mod h1:d4KVXhMt913cLBEI/PXAy6ko+W7e9AhyAKBGh803qeE=
|
||||
@ -569,8 +569,8 @@ github.com/ipfs/go-ipld-legacy v0.1.1 h1:BvD8PEuqwBHLTKqlGFTHSwrwFOMkVESEvwIYwR2
|
||||
github.com/ipfs/go-ipld-legacy v0.1.1/go.mod h1:8AyKFCjgRPsQFf15ZQgDB8Din4DML/fOmKZkkFkrIEg=
|
||||
github.com/ipfs/go-ipns v0.3.0 h1:ai791nTgVo+zTuq2bLvEGmWP1M0A6kGTXUsgv/Yq67A=
|
||||
github.com/ipfs/go-ipns v0.3.0/go.mod h1:3cLT2rbvgPZGkHJoPO1YMJeh6LtkxopCkKFcio/wE24=
|
||||
github.com/ipfs/go-libipfs v0.6.2 h1:QUf3kS3RrCjgtE0QW2d18PFFfOLeEt24Ft892ipLzRI=
|
||||
github.com/ipfs/go-libipfs v0.6.2/go.mod h1:FmhKgxMOQA572TK5DA3MZ5GL44ZqsMHIrkgK4gLn4A8=
|
||||
github.com/ipfs/go-libipfs v0.7.0 h1:Mi54WJTODaOL2/ZSm5loi3SwI3jI2OuFWUrQIkJ5cpM=
|
||||
github.com/ipfs/go-libipfs v0.7.0/go.mod h1:KsIf/03CqhICzyRGyGo68tooiBE2iFbI/rXW7FhAYr0=
|
||||
github.com/ipfs/go-log v0.0.1/go.mod h1:kL1d2/hzSpI0thNYjiKfjanbVNU+IIGA/WnNESY9leM=
|
||||
github.com/ipfs/go-log v1.0.2/go.mod h1:1MNjMxe0u6xvJZgeqbJ8vdo2TKaGwZ1a0Bpza+sr2Sk=
|
||||
github.com/ipfs/go-log v1.0.3/go.mod h1:OsLySYkwIbiSUR/yBTdv1qPtcE4FW3WPWk/ewz9Ru+A=
|
||||
|
||||
4
go.mod
4
go.mod
@ -17,7 +17,7 @@ require (
|
||||
github.com/google/uuid v1.3.0
|
||||
github.com/hashicorp/go-multierror v1.1.1
|
||||
github.com/ipfs/go-blockservice v0.5.0
|
||||
github.com/ipfs/go-cid v0.3.2
|
||||
github.com/ipfs/go-cid v0.4.0
|
||||
github.com/ipfs/go-cidutil v0.1.0
|
||||
github.com/ipfs/go-datastore v0.6.0
|
||||
github.com/ipfs/go-delegated-routing v0.7.0
|
||||
@ -45,7 +45,7 @@ require (
|
||||
github.com/ipfs/go-ipld-git v0.1.1
|
||||
github.com/ipfs/go-ipld-legacy v0.1.1
|
||||
github.com/ipfs/go-ipns v0.3.0
|
||||
github.com/ipfs/go-libipfs v0.6.2
|
||||
github.com/ipfs/go-libipfs v0.7.0
|
||||
github.com/ipfs/go-log v1.0.5
|
||||
github.com/ipfs/go-log/v2 v2.5.1
|
||||
github.com/ipfs/go-merkledag v0.9.0
|
||||
|
||||
8
go.sum
8
go.sum
@ -478,8 +478,8 @@ github.com/ipfs/go-cid v0.0.5/go.mod h1:plgt+Y5MnOey4vO4UlUazGqdbEXuFYitED67Fexh
|
||||
github.com/ipfs/go-cid v0.0.6/go.mod h1:6Ux9z5e+HpkQdckYoX1PG/6xqKspzlEIR5SDmgqgC/I=
|
||||
github.com/ipfs/go-cid v0.0.7/go.mod h1:6Ux9z5e+HpkQdckYoX1PG/6xqKspzlEIR5SDmgqgC/I=
|
||||
github.com/ipfs/go-cid v0.1.0/go.mod h1:rH5/Xv83Rfy8Rw6xG+id3DYAMUVmem1MowoKwdXmN2o=
|
||||
github.com/ipfs/go-cid v0.3.2 h1:OGgOd+JCFM+y1DjWPmVH+2/4POtpDzwcr7VgnB7mZXc=
|
||||
github.com/ipfs/go-cid v0.3.2/go.mod h1:gQ8pKqT/sUxGY+tIwy1RPpAojYu7jAyCp5Tz1svoupw=
|
||||
github.com/ipfs/go-cid v0.4.0 h1:a4pdZq0sx6ZSxbCizebnKiMCx/xI/aBBFlB73IgH4rA=
|
||||
github.com/ipfs/go-cid v0.4.0/go.mod h1:uQHwDeX4c6CtyrFwdqyhpNcxVewur1M7l7fNU7LKwZk=
|
||||
github.com/ipfs/go-cidutil v0.1.0 h1:RW5hO7Vcf16dplUU60Hs0AKDkQAVPVplr7lk97CFL+Q=
|
||||
github.com/ipfs/go-cidutil v0.1.0/go.mod h1:e7OEVBMIv9JaOxt9zaGEmAoSlXW9jdFZ5lP/0PwcfpA=
|
||||
github.com/ipfs/go-datastore v0.0.1/go.mod h1:d4KVXhMt913cLBEI/PXAy6ko+W7e9AhyAKBGh803qeE=
|
||||
@ -591,8 +591,8 @@ github.com/ipfs/go-ipld-legacy v0.1.1 h1:BvD8PEuqwBHLTKqlGFTHSwrwFOMkVESEvwIYwR2
|
||||
github.com/ipfs/go-ipld-legacy v0.1.1/go.mod h1:8AyKFCjgRPsQFf15ZQgDB8Din4DML/fOmKZkkFkrIEg=
|
||||
github.com/ipfs/go-ipns v0.3.0 h1:ai791nTgVo+zTuq2bLvEGmWP1M0A6kGTXUsgv/Yq67A=
|
||||
github.com/ipfs/go-ipns v0.3.0/go.mod h1:3cLT2rbvgPZGkHJoPO1YMJeh6LtkxopCkKFcio/wE24=
|
||||
github.com/ipfs/go-libipfs v0.6.2 h1:QUf3kS3RrCjgtE0QW2d18PFFfOLeEt24Ft892ipLzRI=
|
||||
github.com/ipfs/go-libipfs v0.6.2/go.mod h1:FmhKgxMOQA572TK5DA3MZ5GL44ZqsMHIrkgK4gLn4A8=
|
||||
github.com/ipfs/go-libipfs v0.7.0 h1:Mi54WJTODaOL2/ZSm5loi3SwI3jI2OuFWUrQIkJ5cpM=
|
||||
github.com/ipfs/go-libipfs v0.7.0/go.mod h1:KsIf/03CqhICzyRGyGo68tooiBE2iFbI/rXW7FhAYr0=
|
||||
github.com/ipfs/go-log v0.0.1/go.mod h1:kL1d2/hzSpI0thNYjiKfjanbVNU+IIGA/WnNESY9leM=
|
||||
github.com/ipfs/go-log v1.0.2/go.mod h1:1MNjMxe0u6xvJZgeqbJ8vdo2TKaGwZ1a0Bpza+sr2Sk=
|
||||
github.com/ipfs/go-log v1.0.3/go.mod h1:OsLySYkwIbiSUR/yBTdv1qPtcE4FW3WPWk/ewz9Ru+A=
|
||||
|
||||
@ -126,10 +126,10 @@ func TestGateway(t *testing.T) {
|
||||
assert.Equal(t, 404, resp.StatusCode)
|
||||
})
|
||||
|
||||
t.Run("GET IPFS invalid CID returns 500 (Internal Server Error)", func(t *testing.T) {
|
||||
t.Run("GET IPFS invalid CID returns 400 (Bad Request)", func(t *testing.T) {
|
||||
t.Parallel()
|
||||
resp := client.Get("/ipfs/QmInvalid/pleaseDontAddMe")
|
||||
assert.Equal(t, 500, resp.StatusCode)
|
||||
assert.Equal(t, 400, resp.StatusCode)
|
||||
})
|
||||
|
||||
t.Run("GET IPFS inlined zero-length data object returns ok code (200)", func(t *testing.T) {
|
||||
@ -198,7 +198,7 @@ func TestGateway(t *testing.T) {
|
||||
|
||||
t.Run("GET invalid IPFS path errors", func(t *testing.T) {
|
||||
t.Parallel()
|
||||
assert.Equal(t, 500, client.Get("/ipfs/12345").StatusCode)
|
||||
assert.Equal(t, 400, client.Get("/ipfs/12345").StatusCode)
|
||||
})
|
||||
|
||||
t.Run("GET invalid path errors", func(t *testing.T) {
|
||||
@ -406,7 +406,7 @@ func TestGateway(t *testing.T) {
|
||||
gatewayAddr := URLStrToMultiaddr(node.GatewayURL())
|
||||
res := node.RunIPFS("--api", gatewayAddr.String(), "refs", "local")
|
||||
assert.Equal(t,
|
||||
`Error: invalid path "local": selected encoding not supported`,
|
||||
`Error: invalid path "local": invalid cid: selected encoding not supported`,
|
||||
res.Stderr.Trimmed(),
|
||||
)
|
||||
})
|
||||
|
||||
@ -129,7 +129,7 @@ test_get_cmd() {
|
||||
'
|
||||
|
||||
test_expect_success "ipfs get ../.. should fail" '
|
||||
echo "Error: invalid path \"../..\": selected encoding not supported" >expected &&
|
||||
echo "Error: invalid path \"../..\": invalid cid: selected encoding not supported" >expected &&
|
||||
test_must_fail ipfs get ../.. 2>actual &&
|
||||
test_cmp expected actual
|
||||
'
|
||||
|
||||
@ -11,7 +11,7 @@ import (
|
||||
var CurrentCommit string
|
||||
|
||||
// CurrentVersionNumber is the current application's version literal
|
||||
const CurrentVersionNumber = "0.19.0"
|
||||
const CurrentVersionNumber = "0.20.0-dev"
|
||||
|
||||
const ApiVersion = "/kubo/" + CurrentVersionNumber + "/" //nolint
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user