archethic-foundation / archethic-foundation/archethic-node
Smart Contracts: Condition transaction check even if no trigger
- Dominant language
- Elixir
- Stars
- 82
- Forks
- 24
- PR merge metrics
- No merged PRs in 30d
Description
# Description
The `condition transaction` should be checked even if there are no `actions triggered_by: transaction` block. So a transaction that have a **recipient** with the following contract:
```
@version 1
condition transaction: [
previous_public_key: "0001CBDCFF8AC44F24450F693743FB9C7F819985E861B13C61D98AB9A2C8E881B349",
]
```
can only be validated if it is the direct descendant of `0001CBDCFF8AC4...`
ps: similar to https://github.com/archethic-foundation/archethic-node/issues/789 but is not quite the same thing. I believe the mentionned issue wants a `condition input` to be able to filter the inputs coming in (_without_ recipient).
Contributor guide
Research direction
Start by tracing the smart-contract transaction validation path in the Elixir node and compare the intended behavior with issue #789. Verify the supplied recipient contract: its condition transaction should be checked even when no actions triggered_by: transaction block exists, and validation should allow only a direct descendant of the specified previous public key.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- elixir
- Domain
- blockchain
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100