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

adder: add support for specifying the hash function #3919

Merged
merged 2 commits into from May 14, 2017

Conversation

Projects
None yet
2 participants
@kevina
Copy link
Contributor

kevina commented May 12, 2017

Closes #3917

License: MIT
Signed-off-by: Kevin Atkinson k@kevina.org

@kevina kevina added the in progress label May 12, 2017

@kevina

This comment has been minimized.

Copy link
Contributor

kevina commented May 12, 2017

@whyrusleeping this p.r. will unconditionally set the Cid version to 1 if the --hash option is used, even if the value is sha2-256.

@kevina kevina force-pushed the kevina/add-hash-fun branch from 239f0ad to 2c8120c May 12, 2017

@whyrusleeping

This comment has been minimized.

Copy link
Member

whyrusleeping commented May 13, 2017

Great! I would just like to see a test that adds some directory stuff recursively too

@kevina

This comment has been minimized.

Copy link
Contributor

kevina commented May 13, 2017

I'm working on it. Raw leaves are a bit of a problem. They need proper support for being used with a hash function other then the default sha2-256.

@kevina kevina force-pushed the kevina/add-hash-fun branch 2 times, most recently from cdc1c83 to 322a1f5 May 13, 2017

@kevina

This comment has been minimized.

Copy link
Contributor

kevina commented May 13, 2017

@whyrusleeping okay this should be good to go, the first commit "Rename NewBlock to NewBlockV0" is not necessary, I did it as a debugging aid and it might be useful to keep. If not it can be cleanly dropped.

@kevina kevina requested a review from whyrusleeping May 13, 2017

@kevina kevina force-pushed the kevina/add-hash-fun branch from 322a1f5 to 49e313e May 13, 2017

@whyrusleeping
Copy link
Member

whyrusleeping left a comment

Great! This look good to me 👍 I would like the NewBlockV0 change reverted though, its just a bit too much noise in the PR for my tastes right now

@whyrusleeping

This comment has been minimized.

Copy link
Member

whyrusleeping commented May 14, 2017

Then theres a code climate issue, documenting the NewNodeWithPrefix would be very helpful

kevina added some commits May 13, 2017

Add support for using an alternative hash function with raw nodes.
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>
adder: add support for specifying the hash function
License: MIT
Signed-off-by: Kevin Atkinson <k@kevina.org>

@kevina kevina force-pushed the kevina/add-hash-fun branch from 49e313e to 4bbd001 May 14, 2017

@kevina

This comment has been minimized.

Copy link
Contributor

kevina commented May 14, 2017

@whyrusleeping both issues should be addressed now

@whyrusleeping
Copy link
Member

whyrusleeping left a comment

LGTM, Thanks @kevina :)

@whyrusleeping whyrusleeping merged commit a4ffefd into master May 14, 2017

8 checks passed

ci/circleci Your tests passed on CircleCI!
Details
codeclimate 1 fixed issue
Details
codecov/patch 70.58% of diff hit (target 35.72%)
Details
codecov/project 62.96% (+27.24%) compared to 864bf47
Details
commit-message-check/gitcop All commit messages are valid
Details
continuous-integration/jenkins/pr-merge This commit looks good
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details

@whyrusleeping whyrusleeping deleted the kevina/add-hash-fun branch May 14, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment