Eos: Can i get head block id in smart contract?

Created on 15 Sep 2018  ยท  2Comments  ยท  Source: EOSIO/eos

In eos, there's controller->head_block_id() internally, but can i get it in a smart contract?

enhancement

Most helpful comment

Head block changes constantly. It can not be exposed to contracts, as the results would be nondeterministic.

All 2 comments

Not at this moment. Maybe in the future. However controller->head_block_id() will return the id of previous block, as the current block is not produced yet.

Head block changes constantly. It can not be exposed to contracts, as the results would be nondeterministic.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

williamleecn picture williamleecn  ยท  3Comments

jiazechen picture jiazechen  ยท  3Comments

bezalel picture bezalel  ยท  3Comments

christola picture christola  ยท  3Comments

hadramidah picture hadramidah  ยท  3Comments