Commit Graph

493 Commits

Author SHA1 Message Date
renovate[bot]
2541c1651c
chore(deps): update rust crate built to 0.5.2 (#399)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-26 21:46:51 +07:00
renovate[bot]
9cf326f1dd
chore(deps): update rust crate serde to 1.0.151 (#398)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-26 21:45:08 +07:00
Ivan Boldyrev
03e63810f4
fix(interpreter-cid): fix Cargo.toml keyword list (#412)
It was too long, and the crate was rejected by the crates.io.
2022-12-26 20:58:04 +07:00
renovate[bot]
3c24658919
chore(deps): update rust crate marine-runtime to 0.24.0 (#397)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-26 19:42:10 +07:00
Ivan Boldyrev
4ffad8d6b5
Fix interpreter-cid compilation (#411)
The serde crate was missing "derive" feature.
2022-12-26 19:35:49 +07:00
Ivan Boldyrev
0226c062f8
feat!(execution-engine): Store call executed values as CIDs in the data (#401)
The trace stores CID strings for call result values.  These strings are to be resolved to real values with `InterpreterData::cid_store` map.
2022-12-26 15:45:14 +07:00
Ivan Boldyrev
004ce10abd
Make unstable clippy happy with clippy --fix (#402)
Most of changes either move variables into `format!` templates
or remove excessive clones.
2022-12-12 22:37:05 +07:00
Ivan Boldyrev
e5837e9171
feat(testing-framework): tetraplet behavior (#396)
`behavior=tetraplet` annotation crates a service that returns call's tetraplets
2022-12-01 17:33:59 +07:00
Mike Voronov
9fe7afb897
feat(all): reduce stream usage scope (#298)
This PR intended to reduce stream usage scope in order to make AquaVM truly deterministic.

Refs: #297.

Co-authored-by: Ivan Boldyrev <ivan@fluence.one>
Co-authored-by: Anatoly Laskaris <github_me@nahsi.dev>
2022-11-30 17:38:32 +03:00
renovate[bot]
30967626e3
chore(deps): update dependency typescript to v4.9.3 (#389)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-29 23:23:20 +03:00
renovate[bot]
7aba7024e5
chore(deps): update rust crate clap to 4.0.29 (#388)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-29 23:22:42 +03:00
Anatolios Laskaris
2d72ab9ff7
ci: Set commit prefix to chore (#395) 2022-11-29 10:12:34 +02:00
renovate[bot]
8318aca3c1
chore(deps): update actions/setup-node action to v3 (#394)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-28 09:45:04 +02:00
renovate[bot]
d238c91a06
chore(deps): update jetli/wasm-pack-action action to v0.4.0 (#391)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-28 09:44:45 +02:00
renovate[bot]
9fa5206435
chore(deps): update peaceiris/actions-gh-pages action to v3.9.0 (#392)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-28 09:44:26 +02:00
renovate[bot]
a71d04a7ec
chore(deps): update actions/checkout action to v3 (#393)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-28 09:44:11 +02:00
Ivan Boldyrev
843d2a1d7b
feat(testing-framework): testing parser improvements (#375)
* Introduce multiline call annotations

Call annotations have same format as `;`-annotations, but can allow
multiline JSON literals.  They look like `#| ...  |#` (that's Common Lisp syntax for multiline comments).

For example:

```
(call "peer_id" ("serv" "func") [a b] var)  #|
      map = {
        "0": null,
        "default": 42,
      }
   |#
```

* A JSON in the assertion parser doesn't have be last

We have been using nom's `rest` for JSON values.  Now we have a simple JSON parser
that recognizes JSON to be parsed with `serde_json`, and may have multiple JSON objects
within same assertion.

* Allow annotation after a compound form

It is attached to a rightmost nested element that has to be a `call` special form.
2022-11-25 17:56:23 +07:00
Ivan Boldyrev
becdedc364
feat!(avm-server): Per-call current_peer_id (#381)
The current peer ID is passed as a new field of `TestRunParameters` named
`current_peer_id: String`, instead of creating an AVM with peer ID.

This is a breaking API change of `avm-interface` and `avm-server`.
2022-11-25 14:59:09 +07:00
Ivan Boldyrev
4e86da7eda
feat(testing-framework): Testing framework major refactoring (#372)
1. Network can be shared between several execution, being used by an Rc-handle.
2. The neighborhood is just network's all peers with removed/inserted hosts delta with respect to network.
3. An AIR script is transformed into a separate value of type `TransformedAirScript`.  It allows running several
particles on the same parsed AIR script, sharing state.
4. `TestExecutor` was renamed to `AirScriptExecutor`.  It also has a constructor that accepts a `TransformedAirScript`.
2022-11-24 23:33:55 +07:00
Anatolios Laskaris
7ac0ab109c
ci: Renovate tuning (#385)
* Manage github-actions

* Update renovate config

* Silent automerge

* Do not manage wasmer

* Update
2022-11-24 12:06:22 +02:00
renovate[bot]
d3bda16e71
fix(deps): update all non-major rust dependencies (#369)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-24 12:54:40 +03:00
Ivan Boldyrev
fb344084a7
Make new clippy happy (#384) 2022-11-23 21:02:28 +07:00
Anatolios Laskaris
78675f930e
ci: fix typo (#383) 2022-11-23 13:13:17 +02:00
Anatolios Laskaris
f5de602108
ci: Update e2e (#382)
* Update

* Fix

* Fix

* Typo

* Cleanup

* Run on merge to master

* Fix branch name
2022-11-22 16:58:30 +02:00
Anatolios Laskaris
c33d46619d
ci: Update e2e (#378) 2022-11-16 14:49:51 +02:00
Anatolios Laskaris
9896306573
chore: Fix needless-borrow warning(#379) 2022-11-16 14:12:31 +02:00
Ivan Boldyrev
9c88567e59
More convenient error messages (#374)
Data is printed last as it is very long and made it difficult to find
the original error message.
2022-11-01 15:06:56 +07:00
Anatolios Laskaris
76a1e6d4e6
Publish air-beautify-wasm only on when something changed (#371) 2022-10-26 17:23:47 +07:00
shamsartem
7554c01ce0
update links (#370) 2022-10-26 12:49:31 +03:00
Ivan Boldyrev
ea934ab9a9
air-beautify-wasm in the tree (#336)
1. Update wasm-bindgen in the wasm-air-beautify to make it buildable with rest of tree.
2. Rename `wasm-air-beautify` to `air-beautify-wasm`, to make it consistent
   with other packages.
3. Implement github workflows to build and deploy the `air-beautify-wasm` package.
2022-10-25 14:54:51 +07:00
Anatolios Laskaris
22d39f5b23
ci: Set avm client version to crate version (#368)
* Set version from Cargo.toml

* Fix crate link on release
2022-10-25 10:20:42 +03:00
renovate[bot]
bbc521ce53
fix(deps): update all non-major rust dependencies (#338)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-15 21:08:46 +03:00
renovate[bot]
fb32f33154
chore(deps): update rust crate pretty_assertions to v1 (#361)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-14 12:40:12 +03:00
Mike Voronov
8c3f9a3090
feat(interpreter-data): add interpreter version in data (#367) 2022-10-13 12:50:32 +03:00
Ivan Boldyrev
22fac9329e
feat(testing-framework): prevalidate AIR script (#365)
Try to parse the annotated AIR script with the standard parser to catch
to catch errors early with better error messages.

We do it in the `TestExecutor` only to make testing framwork parser
tests simplier.  For user experience, it doesn't matter.
2022-10-12 13:44:59 +07:00
Mike Voronov
a60b61e1a1
fix(execution-engine): save order between current generations (#366)
Co-authored-by: Valery Antopol <valery.antopol@gmail.com>
2022-10-12 04:29:31 +03:00
Ivan Boldyrev
651b569a13
feat(testing-framework): allow exclamation mark (#364)
While exclamation mark is legacy feature in the lambda parser, people
seem to use it anyway, getting errors not always easy to understand.
2022-10-11 21:52:49 +07:00
Mike Voronov
bf8aee7f15
fix(execution-engine): fix invalid iteration over stream (#362)
This PR is mostly a revertion of #357, that is needed to make stream work correctly in fold itrerations.

Closes #363.
2022-10-11 01:41:22 +03:00
Mike Voronov
eafdec5d86
fix(aquavm): temporary fix entire value in canon (#358) 2022-10-10 22:15:28 +03:00
Ivan Boldyrev
076045124c
feat(testing) Testing framework chapter 1, asserts and comments (#342)
* seq_result` -> `seq_ok`; add `seq_err`

`seq_ok` and `seq_err` are consistent with `ok` and `err`, but produce
results sequentially.

* Accept `;;` and longer comments in the sexp parser

Currently they are just dropped, and resulting AIR has different
character positions in the error messages.

* Add "map" assertion

Lookup result in a map by service's first argument.
2022-10-11 01:05:20 +07:00
Anatolios Laskaris
17a6409566
ci: Add registry to e2e (#359) 2022-10-10 18:48:13 +04:00
Mike Voronov
01bbca72c2
fix(air-parser): allow non used streams in validator (#360)
Validator checks that stream used in `canon` is populated by a value in a supplied script. This PR removes this check, because it's useful for code generation.
2022-10-10 15:51:03 +03:00
Mike Voronov
910f1665eb
fix(trace-handler): fix fold and canon compatibility (#357)
Fixes bug of traces divergence when `canon` is used inside `fold`.

Closes #356.
2022-10-09 12:56:12 +03:00
Mike Voronov
cd598c28ae
refactor(aquavm): improve readability of ap merger and handler (#354)
At the moment `Ap` state contains vector of generations, although the ap instruction itself allow to specify only one stream. It was done to support several streams in a result position in a future. But the current realization allows to handle empty vector that was implemented to support states for scalars and it turned out (for more info see #326) that states for scalars aren't actually needed.

Closes #355.
2022-10-07 14:38:29 +03:00
Mike Voronov
a8b227caf5
refactor(aquavm): getting rid of CallOutputValue in call merger (#353)
This PR refactors call merger of `TraceHandler`. Previously it requires `CallOutputValue` to determine a type of call output value (stream or scalar). And internally it checked correspondence between data result and call output type and return a error if they are not equal. Although execution engine component also had a match over these values and does nothing if they are not matched since `TraceHandler` did this job. This PR eliminate such behaviour and improve isolation of AquaVM modules.
2022-10-06 19:59:47 +03:00
Mike Voronov
c3aa8efa04
chore(tests): rename all *.clj files to *.air (#352) 2022-10-06 15:56:31 +03:00
Mike Voronov
ccbd3262a3
feat(aquavm): allow to set last instruction of fold (#349) 2022-10-01 23:41:30 +03:00
Valery Antopol
dd0c458339
fix: cannon treats ap with different generations as incompatible (#350)
Fixes #348.
2022-09-30 21:43:51 +03:00
Ivan Boldyrev
2e98712cb2
fix(execution-engine) Restricted stream bugfix (#337)
Use proper stream generation structures for call results merged from current data.

Closes #302.

Co-authored-by: vms <michail.vms@gmail.com>
2022-09-30 03:10:24 +07:00
Mike Voronov
8889291af8
fix(execution-engine): treat non-defined stream as empty in canon (#347)
This PR forces `canon` instruction to treat streams as empty, it's crucial for deterministic behaviour.

Closes #346.
2022-09-29 23:05:04 +03:00