Zilliqa / zilliqa-js

JavaScript SDK for Zilliqa blockchain
https://www.npmjs.com/package/@zilliqa-js/zilliqa
GNU General Public License v3.0
131 stars 74 forks source link

fix(core): ds block header type #404

Closed ghost closed 3 years ago

ghost commented 3 years ago

Description

This PR fixes GasPrice type in DsBlockHeader (number -> string).

{
  "id": "1",
  "jsonrpc": "2.0",
  "result": {
    "header": {
      "BlockNum": "5898",
      "Difficulty": 91,
      "DifficultyDS": 149,
      "GasPrice": "1000000000",
      "LeaderPubKey": "0x026964CBF00EE542F5CBE80395FFEA747227BC3EFCC21D04956380180A9BE21546",
      "PoWWinners": [
        "0x0219DB403A630022EE014AFD97D02E2DBC6BCEED2506A9E57B5EE5D9EA4F154929",
        "0x02D9C8FC6C87891968ECCEE5EF1CD8A9F8FC32C6463F2FE4E846DFD5C5F45A625E",
        "0x02E07F03C71D26433E7F290416FA43374DA72704F8AA973D4771AA763ACD7C509C",
        "0x02E0FB6CDAEA57738959B493652A74E86339AF2CFE998FB7424BBD7A813450743F",
        "0x0315E9B13D5A5D29902F1EECE0933E96A0AF9939853D5F82B438AAED9F7560B3FC",
        "0x034D9B1B0DC80A0103AE7826886B415C29BF3E814FF6720F6C9C47B57589EFEAAA",
        "0x0394EA64F2F833B88C56464E12B37780BDB9684875F55BC569B397ABE0FCCD8E0E",
        "0x03C53B6C3D901ED46E786DA383BE61A46A442461D2A83379A11A42D7403FB7102E",
        "0x03F6427EE15A5EC409FE7F8CDCC8E7C7704CC07AD2BF8CADFD2A19BB98E80836AF"
      ],
      "PrevHash": "968e2e7820a3795de8c8a7a2e94379cc10f50ada5ea6f90c03c4e61e22ee83b5",
      "Timestamp": "1590641169078644"
    },
    "signature": "803D64288A6F827DAFA529235C7A78E7BC2D1C882C5DA643E03CB0B2A786C7A5508CCD5F409CDAA325709E4E9A98F1D67596E61CB8CF958AD98B7DB842F87A44"
  }
}

References:

Motivation and Context

How has this been tested?

Screenshots (if appropriate):

Types of changes

Checklist:

codecov-commenter commented 3 years ago

Codecov Report

Merging #404 (d75d769) into dev (76b5911) will not change coverage. The diff coverage is n/a.

:exclamation: Current head d75d769 differs from pull request most recent head 192ecb2. Consider uploading reports for the commit 192ecb2 to get more accurate results Impacted file tree graph

@@           Coverage Diff           @@
##              dev     #404   +/-   ##
=======================================
  Coverage   80.89%   80.89%           
=======================================
  Files          43       43           
  Lines        1795     1795           
  Branches      326      326           
=======================================
  Hits         1452     1452           
  Misses        342      342           
  Partials        1        1           
Impacted Files Coverage Δ
packages/zilliqa-js-core/src/types.ts 100.00% <ø> (ø)

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 76b5911...192ecb2. Read the comment docs.