Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Validium pubdata abstraction #75

Conversation

mationorato
Copy link
Collaborator

@mationorato mationorato commented Jan 26, 2024

Closes #69

How to run

Validium Mode

export ZKSYNC_HOME=$(pwd)
export export PATH=$ZKSYNC_HOME/bin:$PATH
zk && zk clean --all && zk init --validium-mode
zk server

cargo run --release --bin validium_mode_example // in another console

Rollup Mode

export ZKSYNC_HOME=$(pwd)
export export PATH=$ZKSYNC_HOME/bin:$PATH
zk && zk clean --all && zk init
zk server

cargo run --release --bin validium_mode_example // in another console

- Needs to fix errors in tests related to the new Generic Data Type
@mationorato mationorato changed the base branch from main to validium_mode_new_fee_model_final January 26, 2024 22:10
@mationorato mationorato marked this pull request as draft January 26, 2024 22:11
@ilitteri ilitteri changed the title Feat validium pubdata abstraction feat: Validium pubdata abstraction Jan 29, 2024
Copy link

@lferrigno lferrigno left a comment

Choose a reason for hiding this comment

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

Left some comments

core/lib/types/src/utils.rs Outdated Show resolved Hide resolved
core/lib/types/src/l1_batch_committer.rs Outdated Show resolved Hide resolved
@ilitteri ilitteri marked this pull request as ready for review January 30, 2024 19:18
@ilitteri ilitteri self-assigned this Jan 30, 2024
…class/zksync-era into feat_validium_pubdata_abstraction
@ilitteri ilitteri removed the request for review from juanbono February 15, 2024 18:36
ilitteri and others added 24 commits February 15, 2024 15:41
…Rollup mode (#120)

* abstract confirm many test

* abstract resend_each_block_Tst

* abstract dont_resend_already_mined test

* abstract three_scenarios_test

* abstract failed_eth_tx test

* add correct_order_for_confirmations and skipped_l1_batch_at_the_start abstraction test

* add skipped_l1_batch_in_the_middle test abstraction

* add test_parse_multicall_data abstraction

* add get_multicall_data abstraction

* fix failing tests

* change base branch

* add return type in test function

* separate tests using test helper

* update test methods to accept l1_commit_data_generator

* pass zk lint --check
## What ❔

- Integrates snapshot recovery logic into EN.
- Tests recovering an EN from a snapshot in integration tests.

## Why ❔

This is the final step to implement snapshot recovery (still needs to be
thoroughly tested, of course).

## Checklist

- [x] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [x] Tests for the changes have been added / updated.
- [x] Documentation comments have been added / updated.
- [x] Code has been formatted via `zk fmt` and `zk lint`.
- [x] Spellcheck has been run via `zk spellcheck`.
- [x] Linkcheck has been run via `zk linkcheck`.

---------

Signed-off-by: tomg10 <[email protected]>
Co-authored-by: Alex Ostrovski <[email protected]>
🤖 I have created a release *beep* *boop*
---


##
[20.7.0](matter-labs/zksync-era@core-v20.6.0...core-v20.7.0)
(2024-02-16)


### Features

* Add input field to CallRequest
([matter-labs#1069](matter-labs#1069))
([5087121](matter-labs@5087121))
* **api:** Remove unused and obsolete token info
([matter-labs#1071](matter-labs#1071))
([e920897](matter-labs@e920897))
* Better errors for JsonRPC calls
([matter-labs#1002](matter-labs#1002))
([079f999](matter-labs@079f999))
* **commitment:** Commitment component
([matter-labs#1024](matter-labs#1024))
([60305ba](matter-labs@60305ba))
* **en:** Make snapshots applier resilient and process storage log
chunks in parallel
([matter-labs#1036](matter-labs#1036))
([805218c](matter-labs@805218c))
* **node_framework:** Resources and layers for ETH clients
([matter-labs#1074](matter-labs#1074))
([776337a](matter-labs@776337a))
* **node_framework:** Support StateKeeper in the framework
([matter-labs#1043](matter-labs#1043))
([a80fff2](matter-labs@a80fff2))


### Bug Fixes

* **api:** Return on duplicate earlier
([matter-labs#1059](matter-labs#1059))
([cfa5701](matter-labs@cfa5701))
* **contract-verifier:** Use optimizer mode in solidity-single-file
verification
([matter-labs#1079](matter-labs#1079))
([fdab638](matter-labs@fdab638))
* Token distribution
([matter-labs#1051](matter-labs#1051))
([bd63b3a](matter-labs@bd63b3a))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
…s#1101)

## What ❔

* Merging 3 different key generation steps into a single binary
* Added 'clap' support with arguments to select what keys should be
created.
* Also started printing out the md5sum of the generated setup keys, for
easier debugging.

## Why ❔

* Having it in one binary is cleaner, and will allow new things (like
checking the validity of all the keys) in the next steps.
* There will be a separate PR to update our nighly/manual workflows.
## What ❔

- add GasForBatchTip criterion instead of checking gas in batch executor
- removes the assumption that a single tx can't consume whole batch gas
(with or without batch tip)

## Why ❔

That check in batch executor
```
if !vm.has_enough_gas_for_batch_tip() {
    return TxExecutionResult::BootloaderOutOfGasForBlockTip;
}
```
conceptually was a criterion and should be extracted to a separate seal
criteria. This way EN doesn't perform this check which is a correct
behavior and code is cleaner.


## Checklist

<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->

- [x] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [x] Tests for the changes have been added / updated.
- [x] Documentation comments have been added / updated.
- [x] Code has been formatted via `zk fmt` and `zk lint`.
- [x] Spellcheck has been run via `zk spellcheck`.
- [x] Linkcheck has been run via `zk linkcheck`.
## What ❔

Adds health checks with intelligent details for most of components run
by the external node.

## Why ❔

These health checks would allow monitoring what's going on with an EN
easier both for humans and machines. The latter could be used in
integration tests etc.

## Checklist

- [x] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [x] Tests for the changes have been added / updated.
- [x] Documentation comments have been added / updated.
- [x] Code has been formatted via `zk fmt` and `zk lint`.
- [x] Spellcheck has been run via `zk spellcheck`.
- [x] Linkcheck has been run via `zk linkcheck`.
… Validium mode and Rollup mode (#142)

* add validium env test

* abstract from_env method
…dium mode and Rollup mode (#143)

* Adapt state keeper test for validium configuration

* Rename variables

* Fix format

* Optimize code

* Format

* Abstract the repeated logic

* Abstract the repeated logic correctly

* Remove unnecessary reference
…1054)

## What ❔

Created 3 unit tests for the `ResourceCollection` component. This PR is
second in the range. After, it's expected to add unit test coverage for
other components in the `node_framework`.

## Checklist

<!-- Check your PR fulfills the following items. -->
<!-- For draft PRs check the boxes as you complete them. -->

- [x] PR title corresponds to the body of PR (we generate changelog
entries from PRs).
- [x] Tests for the changes have been added / updated.
- [ ] Documentation comments have been added / updated.
- [x] Code has been formatted via `zk fmt` and `zk lint`.
- [x] Spellcheck has been run via `zk spellcheck`.
- [x] Linkcheck has been run via `zk linkcheck`.
… prover keys (matter-labs#1132)

## What ❔

* Adding keystore object as one interface to handle reading and writing
of the verification and setup keys
* As a side effect, also removing dependency on the old test_harness
version from key generator

## Why ❔

* This will allow us to specify different (non default) directories for
verification and setup keys in the future.
…oesn't pollute L1BatchPublishCriterion interface (#151)
…r-labs#1113)

## What ❔

* Moved setup key generation logic to test harness
* Allow key generator to pass the different directories when generating
keys.
* Moved the setup key generation for CPU and GPU under a common trait.

## Why ❔

* Setup key generation logic should live in test harness (where it is
closer to actual circuit logic)
* Passing different directories when generating keys, allow for more
flexibility and easier tooling integrations.
… feat_validium_pubdata_abstraction"

This reverts commit 95c08a5, reversing
changes made to 7f52a8d.
…Class/zksync-era into feat_validium_pubdata_abstraction
@mationorato
Copy link
Collaborator Author

mationorato commented Jul 1, 2024

Outdated. Replaced by matter-labs#1461

@mationorato mationorato closed this Jul 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Abstraction: Not sending pubdata to L1