Skip to content
This repository has been archived by the owner on Mar 10, 2020. It is now read-only.

Make ls links' depth dynamic. #693

Merged
merged 2 commits into from
Feb 20, 2018

Conversation

JonKrone
Copy link
Contributor

@JonKrone JonKrone commented Feb 16, 2018

To be able to prettily print ipfs ls -r, we need to know the depth of each file from the ls command.

It was previously hardcoded a 1, though I don't know why. I'm passing the depth along from a change I made in js-ipfs here.

The b58 hash test for ls should fail in CI because the above change to js-ipfs is required to receive the links' depth. Unfortunately this is a cyclical dependency. I can fix it by breaking out the change to js-ipfs or we can merge and fix if something comes up. lemme know

ref: ipfs/js-ipfs#1222

Copy link
Contributor

@daviddias daviddias left a comment

Choose a reason for hiding this comment

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

@JonKrone
Copy link
Contributor Author

The b58 hash test for ls should fail in CI because the above change to js-ipfs is required to receive the links' depth. Unfortunately this is a cyclical dependency. I can fix it by breaking out the change to js-ipfs or we can merge and fix if something comes up. lemme know

Preferred approach?

@daviddias
Copy link
Contributor

js-ipfs is required to receive the links' depth.

@JonKrone js-ipfs-api is tested against go-ipfs, not js-ipfs. No change in js-ipfs should be required.

@JonKrone
Copy link
Contributor Author

JonKrone commented Feb 19, 2018

@diasdavid Thanks! I did something that made these tests pass at one point but I must've mislead myself. Lots to these projects. Anyhow, just made a change, let me know if it's not the right way to go.

When a feature of js-ipfs diverges from go-ipfs and requires a change in a dependency that uses both go-ipfs and js-ipfs, how do we handle that? I know we want to maintain as much similarity as possible but are the interfaces a core that we can extend or do we want to strictly maintain them? Should we update any interfaces for this change?

@JonKrone
Copy link
Contributor Author

Tests failed this time due to an OOM, heap out of memory: https://travis-ci.org/ipfs/js-ipfs-api/jobs/343565256#L3547

@daviddias
Copy link
Contributor

Thanks @JonKrone!

Tests failed this time due to an OOM, heap out of memory

Just the browser ones and on CI given #683. Still figuring that one out.

@daviddias daviddias merged commit cfe95f6 into ipfs-inactive:master Feb 20, 2018
@ghost ghost removed the in progress label Feb 20, 2018
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.

2 participants