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

feat: add mssing dag put and dag resolve cli commands #2521

Merged
merged 4 commits into from
Oct 19, 2019

Conversation

achingbrain
Copy link
Member

Also allows passing input to ipfs-exec to simulate piping in cli tests.

Also allows passing input to `ipfs-exec` to simulate piping in
cli tests.
preload
})

if (pin) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should push the pinning functionality into core so that it can take a gc lock to avoid being collected between adding and pinning.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or back out of pinning in this PR...

await ipfs.pin.add(cid, {
lock: true
})
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to take the lock around the ipld.put and pin.add like we do in ipfs.add https://github.com/ipfs/js-ipfs/blob/master/src/core/components/files-regular/add-async-iterator.js#L58-L64

Note we'll need to call pin.add with lock: false in the same way we do with add.

@achingbrain achingbrain merged commit 8759bf8 into master Oct 19, 2019
@achingbrain achingbrain deleted the add-missing-dag-cli-commands branch October 19, 2019 14:48
@achingbrain achingbrain mentioned this pull request Oct 23, 2019
52 tasks
alanshaw pushed a commit to ipfs-inactive/interface-js-ipfs-core that referenced this pull request Nov 11, 2019
Was added in ipfs/js-ipfs#2521 but not updated here.
alanshaw pushed a commit to ipfs-inactive/interface-js-ipfs-core that referenced this pull request Nov 18, 2019
Was added in ipfs/js-ipfs#2521 but not updated here.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants