Skip to content

Comments

DonTime module hooks#1302

Merged
DylanTinianov merged 84 commits intomainfrom
CAPPL-903-module-time-hook
Jul 11, 2025
Merged

DonTime module hooks#1302
DylanTinianov merged 84 commits intomainfrom
CAPPL-903-module-time-hook

Conversation

@DylanTinianov
Copy link
Contributor

@DylanTinianov DylanTinianov commented Jun 26, 2025

Enabled DON Time module hooks.

  • Creates custom Plugin Provider for delegate initialization.
  • Implements and links clockTimeGet and pollOneoff with wasm calls
  • Adds a timeFetcher for safely retrieving DON or Node time within trap handlers.
  • Also some small plugin updates.

Jira Ticket

Requires

WorkflowLib Plugin

@DylanTinianov DylanTinianov self-assigned this Jun 26, 2025
@DylanTinianov DylanTinianov changed the title Create WorkflowLib Plugin Create DonTime hook Jun 26, 2025
@DylanTinianov DylanTinianov changed the base branch from main to CAPPL-902-don-time-plugin June 26, 2025 17:12
@DylanTinianov DylanTinianov requested a review from nolag July 10, 2025 15:45
@DylanTinianov DylanTinianov enabled auto-merge (squash) July 10, 2025 17:00
case <-t.ctx.Done():
return
}
} else {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

unnecessary else

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually, it may be a bug in the error condition. It will send the error to the channel, but not return.

Copy link
Contributor

@MStreet3 MStreet3 Jul 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should add a continue after sending the error, unless the fetcher should die after an error

Comment on lines +10 to +12
// Provider wraps an existing OCR3 plugin provider (from the relayer)
// and overrides the plugin factory and contract transmitter for DonTime.
type Provider struct {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why?

Copy link
Contributor Author

@DylanTinianov DylanTinianov Jul 10, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's needed for initializing the plugin since we create a custom transmitter.

@DylanTinianov DylanTinianov merged commit 96180e8 into main Jul 11, 2025
14 of 16 checks passed
@DylanTinianov DylanTinianov deleted the CAPPL-903-module-time-hook branch July 11, 2025 00:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants