question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Strange behaviour without IPFS Companion

See original GitHub issue

When using the app with IPFS Companion everything works great 🌟

But a simple app like this should require the minimum amount of setup, that being said it should work out-of-the-box with just an IPFS daemon running.

Something strange is happening. Steps to reproduce:

  1. Disable the IPFS Companion if it’s active
  2. Fire up an IPFS daemon in the terminal
  3. Start the app and upload a single file – it should upload successfully and generate a share link
  4. Try to upload another file – it uploads but it doesn’t generate another share link as it should (and does with Companion) because the request hangs forever:
http://127.0.0.1:5001/api/v0/object/patch/add-link?arg=QmPvs3XyQqFY8sprbS6A18EqCS1b6A2FwKL8tx4DEjVRUD&arg=package.json&arg=QmdXb9kCfLv4bGHRiiFStC66JSH36Gr2y7j7hW9cnrZqUm&stream-channels=true

The problem should come from this func: https://github.com/ipfs-shipyard/ipfs-share-files/blob/3d8c417ffc0c2ababd771e1277afbecd851e1a55/src/lib/files.js#L47-L56

I can’t understand why it works with Companion & it works the first time the func is called, it generates the share link. But when calling again it hangs. It also happens if you try to upload multiple files the first time, I think there is something wrong when creating the new unixfs-dir and/or adding links to it.

Ideas? @ipfs-shipyard/gui

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
lidelcommented, Sep 3, 2018

AFAIK we can’t fix it from the app itself: website’s JS can’t set Connection nor Expect headers 😦 However, I’ve added a new workaround for go-ipfs issue (https://github.com/ipfs-shipyard/ipfs-companion/pull/562) to IPFS Companion. When merged, it will finally fix issue under Chrome if user has our extension enabled.

See the PR for more details.

0reactions
lidelcommented, Feb 2, 2021

Yup, this is no longer relevant as we deprecated window.ipfs and will use js-ipfs running on the page itself.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ipfs companion doesn't support subpaths for custom API ...
Go to extension settings; Edit IPFS API URL to have a path in it; See error. Expected behavior. I expect the custom path...
Read more >
If a website switches to IPFS, do their visitors have to do ...
If a website switches to IPFS, do their visitors have to do anything different than existing behavior to view website content? Let's say ......
Read more >
Troubleshooting
If you're getting unexpected behavior when trying to run common commands such as ipfs get <cid> returning Error: merkledag: not found , the...
Read more >
Your million-dollar NFT can break tomorrow if you're not ...
Like a painting, NFTs need to be maintained. If a buyer purchases an NFT that relies on IPFS, it'll ultimately be on them...
Read more >
Introducing Cloudflare's IPFS Gateway
Weird thing is, I'm not seeing anyone providing it but I can still ... The extension exists: https://github.com/ipfs-shipyard/ipfs-companion ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found