Skip to content

refactor(gtest): Change block execution model in gtest to be similar to the vara-runtime#4119

Merged
techraed merged 7 commits into
masterfrom
st-block-exec-gtest
Aug 14, 2024
Merged

refactor(gtest): Change block execution model in gtest to be similar to the vara-runtime#4119
techraed merged 7 commits into
masterfrom
st-block-exec-gtest

Conversation

@techraed
Copy link
Copy Markdown
Contributor

@techraed techraed commented Aug 7, 2024

Release notes:

  1. Sending message to program simply means adding message to the queue, not executing block immediately as it was done previously. So program.send(...) now doesn't trigger block execution.
  2. The block execution model is now similar to vara-runtime block execution. Block execution consists of 2 steps: scheduled tasks processing and message processing.
  3. To start block execution one of the following methods must be called: run_next_block, run_next_block_with_allowance, run_to_block. Scheduled tasks can be processed separately without processing messages by calling run_scheduled_tasks.
  4. Instead of RunResult a new BlockRunResult is introduced, which gives some report data of the block execution.
  5. Sending signals from the Program API is removed as it violates the rules of the runtime: signals are sent only on panic automatically after failed execution, as it's done on the vara runtime (see bcba7c0).

TODO:

  • resolve todos (open corresponding issues)
  • fix workspace tests using gtest

@techraed techraed self-assigned this Aug 7, 2024
@techraed techraed changed the title refactor(gtest): Change block execution model in gtest so it's similar to the vara-runtime refactor(gtest): Change block execution model in gtest to be similar to the vara-runtime Aug 8, 2024
Comment thread gtest/src/system.rs
Comment thread gtest/src/manager.rs
Copy link
Copy Markdown
Contributor

@ByteNacked ByteNacked left a comment

Choose a reason for hiding this comment

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

LGTM 👍

@techraed techraed force-pushed the st-block-exec-gtest branch from aeabdb2 to 1867a54 Compare August 13, 2024 08:09
@techraed techraed merged commit 8e4f55f into master Aug 14, 2024
@techraed techraed deleted the st-block-exec-gtest branch August 14, 2024 08:46
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