Skip to content
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

Use uint64 instead of int64 in QGB types #358

Merged

Conversation

rach-id
Copy link
Member

@rach-id rach-id commented Apr 27, 2022

To avoid confusion between data types, this PR changes int64 to uint64 in the right places

@rach-id rach-id self-assigned this Apr 27, 2022
@rach-id rach-id added the C: QGB label Apr 27, 2022
@rach-id rach-id changed the title Use uint64 instead of int64 in QGB Use uint64 instead of int64 in QGB types Apr 27, 2022
@codecov-commenter
Copy link

codecov-commenter commented Apr 27, 2022

Codecov Report

❗ No coverage uploaded for pull request base (qgb-integration@1534631). Click here to learn what that means.
The diff coverage is n/a.

@@                Coverage Diff                 @@
##             qgb-integration     #358   +/-   ##
==================================================
  Coverage                   ?   12.94%           
==================================================
  Files                      ?       55           
  Lines                      ?    10061           
  Branches                   ?        0           
==================================================
  Hits                       ?     1302           
  Misses                     ?     8668           
  Partials                   ?       91           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1534631...ccce361. Read the comment docs.

Copy link
Member

@evan-forbes evan-forbes left a comment

Choose a reason for hiding this comment

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

the thinking around using int64 is that that is what tendermint uses for height, but I'm fine with keeping everything unsigned

@rach-id
Copy link
Member Author

rach-id commented Apr 27, 2022

@evan-forbes we can move everything to be signed to stay consistent with tendermint. Should we ?
This PR aims to have the same type instead of different ones and doing conversions in different places. Either int64 or uint64.

@evan-forbes
Copy link
Member

I could be wrong, but I think its arbitrary for our use case since we will have to convert to an evm friendly encoding of a big.Int any way

@evan-forbes
Copy link
Member

being consistent makes sense tho, so up to you

@rach-id
Copy link
Member Author

rach-id commented Apr 27, 2022

uint64 make more sense for me. I will stick with it for now and in the future, if needed, we can switch again.

@rach-id rach-id merged commit d79b858 into celestiaorg:qgb-integration Apr 27, 2022
@rach-id rach-id deleted the use_uint64_instead_of_int64 branch April 27, 2022 15:25
rach-id added a commit to rach-id/celestia-app that referenced this pull request May 9, 2022
* uses the uint64 instead of int64 in right places

* typo

* cosmetics
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants