Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Catalog and figure out what to do with js-ipfs content #1611

Closed
ElPaisano opened this issue Jun 1, 2023 · 9 comments · Fixed by #1620 or #1639
Closed

Catalog and figure out what to do with js-ipfs content #1611

ElPaisano opened this issue Jun 1, 2023 · 9 comments · Fixed by #1620 or #1639
Assignees

Comments

@ElPaisano
Copy link
Contributor

ElPaisano commented Jun 1, 2023

Public notion link https://pl-strflt.notion.site/ipfs-docs-js-ipfs-cleanup-d46e22253bec4497865c38e7a9277eac

Per Jun 1. 2023 helia WG meeting, the team would like to catalog all mentions of js-ipfs and figure out whether to delete, modify or keep content.

What this issue is doing

This is issue is for cataloging and discussing the js-ipfs mentions in the docs. A PR will be created to update content once consensus is reached.

Notes

This is an important part of ipfs/js-ipfs#4336.

General principles:

  1. Let's not point to technology that isn't maintained or supported. It's better to have less information than inaccurate information.
  2. This is going to hit on assumptions in the past that Kubo and js-ipfs are the only IPFS implementations. docs.ipfs.tech should discuss IPFS concepts and point to various implementations which manage their own documentation. This is going to be the main driver of deleting content.
  3. Valid content around IPFS in JS that should stay around will be converted to Helia instead of js-ipfs.
@ElPaisano ElPaisano added the need/triage Needs initial labeling and prioritization label Jun 1, 2023
@ElPaisano ElPaisano self-assigned this Jun 1, 2023
@BigLep
Copy link
Contributor

BigLep commented Jun 1, 2023

Thanks for creating this @ElPaisano . This will be great. A couple of things:

  1. I made a couple of updates into the issue description.
  2. I assume you're going to do a grep for "js-ipfs". It would be great to get you analysis of how to handle each occurrence, but I am also happy to run through this with you too synchronously and make some quick decisions of delete or modify.

@ElPaisano
Copy link
Contributor Author

Grep is indeed to plan @BigLep. I like the idea of a sync meeting to crank through the list. I'll set something up on the cal for Monday or Tuesday

@ElPaisano
Copy link
Contributor Author

./install/ipfs-companion.md

16:- Install IPFS for JavaScript

./install/server-infrastructure.md

35:- _Integration-ready

./install/js-ipfs.md

2:title
3:description
6:# Install IPFS for JavaScript (js-ipfs)
9:### js-ipfs being discontinued
10:Development of the [js-ipfs project](https
12:Because of this, js-ipfs tutorials may be out of date, and will eventually be archived.
16:This guide will walk you through the basics of using JS-IPFS, an implementation of IPFS in JavaScript. JS-IPFS is one of multiple IPFS implementations. You will learn how to install and spawn a node using the available libraries, and add, retrieve, read, and remove files. If you are unsure about the meaning of some terms, check out the glossary.
24:There are two ways to work with IPFS using JavaScript; the JS-IPFS library or the HTTP client. We'll show you how to use both in this guide.
26:## Install JS-IPFS
32:### JS-IPFS module
40:Alternatively, you can build the project from the source. See the [JS-IPFS GitHub repository](https
54:Alternatively, you can build the project from the source. See the [JS-IPFS GitHub repository](https
82: js-ipfs version
167:The JS-IPFS implementation is split into several Node.js modules. The following section shows examples of using the HTTP client to connect to IPFS. For more information on the different modules, examine the API Packages table
236:Now you can start to add files using JS-IPFS to the IPFS network.
240:As the JS-IPFS implementation changes, some of these steps should be deemed conditional. Please reference the [source packages](https

./welcome-builders.md

36:- With implementations in [Go](https

./quickstart/publish_cli.md

118:- If you prefer to upload a file programmatically with JavaScript or Go, check out the [Web3.storage docs](https

./quickstart/publish.md

114:- If you prefer to upload a file programmatically with JavaScript or Go, check out the [Web3.storage docs](https

./how-to/best-practices-for-nft-data.md

38:In JavaScript, you can use the following options for the ipfs.add method
40:```javascript
126:In javascript, you can set the wrapWithDirectory option when calling `ipfs.add`

./how-to/companion-window-ipfs.md

26:IPFS Companion exposes a subset of IPFS APIs as window.ipfs on every webpage. This means websites can detect that window.ipfs already exists and use it instead of spawning their own js-ipfs node, which saves resources, battery, etc.
62: // (fallback to js-ipfs or js-ipfs-http-client goes here)
70: // (fallback to js-ipfs or js-ipfs-http-client goes here)
76:Use [ipfs-provider](https
95:It is an IPFS proxy endpoint that enables you to obtain an IPFS API instance. Depending how IPFS Companion is configured, you may be talking directly to a js-ipfs node running in Companion, a kubo daemon over js-ipfs-http-client, or a js-ipfs daemon over js-ipfs-http-client ... and potentially others in the future. Note that object returned by window.ipfs.enable is not an instance of js-ipfs or js-ipfs-http-client, but is a proxy to one of them, so don't expect to be able to detect either of them or be able to use any undocumented or instance-specific functions.
97:For information on available functions, see the [js-ipfs](https
109:Spawn a dedicated js-ipfs instance if you need non-standard configuration or any experimental features.

./how-to/companion-node-types.md

70:An embedded node is a js-ipfs instance running in the browser in-memory, without the need for any external software.
78:Power users can provide [custom config](https
80:Please note that there are some limitations when running an embedded js-ipfs instance in the browser context using Companion
82:- Embedded js-ipfs cannot act as an HTTP gateway; the extension uses a public one as a fallback.
83:- Running an embedded js-ipfs instance is known to be CPU-hungry over time, which may drain your battery. See GitHub issues ([#450](https
84:- Missing DHT (see [js-ipfs/#856](https
85:- Default transports limited to websockets ([js-ipfs/#1088](https
86: - Lack of connection closing ([ipfs/js-ipfs#962](https
87: - Missing relay discovery ([js-ipfs/v0.29.x/examples/circuit-relaying](https

./how-to/create-simple-chat-app.md

3:description
9:### js-ipfs being discontinued
10:Development of the [js-ipfs project](https
12:Because of this, js-ipfs tutorials may be out of date, and will eventually be archived.
16:This how-to demonstrates a minimal chat app in js-ipfs entirely in the browser.
43:Besides IPFS (with CIDv1) and JavaScript, our chat app uses these technologies
45:- [Libp2p](https
90:We use [WebRTC-Star](https
98:javascript 132:javascript
144:javascript 153:javascript
219:javascript 239:Using p2p-circuit can be a bit tricky. Once you connect to the relay from a browser, you're still not advertising that you're able to be reached through it! For this purpose, this how-to includes a Python script that runs alongside Kubo and advertises the browser js-ipfs peers it encounters over [PubSub](https 345:With PubSub, you can subscribe to topics and retrieve any messages posted to those topics. In js-ipfs, you can set a callback function, which gets called whenever a message is received 347:javascript
372:javascript 379:javascript
395:```javascript
455:- [js-ipfs/docs/BROWSERS.md](https
456:- [js-ipfs/docs/CONFIG.md](https
457:- [js-ipfs/docs/core-api](https
458:- [js-ipfs/examples/circuit-relaying](https

./how-to/use-existing-private-key.md

35:### JS-IPFS
55:### JavaScript
57:Using pre-generated private keys with JavaScript is straight-forward
60:2. Create the node, passing the desired private key in the [correct format](https
62:```javascript
77:- If you already have an initialized repo (i.e., ~/.jsipfs is not empty), the existing key from the config file (`~/.jsipfs/config`) will be used instead of the provided one ([ipfs/js-ipfs#2261](https

./how-to/configure-node.md

8:IPFS is configured through a json formatted text file, located by default at ~/.ipfs/config. Implementation-specific information can be found within the [Kubo](https

./how-to/websites-on-ipfs/single-page-website.md

259:You may have noticed that when visiting [randomplanetfacts.xyz](http

./how-to/README.md

18:- See how to work with peers using methods like [customizing libp2p bundles](https
21:- Understand how IPFS works in the browser by learning how to address IPFS on the Web, seeing how to [exchange files between nodes](https

./how-to/mint-nfts-with-ipfs.md

47:Since Minty was written to demonstrate the concepts and process of minting IPFS-backed NFTs, we don't need to get caught up in all the details of modern d-app development. Instead, Minty is a simple command-line app written in Javascript.
307:Let's look at how Minty's JavaScript code interacts with the smart contract's mintToken function. This happens in the mintToken method of the Minty class
309:javascript 337:As you can see, calling the smart contract function is mostly like calling a normal JavaScript function, thanks to the [ethers.js smart contract library](https 359:javascript
412:javascript 481:javascript
498:```javascript
538:Work is also underway to [support the remote pinning service API][js-ipfs-remote-pin-pr] in js-ipfs, so soon you'll be able to run the entire process in the user's browser using an embedded IPFS node.
540:If you're building a d-app without a backend server today and just can't wait, you could also use an HTTP API provided by a pinning service to send and pin content using traditional HTTP requests instead of embedding js-ipfs into your d-app. See [Pinata's documentation][pinata-docs] for an example. This makes your d-app code a little less generic since it's tied to one provider's API, but it may be a good way to get started. Doing everything in the browser also means you'll need to carefully manage the API tokens for the pinning services you support, perhaps by allowing users to add their own credentials and storing the tokens in the browser's local storage.
550:[js-ipfs-remote-pin-pr]

./how-to/exchange-files-between-nodes.md

10:As [email protected] currently doesn't support DHT peer discovery, the peer from which you are fetching data should be within reach (local or in public IP) of the browser node. That being said, we explain how to circumvent these caveats in this tutorial, and once they are fixed, we'll update everything here.
49:Before we get stared, you'll need to download the JS-IPFS project repo, install the dependencies, and build the project.
54: git clone https
57:2. Move into the js-ipfs folder and install the dependencies
60: cd js-ipfs
74:**Note
126:Make sure you're in js-ipfs/examples/exchange-files-in-browser.

./how-to/browser-tools-frameworks.md

12:[Example and boilerplate](https
16:[Example and boilerplate application](https
20:[Minimal demonstration](https
24:[Example and boilerplate](https
28:[Minimal example](https
32:[Minimal example](https

./how-to/publish-ipns.md

3:description
11:- Publishing IPNS names programmatically with JS-IPFS
106:## Publishing IPNS names programmatically with JS-IPFS
108:With [ipfs-core](https
110:```javascript
126:By default, ipfs.name.publish will use the Peer ID and set the lifetime to 24 hours. To learn more about the full API, check out the [API docs](https
129:Note that when using `ipfs-core`, you're instantiating a full IPFS node. For your IPNS record to propagate through the network, it needs to be connected to other peers. If you're running `ipfs-core` in the browser, you may want to connect it to a long-running IPFS node to ensure it successfully propagates due to [browser connectivity limitations.](https

./case-studies/fleek.md

53:- **Space Daemon
85:At the core of all of Fleek's offerings are [kubo](https
115:- The Space Daemon JavaScript library acts as an abstraction layer to the [gRPC](https

./case-studies/arbol.md

103:Data is accessed by custom client libraries currently implemented in JavaScript (using [js-ipfs](https

./case-studies/audius.md

71:- Multiple implementations (JavaScript, Go, Python HTTP API)
97:All files and metadata on Audius are shared using IPFS by creator node services, registered on Audius smart contracts, indexed by discovery services, and served through the client to end users. Audius runs nodes internally to test new changes, and there are a dozen public hosts running nodes for specific services and geographies. However, content creators and listeners don’t need to know anything about the back end; they use the Audius client and client libraries to upload and stream audio. Each IPFS node within the Audius network is currently a [kubo](https
109:- [ipfs-http-client](https

./case-studies/morpheus.md

55:The decision to use IPFS was an easy one for the Morpheus.Network team. Not only was their integration of out-of-the-box [kubo](https
86:- [ipfs-http-client](https

./project/history.md

51:In the summer of 2015, the small but growing IPFS team (about five or six full-time contributors) settled into a coworking space in Seattle. They hammered out improvements to the Go and JavaScript implementations of IPFS as interest in the project grew. Satoshi Nakamoto's 2009 [Bitcoin whitepaper](https

./project/repository-guide.md

22:### js-ipfs being discontinued
23:Development of the [js-ipfs project](https
25:Because of this, js-ipfs tutorials may be out of date, and will eventually be archived.
30:- [js-ipfs](https
40:| Subsystem | Go | JavaScript | Rust |

./concepts/ipfs-implementations.md

24:| Elastic provider | <https
26:| helia | <https
52:| Agregore | <https
56:| js-ipfs | <https

./concepts/bitswap.md

8: 'GitHub repo
13:Bitswap is a core module of IPFS for exchanging blocks of data. It directs the requesting and sending of blocks to and from other peers in the network. Bitswap is a message-based protocol where all messages contain want-lists or blocks. Bitswap has a [Go implementation](https
30:```javascript

./concepts/glossary.md

69:A Bootstrap Node is a trusted peer on the IPFS network through which an IPFS node learns about other peers on the network. Both Kubo and js-ipfs use bootstrap nodes to enter the Distributed Hash Table (DHT). See Bootstrap
165:Kubo nodes with a subset of RPC API commands exposed. JS-IPFS nodes use them to query the DHT and also publish content without having to actually run DHT logic on their own. See Delegate routing
251:### JS-IPFS
253:An implementation of IPFS written entirely in JavaScript. It runs in a Browser, a Service Worker, Electron and Node.js. See Nodes > JS-IPFS
257:JavaScript Object Notation (JSON) is a lightweight data-interchange format. JSON is a text format that is completely language independent, human-readable, and easy to parse and generate. [More about JSON](https

./concepts/nodes.md

17: * instance
40:- Used by JS-IPFS nodes running in browser contexts.
41:- JS-ipfs nodes remain connected to the libp2p swarm ports of all preload nodes by having preload nodes on the bootstrap list.
43:- Preload nodes are in the default JS-IPFS configuration as bootstrap nodes, so they will maintain libp2p swarm connections to them at all times.
50:- Only works with dag-pb CIDs because that's all the refs command understands. It's harder to find non-dag-pb content, e.g., you need a connection to the publishing js-ipfs instance or it needs to be put on the DHT by a delegate node.
59:- Can be either Kubo or JS-IPFS nodes; however there are standalone implementations as well
62:- They're used by both Kubo and JS-IPFS nodes.
63: - JS-IPFS nodes can also use relay nodes to overcome the lack of transport compatibility within the JS-IPFS implementation. A browser node with WebSockets/webRTC transports can talk with a Kubo node that only communicates through TCP using a relay that supports both transports. This is not enabled by default and needs to be set up.
74:Both Kubo and JS-IPFS nodes use bootstrap nodes to initially enter the DHT.
79:- The list of bootstrap nodes a JS-IPFS node connects to is configurable in their config files.
94:- Usable by both Kubo and JS-IPFS nodes.
95:- JS-IPFS nodes use them to query the DHT and also publish content without having to actually run DHT logic on their own.
97:- Delegate routing nodes are in the default JS-IPFS configuration as bootstrap nodes, so they will maintain libp2p swarm connections to them at all times.
102:- On default delegate nodes provided by Protocol Labs, the garbage collection happens every hour, so provided content only survives for that long. If the uploading JS-IPFS node is still running, it will issue periodic re-provides using the same publishing mechanic, which extends the life of the content on the DHT.
106:Protocol Labs manages two implementations of the IPFS spec
122:### JS-IPFS
125:#### js-ipfs being discontinued
126:Development of the [js-ipfs project](https
128:Because of this, js-ipfs tutorials may be out of date, and will eventually be archived.
132:An implementation of IPFS written entirely in JavaScript. It runs in a browser, a Service Worker, Electron and Node.js. Capabilities depend on the runtime.
134:More at [js.ipfs.io](https
136:#### JS-IPFS node in a browser
146:Specific limitations of the JS-IPFS implementation are
148:- Unless using WSS, a JS-IPFS node cannot connect to the main public DHT. They will only connect to other JS-IPFS nodes.
152:More at [js.ipfs.io](https

./concepts/file-systems.md

222:UnixFS currently has [Javascript](https

./concepts/content-addressing.md

138:JavaScript users can also leverage the toV1() method provided by the [multiformats](https

./concepts/usage-ideas-examples.md

139:[OrbitDB](https
209:The [Domain Name System](https

./concepts/ipns.md

120:The DHT is the default transport mechanism for IPNS records in most IPFS implementations, e.g. Kubo, and js-ipfs.
204:See the following guide on publishing IPNS names with Kubo and js-ipfs.

./community/README.md

63:1. Add any optional tags that help describe what subcategory the issue is in. Samples options include go-ipfs and js-ipfs.

./community/contribute/ways-to-contribute.md

21:- [ipfs/js-ipfs](https

./community/contribute/grammar-formatting-and-style.md

39:When referring to projects by name, use proper noun capitalization
41:Cases inside code blocks refer to commands and are not capitalized
155: ```javascript

./reference/js/api.md

2:title
3:description
6:# IPFS in JavaScript
8:## JavaScript libraries
10:There are three main JavaScript libraries for working with IPFS in JavaScript
12:- ipfs-http-client is the official JavaScript client for talking to a js-ipfs node.
13:- kubo-rpc-client is the official JavaScript client for talking to a Kubo node.
15:### JS-IPFS
18:### js-ipfs being discontinued
19:Development of the [js-ipfs project](https
21:Because of this, js-ipfs tutorials may be out of date, and will eventually be archived.
25:[JS-IPFS](https
31:See the [JS core API reference →](https
39:If you are writing an application that needs to access the IPFS network, use ipfs-core. If you wish to use js-ipfs in a terminal window or run it as a server for use by multiple otherwise unrelated processes, use ipfs.
46: - Use this library to talk to a Kubo node from your JavaScript application
55:The [ipfs-http-client API](https
56: - JS-IPFS will internally use this library if it detects another node is running on your machine. You can also interact with the HTTP version of JS-IPFS RPC API directly using fetch() in a browser or a module like request in Node.js, but using this library can be much more convenient.
57: - When using JS-IPFS as a backend, use the [ipfs-client](https
59:All the libraries have the [same interface](https
63:We recommend the second method (interacting with a separate IPFS node via RPC API) whenever reasonable. Keeping the IPFS node in a separate process (even if it’s one of your program spawns) isolates you from any stability problems with the node. If a user already has IPFS installed, this also means that you can take advantage of a single, standard installation on their machine. It’s also less code to load in a browser. If you need to spawn a separate IPFS process, you might want to take a look at [js-ipfsd-ctl](https
83:* /packages/ipfs-daemon Run js-IPFS as a background daemon
84:* /packages/ipfs-grpc-client A gRPC client for js-IPFS
86:* /packages/ipfs-grpc-server A gRPC-over-websockets server for js-IPFS
87:* /packages/ipfs-http-client A client for the RPC-over-HTTP API presented by js-ipfs
92:* /packages/ipfs-message-port-client A client for the RPC-over-message-port API presented by js-ipfs running in a shared worker
105:| ipfs-unixfs | [![npm](https
107:| ipfs-repo | [![npm](https
108:| ipfs-repo-migrations | [![npm](https
110:| ipfs-bitswap | [![npm](https
114:| ipfs-utils | [![npm](https
115:| ipfs-http-client | [![npm](https
117:| ipfs-http-response | [![npm](https
118:| ipfsd-ctl | [![npm](https
149:**Explore js-ipfs through interactive coding challenges at [ProtoSchool](https
153:There are lots of JS-IPFS use-case examples in the [ipfs/js-ipfs GitHub repository](https
155:A good starting place is the [IPFS 101, spawn a node and add a file to the IPFS network](https

./reference/README.md

34:### JavaScript (js-ipfs)
37:### js-ipfs being discontinued
38:Development of the [js-ipfs project](https
40:Because of this, js-ipfs tutorials may be out of date, and will eventually be archived.
44:API resources for js-ipfs, including the JS core API reference and the JS HTTP client library.

@BigLep
Copy link
Contributor

BigLep commented Jun 6, 2023

@ElPaisano : thanks for the dump.

A few thoughts...

  1. Lets include the commands you used to generate this dump so it can be sanity checked.
  2. We're going to need something more collaborative than a github issue I think for efficiently annotating what we're going to do. Idea:
  • Create a page or section under https://www.notion.so/pl-strflt/2023Q2-js-ipfs-Deprecation-c84d5d4f661044198ba6e63bf0a34790
  • In that page/section create a database.
  • One database entry per file.
  • Each database page can have the content of the lines under question.
  • We can then have fields for "what are we going to do about this page" and/or checkboxes for when you have handled the file
  • Inline on the database entry page we can make comments or notes on whether this should be removed or modified
  • (bonus) have a docs.ipfs.tech website URL so someone can quickly see the content in context as well
  • This should enable fast and collaborative triaging
  1. I am ok to meet today but it would be great if a first pass suggestion of what to do for each section was applied or if you list out certain questions you ant to get answered.
  2. I'd like to include someone else from the Helia working group on this (e.g., @SgtPooki or @whizzzkid ) so the context is shared and I don't become a blocker for reviews or feedback. You can put them down as optional and raise in #ip-js.

Thanks!

@ElPaisano
Copy link
Contributor Author

Got it @BigLep thanks for the suggestions. I'll go ahead and make that first pass. I'll reschedule us for later in the week

@BigLep
Copy link
Contributor

BigLep commented Jun 6, 2023

@ElPaisano : feel free to push back here. I'm not meaning to create a couple of days of extra work here. Another cheap way to do this is to just take your dump above and put it into a document (e.g., page under https://www.notion.so/pl-strflt/2023Q2-js-ipfs-Deprecation-c84d5d4f661044198ba6e63bf0a34790 ) and you just quickly add comments under each file for what we plan to do. That is probably good enough too. The big thing I want is to make sure can be easily annotate our decisions in realtime as we talk about it or concurrently. Issue comments don't allow for that.

@ElPaisano
Copy link
Contributor Author

@BigLep I do think your DB idea is a good one, so I created a page in the Helia notion https://www.notion.so/pl-strflt/ipfs-docs-js-ipfs-cleanup-d46e22253bec4497865c38e7a9277eac. Working through the first pass now

@ElPaisano ElPaisano moved this to 🏗 In Progress in Protocol Docs Jun 13, 2023
@ElPaisano
Copy link
Contributor Author

@ElPaisano ElPaisano linked a pull request Jun 13, 2023 that will close this issue
@github-project-automation github-project-automation bot moved this from 🥞 Todo to 🎉 Done in Helia Working Group (inactive) Jul 14, 2023
@github-project-automation github-project-automation bot moved this from 🏗 In Progress to ✅ Done in Protocol Docs Jul 14, 2023
@BigLep BigLep reopened this Jul 14, 2023
@github-project-automation github-project-automation bot moved this from 🎉 Done to 🥞 Todo in Helia Working Group (inactive) Jul 14, 2023
@github-project-automation github-project-automation bot moved this from ✅ Done to 👾 Up next in Protocol Docs Jul 14, 2023
@BigLep
Copy link
Contributor

BigLep commented Jul 14, 2023

@ElPaisano : I'm reopening because there is some followup to do based on the after-merge of #1620 . Let's also make sure to update the tracking table in https://www.notion.so/pl-strflt/ipfs-docs-js-ipfs-cleanup-d46e22253bec4497865c38e7a9277eac?pvs=4#19ecd8482e904472bc6fed7834def54e with the current status.

@BigLep BigLep moved this from 🥞 Todo to 🏃‍♀️ In Progress in Helia Working Group (inactive) Jul 14, 2023
@BigLep BigLep removed the need/triage Needs initial labeling and prioritization label Jul 14, 2023
@ElPaisano ElPaisano linked a pull request Jul 24, 2023 that will close this issue
@github-project-automation github-project-automation bot moved this from 🏃‍♀️ In Progress to 🎉 Done in Helia Working Group (inactive) Jul 25, 2023
@github-project-automation github-project-automation bot moved this from 👾 Up next to ✅ Done in Protocol Docs Jul 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Development

Successfully merging a pull request may close this issue.

2 participants