Finschia / finschia-sdk

A framework for building blockchains based Finschia Mainnet that is forked from cosmos-sdk
Apache License 2.0
63 stars 30 forks source link

feat: add `CalculateAllInputsHash` in ZKAuthInputs #1239

Closed zemyblue closed 6 months ago

zemyblue commented 6 months ago

Description

Add CalculateAllInputsHash of ZKAuthInputs in x/zkauth module

Motivation and context

How has this been tested?

Screenshots (if appropriate):

Checklist:

codecov[bot] commented 6 months ago

Codecov Report

Attention: 41 lines in your changes are missing coverage. Please review.

:exclamation: No coverage uploaded for pull request base (feat/zkauth@1132e10). Click here to learn what that means.

Additional details and impacted files [![Impacted file tree graph](https://app.codecov.io/gh/Finschia/finschia-sdk/pull/1239/graphs/tree.svg?width=650&height=150&src=pr&token=m16qfzIPO7&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Finschia)](https://app.codecov.io/gh/Finschia/finschia-sdk/pull/1239?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Finschia) ```diff @@ Coverage Diff @@ ## feat/zkauth #1239 +/- ## ============================================== Coverage ? 69.77% ============================================== Files ? 652 Lines ? 67660 Branches ? 0 ============================================== Hits ? 47208 Misses ? 18253 Partials ? 2199 ``` | [Files](https://app.codecov.io/gh/Finschia/finschia-sdk/pull/1239?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Finschia) | Coverage Δ | | |---|---|---| | [x/zkauth/types/zkauth\_inputs.go](https://app.codecov.io/gh/Finschia/finschia-sdk/pull/1239?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Finschia#diff-eC96a2F1dGgvdHlwZXMvemthdXRoX2lucHV0cy5nbw==) | `66.66% <66.66%> (ø)` | |
Mdaiki0730 commented 6 months ago

The hashed element for poseidon hash is written as Fr, but there are some that are already written as F (e.g. IssF), which can cause confusion. There are many things that already use F, so why not write it as F?

zemyblue commented 6 months ago

The hashed element for poseidon hash is written as Fr, but there are some that are already written as F (e.g. IssF), which can cause confusion. There are many things that already use F, so why not write it as F?

I use gnark style, but it's better to use f. I'll modify it. Thank you.

sonarcloud[bot] commented 6 months ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud