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

Align events implementation with FIP-0049 #1376

Closed
3 tasks done
raulk opened this issue Jan 3, 2023 · 1 comment
Closed
3 tasks done

Align events implementation with FIP-0049 #1376

raulk opened this issue Jan 3, 2023 · 1 comment

Comments

@raulk
Copy link
Member

raulk commented Jan 3, 2023

  • Stop flushing events to blockstore when message execution concludes.
  • Ensure that the events field in ApplyRet is populated with the list of events in the correct order.
  • Ensure that the events field is correctly propagated through the FFI boundary. This requires an integration test in Lotus.
  • Redesign the events system in Lotus to consume events from the in-memory list instead of loading them from the blockstore. Write events to the blockstore when Eth API is enabled.
  • Rearchitect gas charges as per FIP-0049.
  • Finish validation logic and validate that values are CBOR Major Type 2 (byte strings).
  • Ethereum: use compact key names as per example in FIP-0049 (and soon FIP-0054 spec).
    • Propagate this change to the Lotus events system.
  • fix: event filters use cbor encoding internally lotus#10085 (comment)

PRs

@raulk
Copy link
Member Author

raulk commented Jan 14, 2023

Finish validation logic and validate that values are CBOR Major Type 2 (byte strings).

We currently deserialize the event object and retain it in memory. Also, the current schema types values as RawBytes. Therefore, both these points are addressed. There is no extra validation logic needed. Ideally we would validate without desrializing, but that's not even beneficial now because to fully benefit from zero-copy, we'd need the AMT implementation to cooperate by taking trusted CBOR bytes, which it doesn't.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants