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

chore: release js-ipfs 0.1.0 #4026

Closed
wants to merge 1 commit into from
Closed

Conversation

github-actions[bot]
Copy link
Contributor

🤖 I have created a release *beep* *boop*

0.1.0 (2022-01-25)

⚠ BREAKING CHANGES

  • node 15+ is required
  • pubsub: We had to make breaking changes to pubsub commands sent over HTTP RPC to fix data corruption caused by topic names and payload bytes that included \n. More details in Pubsub subscription data encoding kubo#7939 and fix: multibase in pubsub http rpc kubo#8183
  • On decode of CBOR blocks, undefined values will be coerced to null
  • ipfs.dag.put no longer accepts a format arg, it is now storeCodec and inputCodec. 'json' has become 'dag-json', 'cbor' has become 'dag-cbor' and so on
  • The DHT API has been refactored to return async iterators of query events
  • errors will now be thrown if multiple items are passed to ipfs.add or single items to ipfs.addAll (n.b. you can still pass a list of a single item to ipfs.addAll)
  • the globSource api has changed from globSource(dir, opts) to globSource(dir, pattern, opts)
  • There are no default exports and everything is now dual published as ESM/CJS
  • rateIn/rateOut are returned as numbers
  • the output type of ipfs.get has changed and the recursive option has been removed from ipfs.ls since it was not supported everywhere
  • resolve is now recursive by default
  • ipld-formats no longer supported, use multiformat BlockCodecs instead
  • pulls in new multiformats modules
  • Minimum supported node version is 14
  • all core api methods now have types, some method signatures have changed, named exports are now used by the http, grpc and ipfs client modules
  • ipfs-repo upgrade requires repo migration to v10
  • The websocket transport will only dial DNS+WSS addresses - see https://github.com/libp2p/js-libp2p-websockets/releases/tag/v0.15.0
  • electron-webrtc was accidentally bundled with ipfs, now it needs installing separately
  • only dag-pb, dag-cbor and raw formats are supported out of the box, any others will need to be configured during node startup.
  • types returned by ipfs.files.ls are now strings, in line with the docs but different to previous behaviour
  • Buffer is no longer exported from core
  • this removes support for SECIO making Noise the only security transport.
  • Co-authored-by: Marcin Rataj [email protected]
  • remove support for key.export over the http api
    • fix: make http api only accept POST requests
  • Also updates all examples to use the new API.
  • As part of the async iterator refactor some peer IDs were being returned as CIDs - the conversion was done in IPFS but not in libp2p, which meant that where IPFS exposes libp2p directly, peer IDs were being returned as strings, e.g. pubsub topic subscribers, message senders, etc.
  • A roundup of the following PRs:
    • feat: return CID of flushed path from ipfs.files.flush
      • fix: writing mfs files using offsets bigger than the file now works
  • format option is no longer supported as everything is dag-pb all of the time.
  • IPFS is all dag-pb yet we allow passing dag-cbor as the format of IPLD node to use. This is likely to break anything that uses it as tools expect IPFS stuff to be dag-pb, possibly with raw leaves.
  • Switch to using async/await and async iterators.
  • Adds mode and mtime properties to normalised .add inputs, also adds functions for turning metadata into strings for CLI use.
  • Support for Node.js streams and Pull Streams has been removed
  • This is a round up of the remaining async/await PRs along with some cleanup and docs fixes.
  • Errors returned from request failures are now all HTTPErrors which carry a response property. This is a Response that can be used to inspect all information relating to the HTTP response. This means that the err.status or err.statusCode property should now be accessed via err.response.status.
  • files in src/files-regular have moved to src. The src/files-mfs directory has been renamed to src/files. If you were previously requiring files from these directories e.g. require('ipfs-http-client/src/files-regular/add') then please be aware that they have moved.
  • All places in the API that used callbacks are now replaced with async/await
  • Also corrects ipfs.config.profiles.list example.
  • New method:
  • swarm tests need promise based setup check PRs below
  • pubsub is now enabled by default and the experimental flag was removed
  • recursive is now true by default in ipfs resolve
  • The default pubsub implementation has changed from floodsub to gossipsub. Additionally, to enable pubsub programmatically set pubsub.enabled: true instead of EXPERIMENTAL.pubsub: true or via the CLI pass --enable-pubsub instead of --enable-pubsub-experiment to jsipfs daemon.
  • This module used to export a class that extended EventEmitter, now it exports a function that returns an async iterable.
  • Pulled out of feat: support adding async iterators #2379.
  • gateway: Gateway now implicitly responds with the contents of /index.html when accessing a directory / instead of redirecting to /index.html.
  • This is part of the Awesome Endeavour: Async Iterators: Awesome Endeavour: Async Iterators #1670
  • v1 CIDs created by this module now default to base32 encoding when stringified
  • The default string encoding for version 1 CIDs has changed to base32.
  • ipfs.refs now returns objects with camelCase properties not PascalCase properties. i.e. { ref, err } not { Ref, Err }
  • Browser application bundles now include only ipld-dag-pb, ipld-dag-cbor and ipld-raw IPLD codecs. Other codecs should be added manually, see https://github.com/ipfs/js-ipfs/blob/master/README.md#optionsipld for details.
  • Constructor config validation is now a bit more strict - it does not allow null values or unknown properties.
  • Allows users to access these additional types and utilities without having to create an instance of the client first.
  • Allows users to access these additional types and utilities without having to create an instance first.
  • refs test: fix resolve test ipfs-inactive/interface-js-ipfs-core#385 resolves The resolve command should work even if the path ends in the middle of an object #1763
  • --local option has been renamed to --offline
  • All API methods that returned big.js instances now return bignumber.js instances.
  • All API methods that returned big.js instances now return bignumber.js instances.
  • DHT API methods renamed and return types changed
  • For the back story on this change, please see: fix: updates ipld-dag-pb dep to version without .cid or .multihash properties ipfs-inactive/interface-js-ipfs-core#388 (review)
  • the ipfs-api library has been renamed to ipfs-http-client.
  • Object API refactor.
  • Files API methods add*, cat*, get* have moved from files to the root namespace.
  • Files API methods add*, cat*, get* have moved from files to the root namespace.
  • dag-cbor nodes now represent links as CID objects
  • No further changes are needed as js-ipfs-api is getting the raw blocks from IPFS and does the whole parsing client-sided in JavaScript.
  • Prior to this change the ipld-dag-cbor and ipld-dag-pb modules are re-exported so that can be accessed within the Browser bundle. Those modules normally don't need to be used directly, they are kind of implementation details of IPLD. Hence remove them.
  • Prior to this change the ipld-dag-cbor and ipld-dag-pb modules are re-exported so that can be accessed within the Browser bundle. Those modules normally don't need to be used directly, they are kind of implementation details of IPLD. Hence remove them.
  • Requires go-ipfs 0.4.17 as it allows for specifying the data encoding format when requesting object data.
    • new: libp2p.modules.peerDiscovery
  • Consumers of this test suite now have fine grained control over what tests are run. Tests can now be skipped and "onlyed" (run only specific tests). This can be done on a test, command and sub-system level. See the updated usage guide for instructions: https://github.com/ipfs/interface-ipfs-core/blob/master/README.md#usage.
  • pubsub.unsubscribe is now async and argument order for pubsub.subscribe has changed
  • pubsub.unsubscribe is now async and argument order for pubsub.subscribe has changed

Features

@achingbrain achingbrain deleted the release-js-ipfs-v0.1.0 branch January 26, 2022 07:09
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The resolve command should work even if the path ends in the middle of an object
1 participant