Picolab / Picolab/pico-engine

EventEx state machines persist on a pico across uninstalling and reinstalling associated rulesets

Open
#449 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

0 - Backlog bug language fix
Dominant language
TypeScript
Stars
51
Forks
10
Avg merge
4m
Merged PRs (30d)
1

Description

Given this example rule

  rule testEventExStateMachine {
    select when test pre_reinstall before
                test post_reinstall
    send_directive("Rule was selected and run");
  }

If the pico is sent test:pre_reinstall then the ruleset is uninstalled, then installed again, sending test:post_reinstall will select on the rule.
I even restarted the engine between uninstalling and installing the same ruleset again and the rule still selected on test:post_reinstall when test:pre_reinstall had been triggered.

I am fairly positive this is unwanted behavior as it could cause weird bugs in code between differing installations of the same ruleset on the same pico.

I first encountered this behavior with the group operator count <int>

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing EventEx state-machine state through the ruleset uninstall and reinstall lifecycle, including an engine restart. Reproduce the sequence with test:pre_reinstall and test:post_reinstall, then check the count group operator case. Done means state from the previous installation no longer selects rules after reinstall.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
backend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.