From e17753e95199c55d28b09afcdb1583207e018714 Mon Sep 17 00:00:00 2001 From: Jorropo Date: Thu, 11 Jan 2024 09:56:27 +0100 Subject: [PATCH 01/23] docs: in RELEASE_ISSUE_TEMPLATE ask releaser to ensure we are using the latest go release on the major branch --- docs/RELEASE_ISSUE_TEMPLATE.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/RELEASE_ISSUE_TEMPLATE.md b/docs/RELEASE_ISSUE_TEMPLATE.md index 0b10ea8aea9..26e5ad5bef2 100644 --- a/docs/RELEASE_ISSUE_TEMPLATE.md +++ b/docs/RELEASE_ISSUE_TEMPLATE.md @@ -116,6 +116,7 @@ This section covers tasks to be done during each release. - [ ] Publish the release to [DockerHub](https://hub.docker.com/r/ipfs/kubo/)
using `./kuboreleaser --skip-check-before --skip-run release --version vX.Y.Z(-rcN) publish-to-dockerhub` or ... - [ ] Wait for [Publish docker image](https://github.com/ipfs/kubo/actions/workflows/docker-image.yml) workflow run initiated by the tag push to finish - [ ] verify the image is available on [Docker Hub](https://hub.docker.com/r/ipfs/kubo/tags) +- [ ] Verify [ipfs/distributions](https://github.com/ipfs/distributions)'s `.tool-versions`'s `golang` entry is set to the [latest go release](https://go.dev/doc/devel/release) on the major go branch [Kubo is being tested on](https://github.com/ipfs/kubo/blob/master/.github/workflows/gotest.yml) (see `go-version:`). - [ ] Publish the release to [dist.ipfs.tech](https://dist.ipfs.tech)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-distributions` or ... - [ ] check out [ipfs/distributions](https://github.com/ipfs/distributions) - [ ] run `./dist.sh add-version kubo vX.Y.Z(-RCN)` to add the new version to the `versions` file From 2963f1051b3b8ab8f6a4a4bd9e58d15b5eea9be8 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Thu, 11 Jan 2024 10:56:31 +0100 Subject: [PATCH 02/23] chore: increase time of sync-release-assets Need to increase the time so we can release 0.26.0-rc1. It seems that getting the assets is taking a bit longer than normal https://github.com/ipfs/kubo/actions/runs/7486931561/job/20378282844 --- .github/workflows/sync-release-assets.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sync-release-assets.yml b/.github/workflows/sync-release-assets.yml index bc7eaed8d98..12aec86cb7a 100644 --- a/.github/workflows/sync-release-assets.yml +++ b/.github/workflows/sync-release-assets.yml @@ -16,7 +16,7 @@ jobs: dist-ipfs-tech: if: github.repository == 'ipfs/kubo' || github.event_name == 'workflow_dispatch' runs-on: "ubuntu-latest" - timeout-minutes: 5 + timeout-minutes: 15 steps: - uses: ipfs/download-ipfs-distribution-action@v1 - uses: ipfs/start-ipfs-daemon-action@v1 From 8978b5455aa768f527b53034032f8397ed2709ec Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Thu, 11 Jan 2024 08:14:30 +0000 Subject: [PATCH 03/23] chore: update version --- version.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/version.go b/version.go index 93f181c37cd..d5b0642f87a 100644 --- a/version.go +++ b/version.go @@ -11,7 +11,7 @@ import ( var CurrentCommit string // CurrentVersionNumber is the current application's version literal. -const CurrentVersionNumber = "0.26.0-dev" +const CurrentVersionNumber = "0.27.0-dev" const ApiVersion = "/kubo/" + CurrentVersionNumber + "/" //nolint From 43629b5a7f761e18eadd4311519a46196019209e Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 19:14:36 +0000 Subject: [PATCH 04/23] chore(deps): bump docker/setup-qemu-action from 2 to 3 Bumps [docker/setup-qemu-action](https://github.com/docker/setup-qemu-action) from 2 to 3. - [Release notes](https://github.com/docker/setup-qemu-action/releases) - [Commits](https://github.com/docker/setup-qemu-action/compare/v2...v3) --- updated-dependencies: - dependency-name: docker/setup-qemu-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-image.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index c1e77112d1d..de01af4dccc 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -40,7 +40,7 @@ jobs: uses: actions/checkout@v4 - name: Set up QEMU - uses: docker/setup-qemu-action@v2 + uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 From 0ee0ec664a2e62a0bc28d4b03c77451bcc0b1030 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 19:14:43 +0000 Subject: [PATCH 05/23] chore(deps): bump docker/login-action from 2.2.0 to 3.0.0 Bumps [docker/login-action](https://github.com/docker/login-action) from 2.2.0 to 3.0.0. - [Release notes](https://github.com/docker/login-action/releases) - [Commits](https://github.com/docker/login-action/compare/465a07811f14bebb1938fbed4728c6a1ff8901fc...343f7c4344506bcbf9b4de18042ae17996df046d) --- updated-dependencies: - dependency-name: docker/login-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-image.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index de01af4dccc..d7765d6e0cf 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -63,7 +63,7 @@ jobs: shell: bash - name: Log in to Docker Hub - uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc + uses: docker/login-action@343f7c4344506bcbf9b4de18042ae17996df046d with: username: ${{ vars.DOCKER_USERNAME }} password: ${{ secrets.DOCKER_PASSWORD }} From 2a33a0776061ced6b2fd0773939945cd74d90a50 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 19:14:44 +0000 Subject: [PATCH 06/23] chore(deps): bump actions/setup-node from 3 to 4 Bumps [actions/setup-node](https://github.com/actions/setup-node) from 3 to 4. - [Release notes](https://github.com/actions/setup-node/releases) - [Commits](https://github.com/actions/setup-node/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/setup-node dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/build.yml | 4 ++-- .github/workflows/sync-release-assets.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3b30da2b414..22520f9b8cc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -53,7 +53,7 @@ jobs: run: shell: bash steps: - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: lts/* - uses: actions/download-artifact@v3 @@ -109,7 +109,7 @@ jobs: run: shell: bash steps: - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 18.14.0 - uses: actions/download-artifact@v3 diff --git a/.github/workflows/sync-release-assets.yml b/.github/workflows/sync-release-assets.yml index 12aec86cb7a..8a39f32345f 100644 --- a/.github/workflows/sync-release-assets.yml +++ b/.github/workflows/sync-release-assets.yml @@ -22,7 +22,7 @@ jobs: - uses: ipfs/start-ipfs-daemon-action@v1 with: args: --init --init-profile=flatfs,server --enable-gc=false - - uses: actions/setup-node@v3 + - uses: actions/setup-node@v4 with: node-version: 14 - name: Sync the latest 5 github releases From 24b223ceacad9b902d83f97747671001f0228b89 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 19:14:43 +0000 Subject: [PATCH 07/23] chore(deps): bump docker/build-push-action from 4 to 5 Bumps [docker/build-push-action](https://github.com/docker/build-push-action) from 4 to 5. - [Release notes](https://github.com/docker/build-push-action/releases) - [Commits](https://github.com/docker/build-push-action/compare/v4...v5) --- updated-dependencies: - dependency-name: docker/build-push-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-image.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index d7765d6e0cf..7c32418a515 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -72,7 +72,7 @@ jobs: # builds, only one platform is being loaded into the cache. This would # prevent us from testing the other platforms. - name: Build Docker image (linux/amd64) - uses: docker/build-push-action@v4 + uses: docker/build-push-action@v5 with: platforms: linux/amd64 context: . @@ -84,7 +84,7 @@ jobs: cache-to: type=local,dest=/tmp/.buildx-cache-new - name: Build Docker image (linux/arm/v7) - uses: docker/build-push-action@v4 + uses: docker/build-push-action@v5 with: platforms: linux/arm/v7 context: . @@ -96,7 +96,7 @@ jobs: cache-to: type=local,dest=/tmp/.buildx-cache-new - name: Build Docker image (linux/arm64/v8) - uses: docker/build-push-action@v4 + uses: docker/build-push-action@v5 with: platforms: linux/arm64/v8 context: . @@ -116,7 +116,7 @@ jobs: # This will only push the previously built images. - if: github.event_name != 'workflow_dispatch' || github.event.inputs.push == 'true' name: Publish to Docker Hub - uses: docker/build-push-action@v4 + uses: docker/build-push-action@v5 with: platforms: linux/amd64,linux/arm/v7,linux/arm64/v8 context: . From 75f39a40cb3b5fcbdd7f5b631899769d6231a31c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 19:14:40 +0000 Subject: [PATCH 08/23] chore(deps): bump docker/setup-buildx-action from 2 to 3 Bumps [docker/setup-buildx-action](https://github.com/docker/setup-buildx-action) from 2 to 3. - [Release notes](https://github.com/docker/setup-buildx-action/releases) - [Commits](https://github.com/docker/setup-buildx-action/compare/v2...v3) --- updated-dependencies: - dependency-name: docker/setup-buildx-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/docker-image.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/docker-image.yml b/.github/workflows/docker-image.yml index 7c32418a515..fe28293e743 100644 --- a/.github/workflows/docker-image.yml +++ b/.github/workflows/docker-image.yml @@ -43,7 +43,7 @@ jobs: uses: docker/setup-qemu-action@v3 - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 + uses: docker/setup-buildx-action@v3 - name: Cache Docker layers uses: actions/cache@v3 From 75f3c108327bcf13ae6aa10097271646c4b726e5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 11 Jan 2024 19:57:36 +0000 Subject: [PATCH 09/23] chore(deps): bump github.com/ipfs-shipyard/nopfs Bumps [github.com/ipfs-shipyard/nopfs](https://github.com/ipfs-shipyard/nopfs) from 0.0.12-0.20231027223058-cde3b5ba964c to 0.0.12. - [Release notes](https://github.com/ipfs-shipyard/nopfs/releases) - [Commits](https://github.com/ipfs-shipyard/nopfs/commits/v0.0.12) --- updated-dependencies: - dependency-name: github.com/ipfs-shipyard/nopfs dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- docs/examples/kubo-as-a-library/go.mod | 2 +- docs/examples/kubo-as-a-library/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/docs/examples/kubo-as-a-library/go.mod b/docs/examples/kubo-as-a-library/go.mod index 0c15ff98bfa..21ef07573a0 100644 --- a/docs/examples/kubo-as-a-library/go.mod +++ b/docs/examples/kubo-as-a-library/go.mod @@ -60,7 +60,7 @@ require ( github.com/hashicorp/golang-lru v1.0.2 // indirect github.com/hashicorp/golang-lru/v2 v2.0.7 // indirect github.com/huin/goupnp v1.3.0 // indirect - github.com/ipfs-shipyard/nopfs v0.0.12-0.20231027223058-cde3b5ba964c // indirect + github.com/ipfs-shipyard/nopfs v0.0.12 // indirect github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c // indirect github.com/ipfs/bbloom v0.0.4 // indirect github.com/ipfs/go-bitfield v1.1.0 // indirect diff --git a/docs/examples/kubo-as-a-library/go.sum b/docs/examples/kubo-as-a-library/go.sum index 93a1b4492e1..6fa09260f11 100644 --- a/docs/examples/kubo-as-a-library/go.sum +++ b/docs/examples/kubo-as-a-library/go.sum @@ -254,8 +254,8 @@ github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/ipfs-shipyard/nopfs v0.0.12-0.20231027223058-cde3b5ba964c h1:17FO7HnKiFhO7iadu3zCgII+EblpdRmJt5qg9FqQo8Y= -github.com/ipfs-shipyard/nopfs v0.0.12-0.20231027223058-cde3b5ba964c/go.mod h1:1oj4+g/mN6JRuZiXHt5iFRG02e62wp5AKcB3gdgknbk= +github.com/ipfs-shipyard/nopfs v0.0.12 h1:mvwaoefDF5VI9jyvgWCmaoTJIJFAfrbyQV5fJz35hlk= +github.com/ipfs-shipyard/nopfs v0.0.12/go.mod h1:mQyd0BElYI2gB/kq/Oue97obP4B3os4eBmgfPZ+hnrE= github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c h1:7UynTbtdlt+w08ggb1UGLGaGjp1mMaZhoTZSctpn5Ak= github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c/go.mod h1:6EekK/jo+TynwSE/ZOiOJd4eEvRXoavEC3vquKtv4yI= github.com/ipfs/bbloom v0.0.4 h1:Gi+8EGJ2y5qiD5FbsbpX/TMNcJw8gSqr7eyjHa4Fhvs= diff --git a/go.mod b/go.mod index d8440e9f0e3..bf197784fc1 100644 --- a/go.mod +++ b/go.mod @@ -15,7 +15,7 @@ require ( github.com/fsnotify/fsnotify v1.6.0 github.com/google/uuid v1.5.0 github.com/hashicorp/go-multierror v1.1.1 - github.com/ipfs-shipyard/nopfs v0.0.12-0.20231027223058-cde3b5ba964c + github.com/ipfs-shipyard/nopfs v0.0.12 github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c github.com/ipfs/boxo v0.17.0 github.com/ipfs/go-block-format v0.2.0 diff --git a/go.sum b/go.sum index 06ecc39ae34..7c80a6dd282 100644 --- a/go.sum +++ b/go.sum @@ -319,8 +319,8 @@ github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= -github.com/ipfs-shipyard/nopfs v0.0.12-0.20231027223058-cde3b5ba964c h1:17FO7HnKiFhO7iadu3zCgII+EblpdRmJt5qg9FqQo8Y= -github.com/ipfs-shipyard/nopfs v0.0.12-0.20231027223058-cde3b5ba964c/go.mod h1:1oj4+g/mN6JRuZiXHt5iFRG02e62wp5AKcB3gdgknbk= +github.com/ipfs-shipyard/nopfs v0.0.12 h1:mvwaoefDF5VI9jyvgWCmaoTJIJFAfrbyQV5fJz35hlk= +github.com/ipfs-shipyard/nopfs v0.0.12/go.mod h1:mQyd0BElYI2gB/kq/Oue97obP4B3os4eBmgfPZ+hnrE= github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c h1:7UynTbtdlt+w08ggb1UGLGaGjp1mMaZhoTZSctpn5Ak= github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c/go.mod h1:6EekK/jo+TynwSE/ZOiOJd4eEvRXoavEC3vquKtv4yI= github.com/ipfs/bbloom v0.0.4 h1:Gi+8EGJ2y5qiD5FbsbpX/TMNcJw8gSqr7eyjHa4Fhvs= From 9343a95f4d568deebde2df3a458f383be6934382 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Fri, 8 Dec 2023 16:19:58 +0100 Subject: [PATCH 10/23] docs(config): clarify ReproviderStrategy roots --- docs/config.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/config.md b/docs/config.md index 495e9090682..fd0c0a23ed3 100644 --- a/docs/config.md +++ b/docs/config.md @@ -1467,6 +1467,13 @@ Tells reprovider what should be announced. Valid strategies are: - `"all"` - announce all CIDs of stored blocks - `"pinned"` - only announce pinned CIDs recursively (both roots and child blocks) - `"roots"` - only announce the root block of explicitly pinned CIDs + - **⚠️ BE CAREFUL:** node with `roots` strategy will not announce child blocks. + It makes sense only for use cases where the entire DAG is fetched in full, + and a graceful resume does not have to be guaranteed: the lack of child + announcements means an interrupted retrieval won't be able to find + providers for the missing block in the middle of a file, unless the peer + happens to already be connected to a provider and ask for child CID over + bitswap. Default: `"all"` From 2738b49c1a22b742993f424725aa378fc53deec1 Mon Sep 17 00:00:00 2001 From: Jorropo Date: Thu, 30 Nov 2023 11:49:50 +0100 Subject: [PATCH 11/23] profile: add trace --- core/commands/profile.go | 1 + profile/profile.go | 16 ++++++++++++++++ profile/profile_test.go | 1 + 3 files changed, 18 insertions(+) diff --git a/core/commands/profile.go b/core/commands/profile.go index d25711dac22..9f54e0612e7 100644 --- a/core/commands/profile.go +++ b/core/commands/profile.go @@ -85,6 +85,7 @@ However, it could reveal: profile.CollectorCPU, profile.CollectorMutex, profile.CollectorBlock, + profile.CollectorTrace, }), cmds.StringOption(profileTimeOption, "The amount of time spent profiling. If this is set to 0, then sampling profiles are skipped.").WithDefault("30s"), cmds.IntOption(mutexProfileFractionOption, "The fraction 1/n of mutex contention events that are reported in the mutex profile.").WithDefault(4), diff --git a/profile/profile.go b/profile/profile.go index b9ad86d2f53..be1e5adbb62 100644 --- a/profile/profile.go +++ b/profile/profile.go @@ -10,6 +10,7 @@ import ( "os" "runtime" "runtime/pprof" + "runtime/trace" "sync" "time" @@ -27,6 +28,7 @@ const ( CollectorCPU = "cpu" CollectorMutex = "mutex" CollectorBlock = "block" + CollectorTrace = "trace" ) var ( @@ -98,6 +100,11 @@ var collectors = map[string]collector{ collectFunc: blockProfile, enabledFunc: func(opts Options) bool { return opts.ProfileDuration > 0 && opts.BlockProfileRate > 0 }, }, + CollectorTrace: { + outputFile: "trace", + collectFunc: captureTrace, + enabledFunc: func(opts Options) bool { return opts.ProfileDuration > 0 }, + }, } type Options struct { @@ -266,6 +273,15 @@ func profileCPU(ctx context.Context, opts Options, w io.Writer) error { return waitOrCancel(ctx, opts.ProfileDuration) } +func captureTrace(ctx context.Context, opts Options, w io.Writer) error { + err := trace.Start(w) + if err != nil { + return err + } + defer trace.Stop() + return waitOrCancel(ctx, opts.ProfileDuration) +} + func waitOrCancel(ctx context.Context, d time.Duration) error { timer := time.NewTimer(d) defer timer.Stop() diff --git a/profile/profile_test.go b/profile/profile_test.go index a2fe0b51d59..0c06b00de4b 100644 --- a/profile/profile_test.go +++ b/profile/profile_test.go @@ -22,6 +22,7 @@ func TestProfiler(t *testing.T) { CollectorCPU, CollectorMutex, CollectorBlock, + CollectorTrace, } cases := []struct { From 21b820a5ef8ad5ef7093a58a6443a3bf6800b545 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Fri, 12 Jan 2024 14:46:49 +0100 Subject: [PATCH 12/23] fix: profiling tests --- profile/profile_test.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/profile/profile_test.go b/profile/profile_test.go index 0c06b00de4b..6c2f5784e10 100644 --- a/profile/profile_test.go +++ b/profile/profile_test.go @@ -50,6 +50,7 @@ func TestProfiler(t *testing.T) { "cpu.pprof", "mutex.pprof", "block.pprof", + "trace", }, }, { @@ -71,6 +72,7 @@ func TestProfiler(t *testing.T) { "cpu.pprof", "mutex.pprof", "block.pprof", + "trace", }, }, { @@ -105,6 +107,7 @@ func TestProfiler(t *testing.T) { "ipfs", "cpu.pprof", "block.pprof", + "trace", }, }, { @@ -124,6 +127,7 @@ func TestProfiler(t *testing.T) { "ipfs", "cpu.pprof", "mutex.pprof", + "trace", }, }, { From 982d8a92c0401255f596dfa1b0240b6a63eca8ca Mon Sep 17 00:00:00 2001 From: Jorropo Date: Fri, 12 Jan 2024 14:02:45 +0100 Subject: [PATCH 13/23] chore: update boxo --- docs/examples/kubo-as-a-library/go.mod | 2 +- docs/examples/kubo-as-a-library/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- test/dependencies/go.mod | 2 +- test/dependencies/go.sum | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/docs/examples/kubo-as-a-library/go.mod b/docs/examples/kubo-as-a-library/go.mod index 21ef07573a0..2582305b66c 100644 --- a/docs/examples/kubo-as-a-library/go.mod +++ b/docs/examples/kubo-as-a-library/go.mod @@ -7,7 +7,7 @@ go 1.20 replace github.com/ipfs/kubo => ./../../.. require ( - github.com/ipfs/boxo v0.17.0 + github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5 github.com/ipfs/kubo v0.0.0-00010101000000-000000000000 github.com/libp2p/go-libp2p v0.32.2 github.com/multiformats/go-multiaddr v0.12.1 diff --git a/docs/examples/kubo-as-a-library/go.sum b/docs/examples/kubo-as-a-library/go.sum index 6fa09260f11..5cb425214b2 100644 --- a/docs/examples/kubo-as-a-library/go.sum +++ b/docs/examples/kubo-as-a-library/go.sum @@ -260,8 +260,8 @@ github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c h1:7Uy github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c/go.mod h1:6EekK/jo+TynwSE/ZOiOJd4eEvRXoavEC3vquKtv4yI= github.com/ipfs/bbloom v0.0.4 h1:Gi+8EGJ2y5qiD5FbsbpX/TMNcJw8gSqr7eyjHa4Fhvs= github.com/ipfs/bbloom v0.0.4/go.mod h1:cS9YprKXpoZ9lT0n/Mw/a6/aFV6DTjTLYHeA+gyqMG0= -github.com/ipfs/boxo v0.17.0 h1:fVXAb12dNbraCX1Cdid5BB6Kl62gVLNVA+e0EYMqAU0= -github.com/ipfs/boxo v0.17.0/go.mod h1:pIZgTWdm3k3pLF9Uq6MB8JEcW07UDwNJjlXW1HELW80= +github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5 h1:qGPYOK8flU2YzHGq9Cb2Yeo0jjOwompAOzxOv3VSGx8= +github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5/go.mod h1:pIZgTWdm3k3pLF9Uq6MB8JEcW07UDwNJjlXW1HELW80= github.com/ipfs/go-bitfield v1.1.0 h1:fh7FIo8bSwaJEh6DdTWbCeZ1eqOaOkKFI74SCnsWbGA= github.com/ipfs/go-bitfield v1.1.0/go.mod h1:paqf1wjq/D2BBmzfTVFlJQ9IlFOZpg422HL0HqsGWHU= github.com/ipfs/go-block-format v0.0.3/go.mod h1:4LmD4ZUw0mhO+JSKdpWwrzATiEfM7WWgQ8H5l6P8MVk= diff --git a/go.mod b/go.mod index bf197784fc1..9e94c0f228c 100644 --- a/go.mod +++ b/go.mod @@ -17,7 +17,7 @@ require ( github.com/hashicorp/go-multierror v1.1.1 github.com/ipfs-shipyard/nopfs v0.0.12 github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c - github.com/ipfs/boxo v0.17.0 + github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5 github.com/ipfs/go-block-format v0.2.0 github.com/ipfs/go-cid v0.4.1 github.com/ipfs/go-cidutil v0.1.0 diff --git a/go.sum b/go.sum index 7c80a6dd282..3b8feab094b 100644 --- a/go.sum +++ b/go.sum @@ -325,8 +325,8 @@ github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c h1:7Uy github.com/ipfs-shipyard/nopfs/ipfs v0.13.2-0.20231027223058-cde3b5ba964c/go.mod h1:6EekK/jo+TynwSE/ZOiOJd4eEvRXoavEC3vquKtv4yI= github.com/ipfs/bbloom v0.0.4 h1:Gi+8EGJ2y5qiD5FbsbpX/TMNcJw8gSqr7eyjHa4Fhvs= github.com/ipfs/bbloom v0.0.4/go.mod h1:cS9YprKXpoZ9lT0n/Mw/a6/aFV6DTjTLYHeA+gyqMG0= -github.com/ipfs/boxo v0.17.0 h1:fVXAb12dNbraCX1Cdid5BB6Kl62gVLNVA+e0EYMqAU0= -github.com/ipfs/boxo v0.17.0/go.mod h1:pIZgTWdm3k3pLF9Uq6MB8JEcW07UDwNJjlXW1HELW80= +github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5 h1:qGPYOK8flU2YzHGq9Cb2Yeo0jjOwompAOzxOv3VSGx8= +github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5/go.mod h1:pIZgTWdm3k3pLF9Uq6MB8JEcW07UDwNJjlXW1HELW80= github.com/ipfs/go-bitfield v1.1.0 h1:fh7FIo8bSwaJEh6DdTWbCeZ1eqOaOkKFI74SCnsWbGA= github.com/ipfs/go-bitfield v1.1.0/go.mod h1:paqf1wjq/D2BBmzfTVFlJQ9IlFOZpg422HL0HqsGWHU= github.com/ipfs/go-bitswap v0.11.0 h1:j1WVvhDX1yhG32NTC9xfxnqycqYIlhzEzLXG/cU1HyQ= diff --git a/test/dependencies/go.mod b/test/dependencies/go.mod index 82a84fc679f..e0f00037bf9 100644 --- a/test/dependencies/go.mod +++ b/test/dependencies/go.mod @@ -103,7 +103,7 @@ require ( github.com/hexops/gotextdiff v1.0.3 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/ipfs/bbloom v0.0.4 // indirect - github.com/ipfs/boxo v0.17.0 // indirect + github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5 // indirect github.com/ipfs/go-block-format v0.2.0 // indirect github.com/ipfs/go-cid v0.4.1 // indirect github.com/ipfs/go-datastore v0.6.0 // indirect diff --git a/test/dependencies/go.sum b/test/dependencies/go.sum index 6c929b86985..02d3c3500a6 100644 --- a/test/dependencies/go.sum +++ b/test/dependencies/go.sum @@ -342,8 +342,8 @@ github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2 github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/ipfs/bbloom v0.0.4 h1:Gi+8EGJ2y5qiD5FbsbpX/TMNcJw8gSqr7eyjHa4Fhvs= github.com/ipfs/bbloom v0.0.4/go.mod h1:cS9YprKXpoZ9lT0n/Mw/a6/aFV6DTjTLYHeA+gyqMG0= -github.com/ipfs/boxo v0.17.0 h1:fVXAb12dNbraCX1Cdid5BB6Kl62gVLNVA+e0EYMqAU0= -github.com/ipfs/boxo v0.17.0/go.mod h1:pIZgTWdm3k3pLF9Uq6MB8JEcW07UDwNJjlXW1HELW80= +github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5 h1:qGPYOK8flU2YzHGq9Cb2Yeo0jjOwompAOzxOv3VSGx8= +github.com/ipfs/boxo v0.17.1-0.20240112124340-bcb321c857c5/go.mod h1:pIZgTWdm3k3pLF9Uq6MB8JEcW07UDwNJjlXW1HELW80= github.com/ipfs/go-block-format v0.2.0 h1:ZqrkxBA2ICbDRbK8KJs/u0O3dlp6gmAuuXUJNiW1Ycs= github.com/ipfs/go-block-format v0.2.0/go.mod h1:+jpL11nFx5A/SPpsoBn6Bzkra/zaArfSmsknbPMYgzM= github.com/ipfs/go-cid v0.4.1 h1:A/T3qGvxi4kpKWWcPC/PgbvDA2bjVLO7n4UeVwnbs/s= From 765147faf0ed0d63924b6e0fd0a0fd36160917ce Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jan 2024 21:41:49 +0000 Subject: [PATCH 14/23] chore(deps): bump actions/setup-go from 4 to 5 Bumps [actions/setup-go](https://github.com/actions/setup-go) from 4 to 5. - [Release notes](https://github.com/actions/setup-go/releases) - [Commits](https://github.com/actions/setup-go/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/setup-go dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/build.yml | 2 +- .github/workflows/docker-build.yml | 2 +- .github/workflows/gateway-conformance.yml | 4 ++-- .github/workflows/gobuild.yml | 2 +- .github/workflows/golang-analysis.yml | 2 +- .github/workflows/golint.yml | 2 +- .github/workflows/gotest.yml | 2 +- .github/workflows/sharness.yml | 2 +- 8 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 22520f9b8cc..73e72daf658 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,7 +36,7 @@ jobs: run: shell: bash steps: - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v5 with: go-version: ${{ env.GO_VERSION }} - uses: actions/checkout@v4 diff --git a/.github/workflows/docker-build.yml b/.github/workflows/docker-build.yml index d05429a6c42..733dc2c0e0d 100644 --- a/.github/workflows/docker-build.yml +++ b/.github/workflows/docker-build.yml @@ -26,7 +26,7 @@ jobs: run: shell: bash steps: - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v5 with: go-version: 1.21.x - uses: actions/checkout@v4 diff --git a/.github/workflows/gateway-conformance.yml b/.github/workflows/gateway-conformance.yml index 754a2e5a846..94ab1e17a9b 100644 --- a/.github/workflows/gateway-conformance.yml +++ b/.github/workflows/gateway-conformance.yml @@ -47,7 +47,7 @@ jobs: # 2. Build the kubo-gateway - name: Setup Go - uses: actions/setup-go@v4 + uses: actions/setup-go@v5 with: go-version: 1.21.x - uses: protocol/cache-go-action@v1 @@ -135,7 +135,7 @@ jobs: # 2. Build the kubo-gateway - name: Setup Go - uses: actions/setup-go@v4 + uses: actions/setup-go@v5 with: go-version: 1.20.x - uses: protocol/cache-go-action@v1 diff --git a/.github/workflows/gobuild.yml b/.github/workflows/gobuild.yml index 13eabc0fcad..f5de9e5173f 100644 --- a/.github/workflows/gobuild.yml +++ b/.github/workflows/gobuild.yml @@ -28,7 +28,7 @@ jobs: run: shell: bash steps: - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v5 with: go-version: 1.21.x - uses: actions/checkout@v4 diff --git a/.github/workflows/golang-analysis.yml b/.github/workflows/golang-analysis.yml index eddaba988ec..0643de16054 100644 --- a/.github/workflows/golang-analysis.yml +++ b/.github/workflows/golang-analysis.yml @@ -25,7 +25,7 @@ jobs: - uses: actions/checkout@v4 with: submodules: recursive - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v5 with: go-version: "1.21.x" - name: Check that go.mod is tidy diff --git a/.github/workflows/golint.yml b/.github/workflows/golint.yml index d6191e6f376..59150747150 100644 --- a/.github/workflows/golint.yml +++ b/.github/workflows/golint.yml @@ -29,7 +29,7 @@ jobs: run: shell: bash steps: - - uses: actions/setup-go@v4 + - uses: actions/setup-go@v5 with: go-version: 1.21.x - uses: actions/checkout@v4 diff --git a/.github/workflows/gotest.yml b/.github/workflows/gotest.yml index a1042cf7add..e3bf5c4d6ea 100644 --- a/.github/workflows/gotest.yml +++ b/.github/workflows/gotest.yml @@ -30,7 +30,7 @@ jobs: shell: bash steps: - name: Set up Go - uses: actions/setup-go@v4 + uses: actions/setup-go@v5 with: go-version: 1.21.x - name: Check out Kubo diff --git a/.github/workflows/sharness.yml b/.github/workflows/sharness.yml index 448e112de8b..0b8fc894201 100644 --- a/.github/workflows/sharness.yml +++ b/.github/workflows/sharness.yml @@ -23,7 +23,7 @@ jobs: shell: bash steps: - name: Setup Go - uses: actions/setup-go@v4 + uses: actions/setup-go@v5 with: go-version: 1.21.x - name: Checkout Kubo From 2a070973a9271ed525beca80988126ff7a189418 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jan 2024 21:41:56 +0000 Subject: [PATCH 15/23] chore(deps): bump actions/github-script from 6 to 7 Bumps [actions/github-script](https://github.com/actions/github-script) from 6 to 7. - [Release notes](https://github.com/actions/github-script/releases) - [Commits](https://github.com/actions/github-script/compare/v6...v7) --- updated-dependencies: - dependency-name: actions/github-script dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/sync-release-assets.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sync-release-assets.yml b/.github/workflows/sync-release-assets.yml index 8a39f32345f..0d5c8199b65 100644 --- a/.github/workflows/sync-release-assets.yml +++ b/.github/workflows/sync-release-assets.yml @@ -26,7 +26,7 @@ jobs: with: node-version: 14 - name: Sync the latest 5 github releases - uses: actions/github-script@v6 + uses: actions/github-script@v7 with: script: | const fs = require('fs').promises From 22742ba782d23f5ca5ed81186d2e2eb0aff228d5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 15 Jan 2024 21:42:13 +0000 Subject: [PATCH 16/23] chore(deps): bump actions/upload-artifact and actions/download-artifact from 3 to 4 Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 3 to 4. - [Release notes](https://github.com/actions/upload-artifact/releases) - [Commits](https://github.com/actions/upload-artifact/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/upload-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 3 to 4. - [Release notes](https://github.com/actions/download-artifact/releases) - [Commits](https://github.com/actions/download-artifact/compare/v3...v4) --- updated-dependencies: - dependency-name: actions/download-artifact dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/build.yml | 6 +++--- .github/workflows/gateway-conformance.yml | 8 ++++---- .github/workflows/gotest.yml | 4 ++-- .github/workflows/sharness.yml | 4 ++-- 4 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 73e72daf658..9e0c9110539 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -41,7 +41,7 @@ jobs: go-version: ${{ env.GO_VERSION }} - uses: actions/checkout@v4 - run: make build - - uses: actions/upload-artifact@v3 + - uses: actions/upload-artifact@v4 with: name: kubo path: cmd/ipfs/ipfs @@ -56,7 +56,7 @@ jobs: - uses: actions/setup-node@v4 with: node-version: lts/* - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: kubo path: cmd/ipfs @@ -112,7 +112,7 @@ jobs: - uses: actions/setup-node@v4 with: node-version: 18.14.0 - - uses: actions/download-artifact@v3 + - uses: actions/download-artifact@v4 with: name: kubo path: cmd/ipfs diff --git a/.github/workflows/gateway-conformance.yml b/.github/workflows/gateway-conformance.yml index 94ab1e17a9b..993dfca61e5 100644 --- a/.github/workflows/gateway-conformance.yml +++ b/.github/workflows/gateway-conformance.yml @@ -111,13 +111,13 @@ jobs: run: cat output.md >> $GITHUB_STEP_SUMMARY - name: Upload HTML report if: failure() || success() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: gateway-conformance.html path: output.html - name: Upload JSON report if: failure() || success() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: gateway-conformance.json path: output.json @@ -217,13 +217,13 @@ jobs: run: cat output.md >> $GITHUB_STEP_SUMMARY - name: Upload HTML report if: failure() || success() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: gateway-conformance-libp2p.html path: output.html - name: Upload JSON report if: failure() || success() - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: gateway-conformance-libp2p.json path: output.json diff --git a/.github/workflows/gotest.yml b/.github/workflows/gotest.yml index e3bf5c4d6ea..c6b2cdc075d 100644 --- a/.github/workflows/gotest.yml +++ b/.github/workflows/gotest.yml @@ -79,7 +79,7 @@ jobs: output: test/unit/gotest.junit.xml if: failure() || success() - name: Archive the JUnit XML report - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: unit path: test/unit/gotest.junit.xml @@ -92,7 +92,7 @@ jobs: output: test/unit/gotest.html if: failure() || success() - name: Archive the HTML report - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: html path: test/unit/gotest.html diff --git a/.github/workflows/sharness.yml b/.github/workflows/sharness.yml index 0b8fc894201..7bf3325effc 100644 --- a/.github/workflows/sharness.yml +++ b/.github/workflows/sharness.yml @@ -88,7 +88,7 @@ jobs: destination: sharness.html - name: Upload one-page HTML report if: github.repository != 'ipfs/kubo' && (failure() || success()) - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: sharness.html path: kubo/test/sharness/test-results/sharness.html @@ -108,7 +108,7 @@ jobs: destination: sharness-html/ - name: Upload full HTML report if: github.repository != 'ipfs/kubo' && (failure() || success()) - uses: actions/upload-artifact@v3 + uses: actions/upload-artifact@v4 with: name: sharness-html path: kubo/test/sharness/test-results/sharness-html From f72c6cf9838ca2d4f72a475034926d006fc1de7e Mon Sep 17 00:00:00 2001 From: Jorropo Date: Tue, 16 Jan 2024 08:18:58 +0100 Subject: [PATCH 17/23] dependabot: only update github-actions We update go packages as part of the release cycle, dependant bots also never fixup all the `go.sum` in the repo so this is noisy failing PRs. --- .github/dependabot.yml | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 6ff8dba1fb2..5ace4600a1f 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -1,13 +1,5 @@ version: 2 updates: - - package-ecosystem: gomod - directory: "/" - schedule: - interval: daily - time: "11:00" - open-pull-requests-limit: 10 - labels: - - "topic/dependencies" - package-ecosystem: "github-actions" directory: "/" schedule: From 0ec6308e8bf2c18991de7ec0da68bfe6f20ec239 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Tue, 16 Jan 2024 10:56:00 +0100 Subject: [PATCH 18/23] core/corehttp: wrap hostname option with otelhttp --- core/corehttp/gateway.go | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/core/corehttp/gateway.go b/core/corehttp/gateway.go index a2567d8f0fd..a1576517697 100644 --- a/core/corehttp/gateway.go +++ b/core/corehttp/gateway.go @@ -62,7 +62,12 @@ func HostnameOption() ServeOption { } childMux := http.NewServeMux() - mux.Handle("/", gateway.NewHostnameHandler(config, backend, childMux)) + + var handler http.Handler + handler = gateway.NewHostnameHandler(config, backend, childMux) + handler = otelhttp.NewHandler(handler, "HostnameGateway") + + mux.Handle("/", handler) return childMux, nil } } From 35ad4aee7fead1a5a22400d1dc99685094fee898 Mon Sep 17 00:00:00 2001 From: Jorropo Date: Tue, 16 Jan 2024 13:57:11 +0100 Subject: [PATCH 19/23] ci: use latest tagged @helia/interop version --- .github/workflows/build.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9e0c9110539..69534112d8a 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -73,13 +73,12 @@ jobs: - uses: actions/checkout@v4 with: repository: ipfs/helia - fetch-depth: 1 + fetch-depth: 0 path: interop - ref: 'ea5533c794df844c9fb9812e85e2f5e6af09efeb' # temporary while this commit is being released + ref: 'main' - name: Checkout latest tag run: | - exit 0 # temporary while ea5533c794df844c9fb9812e85e2f5e6af09efeb is released - export TAG="$(git describe --tags --abbrev=0)" + export TAG="$(git tag | grep "^interop-" | sort --version-sort --reverse | head -n1)" echo "Running tests against: $TAG" git checkout "$TAG" working-directory: interop From e11d7b0c13a007351ee9cc4108f2860eea15f404 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Tue, 16 Jan 2024 14:33:54 +0100 Subject: [PATCH 20/23] docs: improve release issue template (#10305) --- docs/RELEASE_CHECKLIST.md | 180 +++++++++++++++++++++++++++ docs/RELEASE_ISSUE_TEMPLATE.md | 221 +++------------------------------ 2 files changed, 197 insertions(+), 204 deletions(-) create mode 100644 docs/RELEASE_CHECKLIST.md diff --git a/docs/RELEASE_CHECKLIST.md b/docs/RELEASE_CHECKLIST.md new file mode 100644 index 00000000000..b0a89dccc35 --- /dev/null +++ b/docs/RELEASE_CHECKLIST.md @@ -0,0 +1,180 @@ + + +# ✅ Release Checklist (vX.Y.Z[-rcN]) + +## Labels + +If an item should be executed for a specific release type, it should be labeled with one of the following labels: + +- ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) execute **ONLY** when releasing a Release Candidate +- ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) execute **ONLY** when releasing a Final Release + +Otherwise, it means it should be executed for **ALL** release types. + +Patch releases should follow the same process as `.0` releases. If some item should **NOT** be executed for a Patch Release, it should be labeled with: + +- ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) do **NOT** execute when releasing a Patch Release + +## Before the release + +This section covers tasks to be done ahead of the release. + +- [ ] Verify you have access to all the services and tools required for the release + - [ ] [GPG signature](https://docs.github.com/en/authentication/managing-commit-signature-verification) configured in local git and in GitHub + - [ ] [admin access to IPFS Discourse](https://discuss.ipfs.tech/g/admins) + - ask the previous release owner (or @2color) for an invite + - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [access to #shared-pl-marketing-requests](https://filecoinproject.slack.com/archives/C018EJ8LWH1) channel in FIL Slack + - ask the previous release owner for an invite + - [ ] [access to IPFS network metrics](https://github.com/protocol/pldw/blob/624f47cf4ec14ad2cec6adf601a9f7b203ef770d/docs/sources/ipfs.md#ipfs-network-metrics) dashboards in Grafana + - open an access request in the [pldw](https://github.com/protocol/pldw/issues/new/choose) + - [example](https://github.com/protocol/pldw/issues/158) + - [ ] [kuboreleaser](https://github.com/ipfs/kuboreleaser) checked out on your system (_only if you're using [kuboreleaser](https://github.com/ipfs/kuboreleaser)_) + - [ ] [Thunderdome](https://github.com/ipfs-shipyard/thunderdome) checked out on your system and configured (see the [Thunderdome release docs](./releases_thunderdome.md) for setup) + - [ ] [docker](https://docs.docker.com/get-docker/) installed on your system (_only if you're using [kuboreleaser](https://github.com/ipfs/kuboreleaser)_) + - [ ] [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) installed on your system (_only if you're **NOT** using [kuboreleaser](https://github.com/ipfs/kuboreleaser)_) + - [ ] [zsh](https://github.com/ohmyzsh/ohmyzsh/wiki/Installing-ZSH#install-and-set-up-zsh-as-default) installed on your system + - [ ] [kubo](https://github.com/ipfs/kubo) checked out under `$(go env GOPATH)/src/github.com/ipfs/kubo` + - you can also symlink your clone to the expected location by running `mkdir -p $(go env GOPATH)/src/github.com/ipfs && ln -s $(pwd) $(go env GOPATH)/src/github.com/ipfs/kubo` + - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [Reddit](https://www.reddit.com) account +- ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Upgrade Go used in CI to the latest patch release available in [CircleCI](https://hub.docker.com/r/cimg/go/tags) in: + - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [ipfs/distributions](https://github.com/ipfs/distributions) + - [example](https://github.com/ipfs/distributions/pull/756) + - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [ipfs/ipfs-docs](https://github.com/ipfs/ipfs-docs) + - [example](https://github.com/ipfs/ipfs-docs/pull/1298) +- [ ] Verify there is nothing [left for release](-what-s-left-for-release) +- [ ] Create a release process improvement PR + - [ ] update the [release issue template](docs/RELEASE_ISSUE_TEMPLATE.md) as you go + - [ ] link it in the [Meta](#meta) section + +## The release + +This section covers tasks to be done during each release. + +- [ ] Prepare the release branch and update version numbers accordingly
using `./kuboreleaser --skip-check-before release --version vX.Y.Z(-rcN) prepare-branch` or ... + - [ ] create a new branch `release-vX.Y.Z` + - use `master` as base if `Z == 0` + - use `release` as base if `Z > 0` + - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) update the `CurrentVersionNumber` in [version.go](version.go) in the `master` branch to `vX.Y+1.0-dev` + - [example](https://github.com/ipfs/kubo/pull/9305) + - [ ] update the `CurrentVersionNumber` in [version.go](version.go) in the `release-vX.Y` branch to `vX.Y.Z(-RCN)` + - [example](https://github.com/ipfs/kubo/pull/9394) + - [ ] create a draft PR from `release-vX.Y` to `release` + - [example](https://github.com/ipfs/kubo/pull/9306) + - [ ] Cherry-pick commits from `master` to the `release-vX.Y.Z` using `git cherry-pick -x ` + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Add full changelog and contributors to the [changelog](docs/changelogs/vX.Y.md) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Replace the `Changelog` and `Contributors` sections of the [changelog](docs/changelogs/vX.Y.md) with the stdout of `./bin/mkreleaselog` + - do **NOT** copy the stderr + - [ ] verify all CI checks on the PR from `release-vX.Y` to `release` are passing + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Merge the PR from `release-vX.Y` to `release` using the `Create a merge commit` + - do **NOT** use `Squash and merge` nor `Rebase and merge` because we need to be able to sign the merge commit + - do **NOT** delete the `release-vX.Y` branch +
+- [ ] Run Thunderdome testing, see the [Thunderdome release docs](./releases_thunderdome.md) for details + - [ ] create a PR and merge the experiment config into Thunderdome +- [ ] Create the release tag
using `./kuboreleaser release --version vX.Y.Z(-rcN) tag` or ... + - This is a dangerous operation! Go and Docker publishing are difficult to reverse! Have the release reviewer verify all the commands marked with ⚠️! + - [ ] ⚠️ ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) tag the HEAD commit using `git tag -s vX.Y.Z(-RCN) -m 'Prerelease X.Y.Z(-RCN)'` + - [ ] ⚠️ ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) tag the HEAD commit of the `release` branch using `git tag -s vX.Y.Z(-RCN) -m 'Release X.Y.Z(-RCN)'` + - [ ] ⚠️ verify the tag is signed and tied to the correct commit using `git show vX.Y.Z(-RCN)` + - [ ] ⚠️ push the tag to GitHub using `git push origin vX.Y.Z(-RCN)` + - do **NOT** use `git push --tags` because it pushes all your local tags +
+- [ ] Publish the release to [DockerHub](https://hub.docker.com/r/ipfs/kubo/)
using `./kuboreleaser --skip-check-before --skip-run release --version vX.Y.Z(-rcN) publish-to-dockerhub` or ... + - [ ] Wait for [Publish docker image](https://github.com/ipfs/kubo/actions/workflows/docker-image.yml) workflow run initiated by the tag push to finish + - [ ] verify the image is available on [Docker Hub](https://hub.docker.com/r/ipfs/kubo/tags) +- [ ] Verify [ipfs/distributions](https://github.com/ipfs/distributions)'s `.tool-versions`'s `golang` entry is set to the [latest go release](https://go.dev/doc/devel/release) on the major go branch [Kubo is being tested on](https://github.com/ipfs/kubo/blob/master/.github/workflows/gotest.yml) (see `go-version:`). +- [ ] Publish the release to [dist.ipfs.tech](https://dist.ipfs.tech)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-distributions` or ... + - [ ] check out [ipfs/distributions](https://github.com/ipfs/distributions) + - [ ] run `./dist.sh add-version kubo vX.Y.Z(-RCN)` to add the new version to the `versions` file + - [usage](https://github.com/ipfs/distributions#usage) + - [ ] create and merge the PR which updates `dists/kubo/versions` and `dists/go-ipfs/versions` (![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) and `dists/kubo/current_version` and `dists/go-ipfs/current_version`) + - [example](https://github.com/ipfs/distributions/pull/760) + - [ ] wait for the [CI](https://github.com/ipfs/distributions/actions/workflows/main.yml) workflow run initiated by the merge to master to finish + - [ ] verify the release is available on [dist.ipfs.io](https://dist.ipfs.io/#kubo) +
+- [ ] Publish the release to [NPM](https://www.npmjs.com/package/go-ipfs?activeTab=versions)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-npm` (⚠️ you might need to run the command a couple of times because GHA might not be able to see the new distribution straight away due to caching) or ... + - [ ] run the [Release to npm](https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml) workflow + - [ ] check [Release to npm](https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml) workflow run logs to verify it discovered the new release + - [ ] verify the release is available on [NPM](https://www.npmjs.com/package/go-ipfs?activeTab=versions) +
+- [ ] Publish the release to [GitHub](https://github.com/ipfs/kubo/releases)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-github` or ... + - [ ] create a new release on [GitHub](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository#creating-a-release) + - [RC example](https://github.com/ipfs/kubo/releases/tag/v0.17.0-rc1) + - [FINAL example](https://github.com/ipfs/kubo/releases/tag/v0.17.0) + - [ ] use the `vX.Y.Z(-RCN)` tag + - [ ] link to the release issue + - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) link to the changelog in the description + - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) check the `This is a pre-release` checkbox + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) copy the changelog (without the header) in the description + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) do **NOT** check the `This is a pre-release` checkbox + - [ ] run the [sync-release-assets](https://github.com/ipfs/kubo/actions/workflows/sync-release-assets.yml) workflow + - [ ] wait for the [sync-release-assets](https://github.com/ipfs/kubo/actions/workflows/sync-release-assets.yml) workflow run to finish + - [ ] verify the release assets are present in the [GitHub release](https://github.com/ipfs/kubo/releases/tag/vX.Y.Z(-RCN)) +
+- [ ] Promote the release
using `./kuboreleaser release --version vX.Y.Z(-rcN) promote` or ... + - [ ] create an [IPFS Discourse](https://discuss.ipfs.tech) topic + - [prerelease example](https://discuss.ipfs.tech/t/kubo-v0-16-0-rc1-release-candidate-is-out/15248) + - [release example](https://discuss.ipfs.tech/t/kubo-v0-16-0-release-is-out/15249) + - [ ] use `Kubo vX.Y.Z(-RCN) is out!` as the title + - [ ] use `kubo` and `go-ipfs` as topics + - [ ] repeat the title as a heading (`##`) in the description + - [ ] link to the GitHub Release, binaries on IPNS, docker pull command and release notes in the description + - [ ] pin the [IPFS Discourse](https://discuss.ipfs.tech) topic globally + - you can make the topic a banner if there is no banner already + - verify the [IPFS Discourse](https://discuss.ipfs.tech) topic was copied to: + - [ ] [#ipfs-chatter](https://discord.com/channels/669268347736686612/669268347736686615) in IPFS Discord + - [ ] [#ipfs-chatter](https://filecoinproject.slack.com/archives/C018EJ8LWH1) in FIL Slack + - [ ] [#ipfs-chatter:ipfs.io](https://matrix.to/#/#ipfs-chatter:ipfs.io) in Matrix + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Add the link to the [IPFS Discourse](https://discuss.ipfs.tech) topic to the [GitHub Release](https://github.com/ipfs/kubo/releases/tag/vX.Y.Z(-RCN)) description + - [example](https://github.com/ipfs/kubo/releases/tag/v0.17.0) + - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) create an issue comment mentioning early testers on the release issue + - [example](https://github.com/ipfs/kubo/issues/9319#issuecomment-1311002478) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) create an issue comment linking to the release on the release issue + - [example](https://github.com/ipfs/kubo/issues/9417#issuecomment-1400740975) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) ask the marketing team to tweet about the release in [#shared-pl-marketing-requests](https://filecoinproject.slack.com/archives/C018EJ8LWH1) in FIL Slack + - [example](https://filecoinproject.slack.com/archives/C018EJ8LWH1/p1664885305374900) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) post the link to the [GitHub Release](https://github.com/ipfs/kubo/releases/tag/vX.Y.Z(-RCN)) to [Reddit](https://reddit.com/r/ipfs) + - [example](https://www.reddit.com/r/ipfs/comments/9x0q0k/kubo_v0160_release_is_out/) +
+- [ ] Test the new version with `ipfs-companion`
using `./kuboreleaser release --version vX.Y.Z(-rcN) test-ipfs-companion` or ... + - [ ] run the [e2e](https://github.com/ipfs/ipfs-companion/actions/workflows/e2e.yml) + - use `vX.Y.Z(-RCN)` as the Kubo image version + - [ ] wait for the [e2e](https://github.com/ipfs/ipfs-companion/actions/workflows/e2e.yml) workflow run to finish +
+- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Update Kubo in [ipfs-desktop](https://github.com/ipfs/ipfs-desktop)
using `./kuboreleaser release --version vX.Y.Z(-rcN) update-ipfs-desktop` or ... + - [ ] check out [ipfs/ipfs-desktop](https://github.com/ipfs/ipfs-desktop) + - [ ] run `npm install` + - [ ] create a PR which updates `package.json` and `package-lock.json` + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) add @SgtPooki and @whizzzkid as reviewers +
+- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Update Kubo docs
using `./kuboreleaser release --version vX.Y.Z(-rcN) update-ipfs-docs` or ... + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) run the [update-on-new-ipfs-tag.yml](https://github.com/ipfs/ipfs-docs/actions/workflows/update-on-new-ipfs-tag.yml) workflow + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) merge the PR created by the [update-on-new-ipfs-tag.yml](https://github.com/ipfs/ipfs-docs/actions/workflows/update-on-new-ipfs-tag.yml) workflow run +
+- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Ask Brave to update Kubo in Brave Desktop + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) use [this link](https://github.com/brave/brave-browser/issues/new?assignees=&labels=OS%2FDesktop&projects=&template=desktop.md&title=) to create an issue for the new Kubo version + - [basic example](https://github.com/brave/brave-browser/issues/31453), [example with additional notes](https://github.com/brave/brave-browser/issues/27965) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) post link to the issue in `#shared-pl-brave` for visibility +- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Create a blog entry on [blog.ipfs.tech](https://blog.ipfs.tech)
using `./kuboreleaser release --version vX.Y.Z(-rcN) update-ipfs-blog --date YYYY-MM-DD` or ... + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) create a PR which adds a release note for the new Kubo version + - [example](https://github.com/ipfs/ipfs-blog/pull/529) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) merge the PR + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) verify the blog entry was published +
+- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Merge the [release](https://github.com/ipfs/kubo/tree/release) branch back into [master](https://github.com/ipfs/kubo/tree/master), ignoring the changes to [version.go](version.go) (keep the `-dev`) version,
using `./kuboreleaser release --version vX.Y.Z(-rcN) merge-branch` or ... + - [ ] create a new branch `merge-release-vX.Y.Z` from `release` + - [ ] create and merge a PR from `merge-release-vX.Y.Z` to `master` +
+- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Prepare for the next release
using `./kuboreleaser release --version vX.Y.Z(-rcN) prepare-next` or ... + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Create the next [changelog](https://github.com/ipfs/kubo/blob/master/docs/changelogs/vX.(Y+1).md) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Link to the new changelog in the [CHANGELOG.md](CHANGELOG.md) file + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Create the next release issue +
+- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Create a dependency update PR + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) check out [ipfs/kubo](https://github.com/ipfs/kubo) + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) run `go get -u` in root directory + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) run `go mod tidy` in root directory + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) run `go mod tidy` in `docs/examples/kubo-as-a-library` directory + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) create a PR which updates `go.mod` and `go.sum` + - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) add the PR to the next release milestone +- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Close the release issue diff --git a/docs/RELEASE_ISSUE_TEMPLATE.md b/docs/RELEASE_ISSUE_TEMPLATE.md index 26e5ad5bef2..61c7ee09558 100644 --- a/docs/RELEASE_ISSUE_TEMPLATE.md +++ b/docs/RELEASE_ISSUE_TEMPLATE.md @@ -1,222 +1,35 @@ - + # Items to do upon creating the release issue + - [ ] Fill in the Meta section - [ ] Assign the issue to the release owner and reviewer. - [ ] Name the issue "Release vX.Y.Z" - [ ] Set the proper values for X.Y.Z - [ ] Pin the issue + + # Meta + * Release owner: @who * Release reviewer: @who * Expected RC date: week of YYYY-MM-DD * 🚢 Expected final release date: YYYY-MM-DD -* Accompanying PR for improving the release process: (example: https://github.com/ipfs/kubo/pull/9391) - -See the [Kubo release process](https://pl-strflt.notion.site/Kubo-Release-Process-5a5d066264704009a28a79cff93062c4) for more info. - -# Kubo X.Y.Z Release - -We're happy to announce Kubo X.Y.Z! - -As usual, this release includes important fixes, some of which may be critical for security. Unless the fix addresses a bug being exploited in the wild, the fix will _not_ be called out in the release notes. Please make sure to update ASAP. See our [security fix policy](https://github.com/ipfs/go-ipfs/tree/master/docs/releases.md#security-fix-policy) for details. - -## 🗺 What's left for release - - - -### Required - -### Nice to have - -## 🔦 Highlights - -< top highlights for this release notes. For ANY version (final or RCs) > - -## ✅ Release Checklist - -### Labels - -If an item should be executed for a specific release type, it should be labeled with one of the following labels: - -- ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) execute **ONLY** when releasing a Release Candidate -- ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) execute **ONLY** when releasing a Final Release - -Otherwise, it means it should be executed for **ALL** release types. - -Patch releases should follow the same process as `.0` releases. If some item should **NOT** be executed for a Patch Release, it should be labeled with: - -- ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) do **NOT** execute when releasing a Patch Release - -### Before the release - -This section covers tasks to be done ahead of the release. - -- [ ] Verify you have access to all the services and tools required for the release - - [ ] [GPG signature](https://docs.github.com/en/authentication/managing-commit-signature-verification) configured in local git and in GitHub - - [ ] [admin access to IPFS Discourse](https://discuss.ipfs.tech/g/admins) - - ask the previous release owner (or @2color) for an invite - - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [access to #shared-pl-marketing-requests](https://filecoinproject.slack.com/archives/C018EJ8LWH1) channel in FIL Slack - - ask the previous release owner for an invite - - [ ] [access to IPFS network metrics](https://github.com/protocol/pldw/blob/624f47cf4ec14ad2cec6adf601a9f7b203ef770d/docs/sources/ipfs.md#ipfs-network-metrics) dashboards in Grafana - - open an access request in the [pldw](https://github.com/protocol/pldw/issues/new/choose) - - [example](https://github.com/protocol/pldw/issues/158) - - [ ] [kuboreleaser](https://github.com/ipfs/kuboreleaser) checked out on your system (_only if you're using [kuboreleaser](https://github.com/ipfs/kuboreleaser)_) - - [ ] [Thunderdome](https://github.com/ipfs-shipyard/thunderdome) checked out on your system and configured (see the [Thunderdome release docs](./releases_thunderdome.md) for setup) - - [ ] [docker](https://docs.docker.com/get-docker/) installed on your system (_only if you're using [kuboreleaser](https://github.com/ipfs/kuboreleaser)_) - - [ ] [npm](https://docs.npmjs.com/downloading-and-installing-node-js-and-npm) installed on your system (_only if you're **NOT** using [kuboreleaser](https://github.com/ipfs/kuboreleaser)_) - - [ ] [zsh](https://github.com/ohmyzsh/ohmyzsh/wiki/Installing-ZSH#install-and-set-up-zsh-as-default) installed on your system - - [ ] [kubo](https://github.com/ipfs/kubo) checked out under `$(go env GOPATH)/src/github.com/ipfs/kubo` - - you can also symlink your clone to the expected location by running `mkdir -p $(go env GOPATH)/src/github.com/ipfs && ln -s $(pwd) $(go env GOPATH)/src/github.com/ipfs/kubo` - - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [Reddit](https://www.reddit.com) account -- ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Upgrade Go used in CI to the latest patch release available in [CircleCI](https://hub.docker.com/r/cimg/go/tags) in: - - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [ipfs/distributions](https://github.com/ipfs/distributions) - - [example](https://github.com/ipfs/distributions/pull/756) - - [ ] ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) [ipfs/ipfs-docs](https://github.com/ipfs/ipfs-docs) - - [example](https://github.com/ipfs/ipfs-docs/pull/1298) -- [ ] Verify there is nothing [left for release](-what-s-left-for-release) -- [ ] Create a release process improvement PR - - [ ] update the [release issue template](docs/RELEASE_ISSUE_TEMPLATE.md) as you go - - [ ] link it in the [Meta](#meta) section - -### The release +* Release PR: +* Accompanying PR for improving the release process: ([example](https://github.com/ipfs/kubo/pull/9391)) -This section covers tasks to be done during each release. +# Items In Scope -- [ ] Prepare the release branch and update version numbers accordingly
using `./kuboreleaser --skip-check-before release --version vX.Y.Z(-rcN) prepare-branch` or ... - - [ ] create a new branch `release-vX.Y.Z` - - use `master` as base if `Z == 0` - - use `release` as base if `Z > 0` - - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) update the `CurrentVersionNumber` in [version.go](version.go) in the `master` branch to `vX.Y+1.0-dev` - - [example](https://github.com/ipfs/kubo/pull/9305) - - [ ] update the `CurrentVersionNumber` in [version.go](version.go) in the `release-vX.Y` branch to `vX.Y.Z(-RCN)` - - [example](https://github.com/ipfs/kubo/pull/9394) - - [ ] create a draft PR from `release-vX.Y` to `release` - - [example](https://github.com/ipfs/kubo/pull/9306) - - [ ] Cherry-pick commits from `master` to the `release-vX.Y.Z` using `git cherry-pick -x ` - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Add full changelog and contributors to the [changelog](docs/changelogs/vX.Y.md) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Replace the `Changelog` and `Contributors` sections of the [changelog](docs/changelogs/vX.Y.md) with the stdout of `./bin/mkreleaselog` - - do **NOT** copy the stderr - - [ ] verify all CI checks on the PR from `release-vX.Y` to `release` are passing - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Merge the PR from `release-vX.Y` to `release` using the `Create a merge commit` - - do **NOT** use `Squash and merge` nor `Rebase and merge` because we need to be able to sign the merge commit - - do **NOT** delete the `release-vX.Y` branch -
-- [ ] Run Thunderdome testing, see the [Thunderdome release docs](./releases_thunderdome.md) for details - - [ ] create a PR and merge the experiment config into Thunderdome -- [ ] Create the release tag
using `./kuboreleaser release --version vX.Y.Z(-rcN) tag` or ... - - This is a dangerous operation! Go and Docker publishing are difficult to reverse! Have the release reviewer verify all the commands marked with ⚠️! - - [ ] ⚠️ ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) tag the HEAD commit using `git tag -s vX.Y.Z(-RCN) -m 'Prerelease X.Y.Z(-RCN)'` - - [ ] ⚠️ ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) tag the HEAD commit of the `release` branch using `git tag -s vX.Y.Z(-RCN) -m 'Release X.Y.Z(-RCN)'` - - [ ] ⚠️ verify the tag is signed and tied to the correct commit using `git show vX.Y.Z(-RCN)` - - [ ] ⚠️ push the tag to GitHub using `git push origin vX.Y.Z(-RCN)` - - do **NOT** use `git push --tags` because it pushes all your local tags -
-- [ ] Publish the release to [DockerHub](https://hub.docker.com/r/ipfs/kubo/)
using `./kuboreleaser --skip-check-before --skip-run release --version vX.Y.Z(-rcN) publish-to-dockerhub` or ... - - [ ] Wait for [Publish docker image](https://github.com/ipfs/kubo/actions/workflows/docker-image.yml) workflow run initiated by the tag push to finish - - [ ] verify the image is available on [Docker Hub](https://hub.docker.com/r/ipfs/kubo/tags) -- [ ] Verify [ipfs/distributions](https://github.com/ipfs/distributions)'s `.tool-versions`'s `golang` entry is set to the [latest go release](https://go.dev/doc/devel/release) on the major go branch [Kubo is being tested on](https://github.com/ipfs/kubo/blob/master/.github/workflows/gotest.yml) (see `go-version:`). -- [ ] Publish the release to [dist.ipfs.tech](https://dist.ipfs.tech)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-distributions` or ... - - [ ] check out [ipfs/distributions](https://github.com/ipfs/distributions) - - [ ] run `./dist.sh add-version kubo vX.Y.Z(-RCN)` to add the new version to the `versions` file - - [usage](https://github.com/ipfs/distributions#usage) - - [ ] create and merge the PR which updates `dists/kubo/versions` and `dists/go-ipfs/versions` (![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) and `dists/kubo/current_version` and `dists/go-ipfs/current_version`) - - [example](https://github.com/ipfs/distributions/pull/760) - - [ ] wait for the [CI](https://github.com/ipfs/distributions/actions/workflows/main.yml) workflow run initiated by the merge to master to finish - - [ ] verify the release is available on [dist.ipfs.io](https://dist.ipfs.io/#kubo) -
-- [ ] Publish the release to [NPM](https://www.npmjs.com/package/go-ipfs?activeTab=versions)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-npm` (⚠️ you might need to run the command a couple of times because GHA might not be able to see the new distribution straight away due to caching) or ... - - [ ] run the [Release to npm](https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml) workflow - - [ ] check [Release to npm](https://github.com/ipfs/npm-go-ipfs/actions/workflows/main.yml) workflow run logs to verify it discovered the new release - - [ ] verify the release is available on [NPM](https://www.npmjs.com/package/go-ipfs?activeTab=versions) -
-- [ ] Publish the release to [GitHub](https://github.com/ipfs/kubo/releases)
using `./kuboreleaser release --version vX.Y.Z(-rcN) publish-to-github` or ... - - [ ] create a new release on [GitHub](https://docs.github.com/en/repositories/releasing-projects-on-github/managing-releases-in-a-repository#creating-a-release) - - [RC example](https://github.com/ipfs/kubo/releases/tag/v0.17.0-rc1) - - [FINAL example](https://github.com/ipfs/kubo/releases/tag/v0.17.0) - - [ ] use the `vX.Y.Z(-RCN)` tag - - [ ] link to the release issue - - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) link to the changelog in the description - - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) check the `This is a pre-release` checkbox - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) copy the changelog (without the header) in the description - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) do **NOT** check the `This is a pre-release` checkbox - - [ ] run the [sync-release-assets](https://github.com/ipfs/kubo/actions/workflows/sync-release-assets.yml) workflow - - [ ] wait for the [sync-release-assets](https://github.com/ipfs/kubo/actions/workflows/sync-release-assets.yml) workflow run to finish - - [ ] verify the release assets are present in the [GitHub release](https://github.com/ipfs/kubo/releases/tag/vX.Y.Z(-RCN)) -
-- [ ] Promote the release
using `./kuboreleaser release --version vX.Y.Z(-rcN) promote` or ... - - [ ] create an [IPFS Discourse](https://discuss.ipfs.tech) topic - - [prerelease example](https://discuss.ipfs.tech/t/kubo-v0-16-0-rc1-release-candidate-is-out/15248) - - [release example](https://discuss.ipfs.tech/t/kubo-v0-16-0-release-is-out/15249) - - [ ] use `Kubo vX.Y.Z(-RCN) is out!` as the title - - [ ] use `kubo` and `go-ipfs` as topics - - [ ] repeat the title as a heading (`##`) in the description - - [ ] link to the GitHub Release, binaries on IPNS, docker pull command and release notes in the description - - [ ] pin the [IPFS Discourse](https://discuss.ipfs.tech) topic globally - - you can make the topic a banner if there is no banner already - - verify the [IPFS Discourse](https://discuss.ipfs.tech) topic was copied to: - - [ ] [#ipfs-chatter](https://discord.com/channels/669268347736686612/669268347736686615) in IPFS Discord - - [ ] [#ipfs-chatter](https://filecoinproject.slack.com/archives/C018EJ8LWH1) in FIL Slack - - [ ] [#ipfs-chatter:ipfs.io](https://matrix.to/#/#ipfs-chatter:ipfs.io) in Matrix - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Add the link to the [IPFS Discourse](https://discuss.ipfs.tech) topic to the [GitHub Release](https://github.com/ipfs/kubo/releases/tag/vX.Y.Z(-RCN)) description - - [example](https://github.com/ipfs/kubo/releases/tag/v0.17.0) - - [ ] ![](https://img.shields.io/badge/only-RC-blue?style=flat-square) create an issue comment mentioning early testers on the release issue - - [example](https://github.com/ipfs/kubo/issues/9319#issuecomment-1311002478) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) create an issue comment linking to the release on the release issue - - [example](https://github.com/ipfs/kubo/issues/9417#issuecomment-1400740975) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) ask the marketing team to tweet about the release in [#shared-pl-marketing-requests](https://filecoinproject.slack.com/archives/C018EJ8LWH1) in FIL Slack - - [example](https://filecoinproject.slack.com/archives/C018EJ8LWH1/p1664885305374900) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) post the link to the [GitHub Release](https://github.com/ipfs/kubo/releases/tag/vX.Y.Z(-RCN)) to [Reddit](https://reddit.com/r/ipfs) - - [example](https://www.reddit.com/r/ipfs/comments/9x0q0k/kubo_v0160_release_is_out/) -
-- [ ] Test the new version with `ipfs-companion`
using `./kuboreleaser release --version vX.Y.Z(-rcN) test-ipfs-companion` or ... - - [ ] run the [e2e](https://github.com/ipfs/ipfs-companion/actions/workflows/e2e.yml) - - use `vX.Y.Z(-RCN)` as the Kubo image version - - [ ] wait for the [e2e](https://github.com/ipfs/ipfs-companion/actions/workflows/e2e.yml) workflow run to finish -
-- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Update Kubo in [ipfs-desktop](https://github.com/ipfs/ipfs-desktop)
using `./kuboreleaser release --version vX.Y.Z(-rcN) update-ipfs-desktop` or ... - - [ ] check out [ipfs/ipfs-desktop](https://github.com/ipfs/ipfs-desktop) - - [ ] run `npm install` - - [ ] create a PR which updates `package.json` and `package-lock.json` - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) add @SgtPooki and @whizzzkid as reviewers -
-- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Update Kubo docs
using `./kuboreleaser release --version vX.Y.Z(-rcN) update-ipfs-docs` or ... - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) run the [update-on-new-ipfs-tag.yml](https://github.com/ipfs/ipfs-docs/actions/workflows/update-on-new-ipfs-tag.yml) workflow - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) merge the PR created by the [update-on-new-ipfs-tag.yml](https://github.com/ipfs/ipfs-docs/actions/workflows/update-on-new-ipfs-tag.yml) workflow run -
-- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Ask Brave to update Kubo in Brave Desktop - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) use [this link](https://github.com/brave/brave-browser/issues/new?assignees=&labels=OS%2FDesktop&projects=&template=desktop.md&title=) to create an issue for the new Kubo version - - [basic example](https://github.com/brave/brave-browser/issues/31453), [example with additional notes](https://github.com/brave/brave-browser/issues/27965) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) post link to the issue in `#shared-pl-brave` for visibility -- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Create a blog entry on [blog.ipfs.tech](https://blog.ipfs.tech)
using `./kuboreleaser release --version vX.Y.Z(-rcN) update-ipfs-blog --date YYYY-MM-DD` or ... - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) create a PR which adds a release note for the new Kubo version - - [example](https://github.com/ipfs/ipfs-blog/pull/529) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) merge the PR - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) verify the blog entry was published -
-- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Merge the [release](https://github.com/ipfs/kubo/tree/release) branch back into [master](https://github.com/ipfs/kubo/tree/master), ignoring the changes to [version.go](version.go) (keep the `-dev`) version,
using `./kuboreleaser release --version vX.Y.Z(-rcN) merge-branch` or ... - - [ ] create a new branch `merge-release-vX.Y.Z` from `release` - - [ ] create and merge a PR from `merge-release-vX.Y.Z` to `master` -
-- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Prepare for the next release
using `./kuboreleaser release --version vX.Y.Z(-rcN) prepare-next` or ... - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Create the next [changelog](https://github.com/ipfs/kubo/blob/master/docs/changelogs/vX.(Y+1).md) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Link to the new changelog in the [CHANGELOG.md](CHANGELOG.md) file - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Create the next release issue -
-- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) Create a dependency update PR - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) check out [ipfs/kubo](https://github.com/ipfs/kubo) - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) run `go get -u` in root directory - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) run `go mod tidy` in root directory - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) run `go mod tidy` in `docs/examples/kubo-as-a-library` directory - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) create a PR which updates `go.mod` and `go.sum` - - [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) ![](https://img.shields.io/badge/not-PATCH-yellow?style=flat-square) add the PR to the next release milestone -- [ ] ![](https://img.shields.io/badge/only-FINAL-green?style=flat-square) Close the release issue +## Required -## How to contribute? + -Would you like to contribute to the IPFS project and don't know how? Well, there are a few places you can get started: +## Nice To Have (Optional) -- Check the issues with the `help wanted` label in the [ipfs/kubo repo](https://github.com/ipfs/kubo/issues?q=is%3Aopen+is%3Aissue+label%3A%22help+wanted%22) -- Join the discussion at [discuss.ipfs.tech](https://discuss.ipfs.tech/) and help users finding their answers. -- See other options at https://docs.ipfs.tech/community/ + From c0d7da22a204869222af11c5981a92362829f548 Mon Sep 17 00:00:00 2001 From: Marcin Rataj Date: Wed, 17 Jan 2024 15:59:02 +0100 Subject: [PATCH 21/23] docs(cli): name inspect --verify (#10308) Co-authored-by: Daniel Norman <1992255+2color@users.noreply.github.com> --- core/commands/name/name.go | 2 +- test/cli/name_test.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/core/commands/name/name.go b/core/commands/name/name.go index 37ab4df5352..9445fc362f0 100644 --- a/core/commands/name/name.go +++ b/core/commands/name/name.go @@ -245,7 +245,7 @@ Passing --verify will verify signature against provided public key. if out.Validation == nil { tw.Flush() - fmt.Fprintf(w, "\nThis record was not validated.\n") + fmt.Fprintf(w, "\nThis record was not verified. Pass '--verify k51...' to verify.\n") } else { tw.Flush() fmt.Fprintf(w, "\nValidation results:\n") diff --git a/test/cli/name_test.go b/test/cli/name_test.go index e0f2f090962..42c649c09b5 100644 --- a/test/cli/name_test.go +++ b/test/cli/name_test.go @@ -172,7 +172,7 @@ func TestName(t *testing.T) { res = node.PipeToIPFS(bytes.NewReader(record), "name", "inspect") out := res.Stdout.String() - require.Contains(t, out, "This record was not validated.") + require.Contains(t, out, "This record was not verified.") require.Contains(t, out, publishPath) require.Contains(t, out, "30m") @@ -198,7 +198,7 @@ func TestName(t *testing.T) { t.Parallel() res = node.PipeToIPFS(bytes.NewReader(record), "name", "inspect") out := res.Stdout.String() - require.Contains(t, out, "This record was not validated.") + require.Contains(t, out, "This record was not verified.") require.Contains(t, out, publishPath) require.Contains(t, out, "30m") require.Contains(t, out, "Signature Type: V1+V2") From 4790618a292b5d2c7b6ad788929484a07b48b767 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Thu, 18 Jan 2024 17:26:54 +0100 Subject: [PATCH 22/23] chore: remove Gateway.APICommands Remove unused and undocumented gateway configuration field introduced in go-ipfs v0.4 --- config/gateway.go | 3 --- config/init.go | 1 - 2 files changed, 4 deletions(-) diff --git a/config/gateway.go b/config/gateway.go index 9c0830c506b..0ed07d7cdb9 100644 --- a/config/gateway.go +++ b/config/gateway.go @@ -53,9 +53,6 @@ type Gateway struct { // PathPrefixes was removed: https://github.com/ipfs/go-ipfs/issues/7702 PathPrefixes []string - // FIXME: Not yet implemented: https://github.com/ipfs/kubo/issues/8059 - APICommands []string - // NoFetch configures the gateway to _not_ fetch blocks in response to // requests. NoFetch bool diff --git a/config/init.go b/config/init.go index e4cb1e95a54..13d3b9b1961 100644 --- a/config/init.go +++ b/config/init.go @@ -68,7 +68,6 @@ func InitWithIdentity(identity Identity) (*Config, error) { NoFetch: false, PathPrefixes: []string{}, HTTPHeaders: map[string][]string{}, - APICommands: []string{}, }, Reprovider: Reprovider{ Interval: nil, From d1db95c447490d3e4ec56416a3718d8917f02b81 Mon Sep 17 00:00:00 2001 From: Henrique Dias Date: Fri, 19 Jan 2024 11:20:28 +0100 Subject: [PATCH 23/23] config: remove all options that are marked as REMOVED Most of the removed options are many years old. In addition, they've all been removed in past iterations of Kubo. Some options were marked as removed in the config.md, but we still had a warning in the code to let users know they have been removed. I think it's been long enough for all of this options, and enough Kubo iterations in order to alert the users. It is good to keep it in the config.md for now so that people can actually check. However, I think it's time to remove them from the code itself. --- cmd/ipfs/kubo/daemon.go | 15 --------------- config/discovery.go | 4 ---- config/gateway.go | 6 ------ config/init.go | 1 - config/swarm.go | 24 ------------------------ core/node/groups.go | 18 ------------------ core/node/libp2p/sec.go | 9 --------- core/node/libp2p/smux.go | 3 --- docs/config.md | 2 +- 9 files changed, 1 insertion(+), 81 deletions(-) diff --git a/cmd/ipfs/kubo/daemon.go b/cmd/ipfs/kubo/daemon.go index 31e5fe28d8f..ae755648e07 100644 --- a/cmd/ipfs/kubo/daemon.go +++ b/cmd/ipfs/kubo/daemon.go @@ -68,7 +68,6 @@ const ( routingOptionAutoClientKwd = "autoclient" unencryptTransportKwd = "disable-transport-encryption" unrestrictedAPIAccessKwd = "unrestricted-api" - writableKwd = "writable" enablePubSubKwd = "enable-pubsub-experiment" enableIPNSPubSubKwd = "enable-namesys-pubsub" enableMultiplexKwd = "enable-mplex-experiment" @@ -164,7 +163,6 @@ Headers. cmds.StringOption(initProfileOptionKwd, "Configuration profiles to apply for --init. See ipfs init --help for more"), cmds.StringOption(routingOptionKwd, "Overrides the routing option").WithDefault(routingOptionDefaultKwd), cmds.BoolOption(mountKwd, "Mounts IPFS to the filesystem using FUSE (experimental)"), - cmds.BoolOption(writableKwd, "Enable legacy Gateway.Writable (REMOVED)"), cmds.StringOption(ipfsMountKwd, "Path to the mountpoint for IPFS (if using --mount). Defaults to config setting."), cmds.StringOption(ipnsMountKwd, "Path to the mountpoint for IPNS (if using --mount). Defaults to config setting."), cmds.BoolOption(unrestrictedAPIAccessKwd, "Allow API access to unlisted hashes"), @@ -803,15 +801,6 @@ func serveHTTPGateway(req *cmds.Request, cctx *oldcmds.Context) (<-chan error, e return nil, fmt.Errorf("serveHTTPGateway: GetConfig() failed: %s", err) } - writable, writableOptionFound := req.Options[writableKwd].(bool) - if !writableOptionFound { - writable = cfg.Gateway.Writable.WithDefault(false) - } - - if writable { - log.Fatalf("Support for Gateway.Writable and --writable has been REMOVED. Please remove it from your config file or CLI. Modern replacement tracked in https://github.com/ipfs/specs/issues/375") - } - listeners, err := sockets.TakeListeners("io.ipfs.gateway") if err != nil { return nil, fmt.Errorf("serveHTTPGateway: socket activation failed: %s", err) @@ -876,10 +865,6 @@ func serveHTTPGateway(req *cmds.Request, cctx *oldcmds.Context) (<-chan error, e opts = append(opts, corehttp.RedirectOption("", cfg.Gateway.RootRedirect)) } - if len(cfg.Gateway.PathPrefixes) > 0 { - log.Fatal("Support for custom Gateway.PathPrefixes was removed: https://github.com/ipfs/go-ipfs/issues/7702") - } - node, err := cctx.ConstructNode() if err != nil { return nil, fmt.Errorf("serveHTTPGateway: ConstructNode() failed: %s", err) diff --git a/config/discovery.go b/config/discovery.go index 274ae051cef..4ddc3a82f08 100644 --- a/config/discovery.go +++ b/config/discovery.go @@ -6,8 +6,4 @@ type Discovery struct { type MDNS struct { Enabled bool - - // DEPRECATED: the time between discovery rounds is no longer configurable - // See: https://github.com/ipfs/go-ipfs/pull/9048#discussion_r906814717 - Interval *OptionalInteger `json:",omitempty"` } diff --git a/config/gateway.go b/config/gateway.go index 0ed07d7cdb9..fa093245d9a 100644 --- a/config/gateway.go +++ b/config/gateway.go @@ -47,12 +47,6 @@ type Gateway struct { // should be redirected. RootRedirect string - // REMOVED: modern replacement tracked in https://github.com/ipfs/specs/issues/375 - Writable Flag `json:",omitempty"` - - // PathPrefixes was removed: https://github.com/ipfs/go-ipfs/issues/7702 - PathPrefixes []string - // NoFetch configures the gateway to _not_ fetch blocks in response to // requests. NoFetch bool diff --git a/config/init.go b/config/init.go index 13d3b9b1961..e3d0af30d9e 100644 --- a/config/init.go +++ b/config/init.go @@ -66,7 +66,6 @@ func InitWithIdentity(identity Identity) (*Config, error) { Gateway: Gateway{ RootRedirect: "", NoFetch: false, - PathPrefixes: []string{}, HTTPHeaders: map[string][]string{}, }, Reprovider: Reprovider{ diff --git a/config/swarm.go b/config/swarm.go index 16c52b4a5dd..f15634b578a 100644 --- a/config/swarm.go +++ b/config/swarm.go @@ -13,26 +13,6 @@ type SwarmConfig struct { // DisableNatPortMap turns off NAT port mapping (UPnP, etc.). DisableNatPortMap bool - // DisableRelay explicitly disables the relay transport. - // - // Deprecated: This flag is deprecated and is overridden by - // `Swarm.Transports.Relay` if specified. - DisableRelay bool `json:",omitempty"` - - // EnableRelayHop makes this node act as a public relay v1 - // - // Deprecated: The circuit v1 protocol is deprecated. - // Use `Swarm.RelayService` to configure the circuit v2 relay. - EnableRelayHop bool `json:",omitempty"` - - // EnableAutoRelay enables the "auto relay user" feature. - // Node will find and use advertised public relays when it determines that - // it's not reachable from the public internet. - // - // Deprecated: This flag is deprecated and is overridden by - // `Swarm.RelayClient.Enabled` if specified. - EnableAutoRelay bool `json:",omitempty"` - // RelayClient controls the client side of "auto relay" feature. // When enabled, the node will use relays if it is not publicly reachable. RelayClient RelayClient @@ -112,8 +92,6 @@ type Transports struct { Security struct { // Defaults to 100. TLS Priority `json:",omitempty"` - // Defaults to 200. - SECIO Priority `json:",omitempty"` // Defaults to 300. Noise Priority `json:",omitempty"` } @@ -123,8 +101,6 @@ type Transports struct { Multiplexers struct { // Defaults to 100. Yamux Priority `json:",omitempty"` - // Defaults to -1. - Mplex Priority `json:",omitempty"` } } diff --git a/core/node/groups.go b/core/node/groups.go index e1e2e4b9c98..4572a2ddd80 100644 --- a/core/node/groups.go +++ b/core/node/groups.go @@ -122,24 +122,6 @@ func LibP2P(bcfg *BuildCfg, cfg *config.Config, userResourceOverrides rcmgr.Part } } - // Force users to migrate old config. - // nolint - if cfg.Swarm.DisableRelay { - logger.Fatal("The 'Swarm.DisableRelay' config field was removed." + - "Use the 'Swarm.Transports.Network.Relay' instead.") - } - // nolint - if cfg.Swarm.EnableAutoRelay { - logger.Fatal("The 'Swarm.EnableAutoRelay' config field was removed." + - "Use the 'Swarm.RelayClient.Enabled' instead.") - } - // nolint - if cfg.Swarm.EnableRelayHop { - logger.Fatal("The `Swarm.EnableRelayHop` config field was removed.\n" + - "Use `Swarm.RelayService` to configure the circuit v2 relay.\n" + - "If you want to continue running a circuit v1 relay, please use the standalone relay daemon: https://dist.ipfs.tech/#libp2p-relay-daemon (with RelayV1.Enabled: true)") - } - // Gather all the options opts := fx.Options( BaseLibP2P, diff --git a/core/node/libp2p/sec.go b/core/node/libp2p/sec.go index 820ba22d6d1..0dc6940d8f9 100644 --- a/core/node/libp2p/sec.go +++ b/core/node/libp2p/sec.go @@ -8,11 +8,6 @@ import ( tls "github.com/libp2p/go-libp2p/p2p/security/tls" ) -const secioEnabledWarning = `The SECIO security transport was enabled in the config but is no longer supported. - -SECIO disabled by default in go-ipfs 0.7 removed in go-ipfs 0.9. Please remove -Swarm.Transports.Security.SECIO from your IPFS config.` - func Security(enabled bool, tptConfig config.Transports) interface{} { if !enabled { return func() (opts Libp2pOpts) { @@ -23,10 +18,6 @@ func Security(enabled bool, tptConfig config.Transports) interface{} { } } - if _, enabled := tptConfig.Security.SECIO.WithDefault(config.Disabled); enabled { - log.Error(secioEnabledWarning) - } - // Using the new config options. return func() (opts Libp2pOpts) { opts.Opts = append(opts.Opts, prioritizeOptions([]priorityOption{{ diff --git a/core/node/libp2p/smux.go b/core/node/libp2p/smux.go index a276b5ddc16..d52b306d85b 100644 --- a/core/node/libp2p/smux.go +++ b/core/node/libp2p/smux.go @@ -14,9 +14,6 @@ func makeSmuxTransportOption(tptConfig config.Transports) (libp2p.Option, error) if prefs := os.Getenv("LIBP2P_MUX_PREFS"); prefs != "" { return nil, fmt.Errorf("configuring muxers with LIBP2P_MUX_PREFS is no longer supported, use Swarm.Transports.Multiplexers") } - if tptConfig.Multiplexers.Mplex != 0 { - return nil, fmt.Errorf("Swarm.Transports.Multiplexers.Mplex is no longer supported, remove it from your config, see https://github.com/libp2p/specs/issues/553") - } if tptConfig.Multiplexers.Yamux < 0 { return nil, fmt.Errorf("running libp2p with Swarm.Transports.Multiplexers.Yamux disabled is not supported") } diff --git a/docs/config.md b/docs/config.md index fd0c0a23ed3..6a336a66cbc 100644 --- a/docs/config.md +++ b/docs/config.md @@ -2222,7 +2222,7 @@ Type: `priority` #### `Swarm.Transports.Security.SECIO` -Support for SECIO has been removed. Please remove this option from your config. +**REMOVED**: support for SECIO has been removed. Please remove this option from your config. #### `Swarm.Transports.Security.Noise`