fission-codes / fission-cli

Rewrite it in Rust 🦀
Apache License 2.0
1 stars 1 forks source link

Adding ipfs trait #10

Closed BoisterousCoder closed 1 year ago

BoisterousCoder commented 1 year ago

Description

This pull request implement an implantation for ipfs so code can later the call the following features:

Link to issue

closes #7

Testing

There are intregration test that are located in ./ipfs/tests.rs. Just do cargo test to run them and cargo test -- --nocapture if you need to see the console log. These test should hit the entire code. Just note these tests reference the fission production ipfs nodes and a couple of the tests upload files. Also you will need to have ipfs in your PATH as the daemon is launched using the ipfs daemon command.

Type of change

zeeshanlakhani commented 1 year ago

Instead of the HTTP layer here, https://github.com/ferristseng/rust-ipfs-api is probably the way to go.

BoisterousCoder commented 1 year ago

I think its ready for review again but I don't dont think anyone is going to be able to review it until the 3rd

BoisterousCoder commented 1 year ago

@bgins Those sub-directories are there to test that you can upload sub-directories and what's inside of them

bgins commented 1 year ago

@bgins Those sub-directories are there to test that you can upload sub-directories and what's inside of them

Ah ok, I missed that. Makes sense to keep them then. 👌

bgins commented 1 year ago

@BoisterousCoder Thanks for making all the changes, and this is in good shape! However, personally, I'd probably remove the dead code (as we can revisit things from utils at another point) and remove the tests using this code.

Yep, this seems like the right call. It will make the code base cleaner and easier to read.

We may have use for some of the dead code in the future. If we do, we can pull it up when we need it. I'll keep this branch around for future reference.

BoisterousCoder commented 1 year ago

@BoisterousCoder Thanks for making all the changes, and this is in good shape! However, personally, I'd probably remove the dead code (as we can revisit things from utils at another point) and remove the tests using this code.

Okay, dead code removed