-
Notifications
You must be signed in to change notification settings - Fork 665
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
Expose epoch manager information #4885
Comments
Could you explain the use case here? Unless there is a strong reason, we usually do not consider adding new host functions. This is also related to #2745 |
My specific use case is that I want to disallow some validators from being able to run my tx, by making the tx fail if the validator is in a blacklist. Thinking about a more generic approach, instead of explicitly giving this info, we can expose the hash of the previous block. This is enough to proof anything that happened previously, in particular I think this is enough (with extra data) to proof who is the current block producer. |
Should we revive the discussion on host function for block hash 😄 |
This issue has been automatically marked as stale because it has not had recent activity in the last 2 months. |
This issue has been automatically marked as stale because it has not had recent activity in the last 2 months. |
Feature request
Create a host function to give access to epoch manager information. In particular I'm thinking about having a function that given a
block_height
returns the expectedblock_producer
for that block. Notice thatblock_height
can be from the future, as long as it is part of the current epoch and this information is already available.Somehow related, is this change: #2504
Additional context
This can be achieved today without any protocol change, but it is inconvenient, by running a NEAR Light Client as a smart contract on top of NEAR (similar to the rainbow-bridge implementation). It is inconvenient because data must be relayed at least once per epoch.
The text was updated successfully, but these errors were encountered: