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

idea: schedule "virtual" event logs #117

Open
fubuloubu opened this issue Sep 20, 2024 · 1 comment
Open

idea: schedule "virtual" event logs #117

fubuloubu opened this issue Sep 20, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@fubuloubu
Copy link
Member

Overview

Allow Silverback apps to dynamically "schedule" events to occur in the future, basically receiving an event log trigger without there being any sort of actual event occuring

Specification

In Ape, we have a way to make a "Mock" Contract Log by using a ContractEvent instance directly via __call__

We could allow a user to add/remove mock events that should trigger at a particular timestamp so we can imitate "scheduling" a trigger to occur in the future, such as w/ ApePay scheduling a Stream cancellation when the stream naturally runs out of funds (which doesn't actually trigger any sort of event)

Care should be taken to ensure that it can be effectlively "unscheduled" to prevent duplicate events occuring (e.g. w/ ApePay if an actual Stream cancellation occurs, remove the mock one)

Dependencies

This might require better support for indexed args in events

@fubuloubu fubuloubu added the enhancement New feature or request label Sep 20, 2024
Copy link

linear bot commented Sep 20, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant