Skip to content
This repository has been archived by the owner on Feb 12, 2024. It is now read-only.

Releases: ipfs/js-ipfs

v0.41.0-rc.1

10 Feb 14:52
Compare
Choose a tag to compare
v0.41.0-rc.1 Pre-release
Pre-release

Bug Fixes

Features

v0.41.0-rc.0

03 Feb 21:01
Compare
Choose a tag to compare
v0.41.0-rc.0 Pre-release
Pre-release

Bug Fixes

Code Refactoring

Features

Performance Improvements

  • expose importer concurrency controls when adding files (#2637) (1d19c4f)

BREAKING CHANGES

  • Where PeerIDs were previously CIDs, now they are Strings
  • ipfs.bitswap.stat().peers[n] is now a String (was a CID)
  • ipfs.dht.findPeer().id is now a String (was a CID)
  • ipfs.dht.findProvs()[n].id is now a String (was a CID)
  • ipfs.dht.provide()[n].id is now a String (was a CID)
  • ipfs.dht.put()[n].id is now a String (was a CID)
  • ipfs.dht.query()[n].id is now a String (was a CID)
  • ipfs.id().id is now a String (was a CID)
  • ipfs.id().addresses[n] are now Multiaddrs (were Strings)
  • Removes all codec/format options, everything is dag-pb now.

v0.40.0

02 Dec 15:02
Compare
Choose a tag to compare

🔦 Highlights

Migrations are not just for ducks. We're paving the way for the dweb in the browser by laying foundations to switch to a hash format that can be used in URL origins 🛣

🦆 New repo migrations tool

Ever worked on an application where you've had to write a database migration? Yeah, us too. Up until now js-ipfs hasn't been able to migrate repo's to a new format. Well, that's not strictly true, you could have used the go-ipfs repo migration tool on a repo created when running js-ipfs in Node.js (yes, we have repo compatibility!), but in the browser you were stuck.

..and I mean really stuck, if we'd updated the format of a repo that ships with js-ipfs then your applications would just have to catch an error that the repo version was not compatible. You couldn't use it, and you couldn't upgrade. Bad news bears 🐻.

We had a cunning strategy to avoid this situation - do not change the repo 😂, but this is rapidly becoming unsustainable since we actually want to add a migration to achieve our dream of base32 encoded v1 (by default) CIDs.

Good news friends! The new version of js-ipfs now ships with a repo migration tool that'll automatically migrate repo's in the browser. So now all our ducks are in a line, stay tuned for a migration and a switch to v1 CIDs ✨!

🎻 base32 encoded CIDs in IPNS paths

My violin strings gently weep for being able to use Peer IDs in a domain, and let me tell you why.

Peer IDs currently cannot be used in a domain name because their string format is base58 - a case SENSITIVE encoding. In domain names the following are equivalent:

QmNib2c1qCVSbp9QPT81RmDSg3n8kFgPsMCdj4gpveJESE
qmnib2c1qcvsbp9qpt81rmdsg3n8kfgpsmcdj4gpvejese
QMNIB2C1QCVSBP9QPT81RMDSG3N8KFGPSMCDJ4GPVEJESE

So, bad times.

...but wait, Peer IDs ARE CIDs! I know, weird, but also rad because in theory we should be able to re-encode them as base32. Right now though, everything expects a base58 encoded string (a v0 CID) because they're actually just a multihash.

In this js-ipfs release we've made a small change to allow you to take your Peer ID (a v0 CID), convert it to a base32 encoded v1 CID and use it in an IPNS path like /ipns/bafybeidta3hkxk3ihxfsk765oswgsjhmvcnkeestyuov6r2t5tyts4xuoe. You can take advantage of cid.ipfs.io (base32 version is provided for your convenience at the very bottom of the page) or do the conversion with the command line tools:

jsipfs id | json id | jsipfs cid base32
bafybeidta3hkxk3ihxfsk765oswgsjhmvcnkeestyuov6r2t5tyts4xuoe

This is really, seriously cool, because now Peer IDs can be used in domain names and so an IPFS gateway operating at bafybeidta3hkxk3ihxfsk765oswgsjhmvcnkeestyuov6r2t5tyts4xuoe.ipns.dweb.link for example, will have origin isolation (hooray for security 🔒) AND IPNS enabled mutable data 🚀⚡️

To ease the transition we support CID v0 converted to v1 (with dag-pb multicodec). In the future, new Peer IDs will be v1 CIDs with self-describing libp2p-key codec that is base32 encoded by default...but that's a change for another day.

🌲 Implemented dag put and dag resolve CLI commands

These have been available in core for a while now and we finally got round to surfacing them in the CLI. e.g.

$ jsipfs dag put '""IPLD RULEZ""'
bafyreia5coklfzblgd3reqwaieafmpasdceqmcnjrowre3623mtb4nxlhm

$ jsipfs dag put '{"to": {"/": "bafyreia5coklfzblgd3reqwaieafmpasdceqmcnjrowre3623mtb4nxlhm"}}'
bafyreiequnkfflujkwhxk6wud5w64hmijdqdmx7p55fgrbiizw32kdrb7e

$ jsipfs dag put '{"path": {"/": "bafyreiequnkfflujkwhxk6wud5w64hmijdqdmx7p55fgrbiizw32kdrb7e"}}'
bafyreidgfdsoupe747qnjzkjk2yirgv76wr4drev3i7kv6dht4dkypusze

$ jsipfs dag resolve bafyreidgfdsoupe747qnjzkjk2yirgv76wr4drev3i7kv6dht4dkypusze/path/to
bafyreia5coklfzblgd3reqwaieafmpasdceqmcnjrowre3623mtb4nxlhm

$ jsipfs dag get bafyreia5coklfzblgd3reqwaieafmpasdceqmcnjrowre3623mtb4nxlhm
IPLD RULEZ

🏗 API Changes

  • dag.put got a pin option to save you from calling the pin API separately (and potentially losing your node if GC runs inbetween!)

❤️ Huge thank you to everyone that made this release possible

Read more

v0.39.1

02 Dec 13:36
Compare
Choose a tag to compare

Bug Fixes

v0.40.0-rc.1

28 Nov 13:00
Compare
Choose a tag to compare
v0.40.0-rc.1 Pre-release
Pre-release

Bug Fixes

v0.40.0-rc.0

11 Nov 14:37
Compare
Choose a tag to compare
v0.40.0-rc.0 Pre-release
Pre-release

Bug Fixes

Features

v0.39.0

23 Oct 12:34
Compare
Choose a tag to compare

Features

Bug Fixes

v0.38.1

18 Oct 10:17
Compare
Choose a tag to compare

Bug Fixes

v0.39.0-rc.2

17 Oct 16:48
Compare
Choose a tag to compare
v0.39.0-rc.2 Pre-release
Pre-release

Bug Fixes

v0.39.0-rc.1

15 Oct 14:11
Compare
Choose a tag to compare
v0.39.0-rc.1 Pre-release
Pre-release
chore: release version v0.39.0-rc.1