mrusme / superhighway84

USENET-inspired, uncensorable, decentralized internet discussion system running on IPFS & OrbitDB
https://xn--gckvb8fzb.com/superhighway84
GNU General Public License v3.0
694 stars 24 forks source link

New IPFS Repo Version #38

Open mrd0ll4r opened 2 years ago

mrd0ll4r commented 2 years ago

go-ipfs v0.12 was released. This introduced repo version 12. I upgraded IPFS, upgraded my repo, but now superhighway84 doesn't like it anymore, which is understandable:

panic: Your programs version (11) is lower than your repos (12).
Please update ipfs to a version that supports the existing repo, or run
a migration in reverse.

See https://github.com/ipfs/fs-repo-migrations/blob/master/run.md for details.

goroutine 1 [running]:
log.Panicln({0xc001d59f48, 0xc0000ec400, 0xc000181500})
        /opt/hostedtoolcache/go/1.17.6/x64/src/log/log.go:368 +0x65
main.main()
        /home/runner/work/superhighway84/superhighway84/superhighway84.go:87 +0x5e6

What's the plan? I'm using a separate IPFS_PATH for superhighway84 with repo version 11 now, which works, but I guess we'll have to upgrade at some point...

mrusme commented 2 years ago

Well, Superhighway84 is depending on go-orbit-db which atm is still using an older version. I tried upgrading to the latest go-orbit-db a few days ago but it failed due to some dependency issues that seem to happen rn in go-orbit-db.

mrusme commented 2 years ago

Checked again:

go: downloading github.com/ipfs/go-ipfs v0.12.0
go: downloading github.com/whyrusleeping/cbor-gen v0.0.0-20220224212727-7a699437a831
go: downloading github.com/libp2p/go-libp2p-swarm v0.10.2
go: downloading github.com/libp2p/go-tcp-transport v0.5.1
go: downloading github.com/libp2p/go-mplex v0.5.0
go: downloading github.com/klauspost/compress v1.14.4
go: downloading golang.org/x/mobile v0.0.0-20220224134551-8a0a1e50732f
go: downloading golang.org/x/exp/shiny v0.0.0-20220218215828-6cf2b201936e
go: downloading golang.org/x/exp v0.0.0-20220218215828-6cf2b201936e
go: downloading github.com/godbus/dbus/v5 v5.1.0
# github.com/libp2p/go-libp2p-mplex
../../../.go/pkg/mod/github.com/libp2p/go-libp2p-mplex@v0.5.0/transport.go:21:32: multiple-value multiplex.NewMultiplex() in single-value context
# github.com/libp2p/go-libp2p/p2p/protocol/circuitv2/client
../../../.go/pkg/mod/github.com/libp2p/go-libp2p@v0.17.0/p2p/protocol/circuitv2/client/client.go:32:13: undefined: upgrader.Upgrader
../../../.go/pkg/mod/github.com/libp2p/go-libp2p@v0.17.0/p2p/protocol/circuitv2/client/client.go:57:33: undefined: upgrader.Upgrader
../../../.go/pkg/mod/github.com/libp2p/go-libp2p@v0.17.0/p2p/protocol/circuitv2/client/transport.go:21:42: undefined: upgrader.Upgrader

Something still doesn't seem right with the dependencies.

mrusme commented 2 years ago

Unlike what the comment in the linked go-libp2p stated randomly removing indirect dependencies and basically go get-ing everything from scratch finally fixed the upgrade issues. Man, IPFSs really exaggerates it with dependencies and it seems there's no documentation which version of lib A works with what versions of lib B. Anyway, at least Superhighway84 is now running the latest go-orbit-db release.

mrd0ll4r commented 2 years ago

Man, IPFSs really exaggerates it with dependencies and it seems there's no documentation which version of lib A works with what versions of lib B. Anyway, at least Superhighway84 is now running the latest go-orbit-db release.

I can very much relate :) Thanks for looking into it!

mrusme commented 2 years ago

FYI: go-orbit-db was upgraded to 1.17.1, which now uses go-ipfs 0.12.2. I have just pushed an update, 0.2.0, which includes the updated libraries. Now Superhighway84 is able to run on IPFS 0.12 repositories!

mister-monster commented 1 year ago

the same thing is now happening with regard to program version 12 and repo version 13...

mrusme commented 1 year ago

Sorry, yeah, it's really a little bit of a PITA. :-( Will have a look!

timecool-cpu commented 1 year ago

@mrusme I get the same question but i cannot solve it: Your programs version (13) is lower than your repos (14).

i download the fs-repo-migrations and run that but get the error:migrations/fs-repo-migrations ; exit; Could not get available repo migrations: http.DefaultClient.Do error: Get "https://ipfs.io/ipns/dist.ipfs.io/fs-repo-10-to-11/versions": dial tcp 52.58.1.161:443: i/o timeout

mrusme commented 1 year ago

@timecool-cpu yeah, version incompatibilities are a tough sell for IPFS unfortunately. Ultimately if you don't care, you can just delete the whole IPFS repo and re-initialize it with the version that Superhighway84 is using. Alternatively, I've described in the README how you can use a dedicated IPFS repo for Superhighway84. You'd need to have the IPFS CLI in that version around nevertheless.