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

chore: renames era_test_node to anvil-zksync #444

Merged
merged 10 commits into from
Dec 4, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# This CODEOWNERS file sets the individuals responsible for code in the era-test-node repository.
# This CODEOWNERS file sets the individuals responsible for code in the anvil-zksync repository.

# These users are the default owners for everything in the repo.
# They will be requested for review when someone opens a pull request.
Expand Down
10 changes: 5 additions & 5 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,18 @@

## Welcome! 👋

Hello there, contributor! We're delighted that you're considering contributing to the `era-test-node` project. This document is here to guide you through the steps and best practices for contributing to this Rust-based repository.
Hello there, contributor! We're delighted that you're considering contributing to the `anvil-zksync` project. This document is here to guide you through the steps and best practices for contributing to this Rust-based repository.

Please take a moment to review this document to ensure a smooth and efficient contribution process for everyone involved.

## Getting Started

- **Fork the repository.** Begin by forking the main `era-test-node` repository to your personal GitHub account.
- **Fork the repository.** Begin by forking the main `anvil-zksync` repository to your personal GitHub account.

- **Clone the repository.** After forking, clone the repository to your local machine:

```bash
git clone https://github.com/<your-github-username>/era-test-node.git
git clone https://github.com/<your-github-username>/anvil-zksync.git
```

- **Create a new branch.** Use descriptive names for your branches to help identify the feature, bugfix, or enhancement you're addressing:
Expand Down Expand Up @@ -42,7 +42,7 @@ git push origin feature/description-of-your-feature

## Submitting a Pull Request

- **Initiate a pull request (PR).** Go to the main `era-test-node` repository. Your recently pushed branch should be highlighted, showing a "Compare & pull request" button. Click on it and provide a clear, detailed description of your changes in the PR.
- **Initiate a pull request (PR).** Go to the main `anvil-zksync` repository. Your recently pushed branch should be highlighted, showing a "Compare & pull request" button. Click on it and provide a clear, detailed description of your changes in the PR.

- **Await a review.** Our maintainers will review your PR. They might request changes or clarifications, so be ready to address any feedback.

Expand All @@ -63,7 +63,7 @@ If you're unsure about something or have questions, don't hesitate to open an is

## What's Next?

Once your PR is approved and merged, your contribution will be integrated into the `era-test-node` repository. Congratulations, and thank you! We value your contribution and look forward to future collaborations.
Once your PR is approved and merged, your contribution will be integrated into the `anvil-zksync` repository. Congratulations, and thank you! We value your contribution and look forward to future collaborations.

Remember, the best contributions come from enjoying the process, being respectful, and continuously learning. Thanks for being a part of our community!

Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ assignees: ''

---

### 🐛 Bug Report for zkSync Era In-Memory Node
### 🐛 Bug Report for anvil-zksync

#### 📝 Description

Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ contact_links:
url: https://github.com/zkSync-Community-Hub/zkync-developers/discussions
about: Please provide feedback, and ask questions here.
- name: In-memory documentation page
url: https://era.zksync.io/docs/tools/testing/era-test-node.html
url: https://era.zksync.io/docs/tools/testing/anvil-zksync.html
about: Please refer to the documentation for immediate answers.
6 changes: 3 additions & 3 deletions .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,13 @@ jobs:
- name: Create artifact
run: |
cd ./target/release
tar -czf era_test_node-${{ matrix.os }}.tar.gz ./era_test_node*
tar -czf anvil-zksync-${{ matrix.os }}.tar.gz ./anvil-zksync*

- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: era_test_node-${{ matrix.os }}.tar.gz
path: ./target/release/era_test_node-${{ matrix.os }}.tar.gz
name: anvil-zksync-${{ matrix.os }}.tar.gz
path: ./target/release/anvil-zksync-${{ matrix.os }}.tar.gz
e2e:
needs: build
uses: ./.github/workflows/e2e.yml
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,14 @@ jobs:
<html lang="en-US">
<head>
<meta charset="UTF-8">
<meta http-equiv="refresh" content="0; url=./era_test_node/index.html">
<meta http-equiv="refresh" content="0; url=./anvil-zksync/index.html">
<script type="text/javascript">
window.location.href = "./era_test_node/index.html"
window.location.href = "./anvil-zksync/index.html"
</script>
<title>Page Redirection</title>
</head>
<body>
If you are not redirected automatically, follow this <a href='./era_test_node/index.html'>link to example</a>.
If you are not redirected automatically, follow this <a href='./anvil-zksync/index.html'>link to example</a>.
</body>
</html>' > ./target/doc/index.html
- name: Generate rustbook
Expand Down
14 changes: 7 additions & 7 deletions .github/workflows/e2e-rust.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Testing era_test_node using e2e (Rust version)
name: Testing anvil-zksync using e2e (Rust version)
on:
workflow_call:

Expand All @@ -18,18 +18,18 @@ jobs:
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: era_test_node-${{ matrix.os }}.tar.gz
name: anvil-zksync-${{ matrix.os }}.tar.gz

- name: Extract era_test_node
- name: Extract anvil-zksync
id: extract_node
run: |
echo "Extracting era_test_node binary"
tar -xzf era_test_node-${{ matrix.os }}.tar.gz
chmod +x era_test_node
echo "Extracting anvil-zksync binary"
tar -xzf anvil-zksync-${{ matrix.os }}.tar.gz
chmod +x anvil-zksync

- name: Launch tests
id: launch
working-directory: ./e2e-tests-rust
run: cargo test
env:
ERA_TEST_NODE_BINARY_PATH: ../era_test_node
ANVIL_ZKSYNC_BINARY_PATH: ../anvil-zksync
18 changes: 9 additions & 9 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Testing era_test_node using e2e
name: Testing anvil-zksync using e2e
on:
workflow_call:

Expand All @@ -24,16 +24,16 @@ jobs:
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: era_test_node-${{ matrix.os }}.tar.gz
name: anvil-zksync-${{ matrix.os }}.tar.gz

- name: Start the era_test_node
- name: Start the anvil-zksync
id: start_node
run: |
echo "Extracting era_test_node binary"
tar -xzf era_test_node-${{ matrix.os }}.tar.gz
chmod +x era_test_node
echo "Extracting anvil-zksync binary"
tar -xzf anvil-zksync-${{ matrix.os }}.tar.gz
chmod +x anvil-zksync
echo "Starting node in background"
./era_test_node 2>&1 | tee era_test_node_output.log &
./anvil-zksync 2>&1 | tee anvil-zksync-output.log &
echo "PID=$!" >> $GITHUB_ENV

- name: Launch tests
Expand All @@ -42,9 +42,9 @@ jobs:
echo "Run tests"
make test-e2e

- name: Stop the era_test_node and print output logs
- name: Stop the anvil-zksync and print output logs
id: stop_node
if: always()
run: |
cat era_test_node_output.log
cat anvil-zksync-output.log
kill $PID
90 changes: 48 additions & 42 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
# This workflow is borrowed from reth, which is borrowed from Lighthouse:
# This workflow is borrowed from reth, which is borrowed from Lighthouse:
# reth: https://github.com/paradigmxyz/reth/blob/500b0fac135fe07635d871d64467326599e2b27e/.github/workflows/release.yml
# lighthouse: https://github.com/sigp/lighthouse/blob/693886b94176faa4cb450f024696cb69cda2fe58/.github/workflows/release.yml

name: release

on:
push:
push:
tags:
- v*

env:
REPO_NAME: ${{ github.repository_owner }}/era-test-node
REPO_NAME: ${{ github.repository_owner }}/anvil-zksync
CARGO_TERM_COLOR: always
RUSTFLAGS: ""

Expand All @@ -29,16 +29,22 @@ jobs:
name: build release
strategy:
matrix:
arch: [x86_64-unknown-linux-gnu, aarch64-unknown-linux-gnu, x86_64-apple-darwin, aarch64-apple-darwin]
arch:
[
x86_64-unknown-linux-gnu,
aarch64-unknown-linux-gnu,
x86_64-apple-darwin,
aarch64-apple-darwin,
]
include:
- arch: x86_64-unknown-linux-gnu
platform: ubuntu-20.04
- arch: aarch64-unknown-linux-gnu
platform: ubuntu-20.04
- arch: x86_64-apple-darwin
platform: macos-latest
- arch: aarch64-apple-darwin
platform: macos-latest
- arch: x86_64-unknown-linux-gnu
platform: ubuntu-20.04
- arch: aarch64-unknown-linux-gnu
platform: ubuntu-20.04
- arch: x86_64-apple-darwin
platform: macos-latest
- arch: aarch64-apple-darwin
platform: macos-latest

runs-on: ${{ matrix.platform }}
needs: [extract-version]
Expand Down Expand Up @@ -66,37 +72,37 @@ jobs:
run: |
cargo install cross --git https://github.com/cross-rs/cross --tag v0.2.4

- name: Build era-test-node for ${{ matrix.arch }}
- name: Build anvil-zksync for ${{ matrix.arch }}
run: |
make build-${{ matrix.arch }}

- name: Rename and move binary
run: |
run: |
mkdir artifacts
mv target/${{ matrix.arch }}/release/era_test_node ./artifacts
mv target/${{ matrix.arch }}/release/anvil-zksync ./artifacts

- name: Create artifacts
run: |
cd artifacts
tar -czf era_test_node-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.arch }}.tar.gz era_test_node*
tar -czf anvil-zksync-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.arch }}.tar.gz anvil-zksync*
mv *tar.gz* ..

# =======================================================================
# Upload artifacts
# This is required to share artifacts between different jobs
# =======================================================================
- name: Upload artifact
uses: actions/upload-artifact@v3
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: era_test_node-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.arch }}.tar.gz
path: era_test_node-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.arch }}.tar.gz
name: anvil-zksync-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.arch }}.tar.gz
path: anvil-zksync-${{ needs.extract-version.outputs.VERSION }}-${{ matrix.arch }}.tar.gz

draft-release:
name: draft release
needs: [build, extract-version]
needs: [build, extract-version]
runs-on: ubuntu-latest
env:
VERSION: ${{ needs.extract-version.outputs.VERSION }}
VERSION: ${{ needs.extract-version.outputs.VERSION }}
permissions:
# Required to post the release
contents: write
Expand All @@ -122,14 +128,14 @@ jobs:
echo "CHANGELOG<<EOF" >> $GITHUB_OUTPUT
echo "$(git log --pretty=format:"- %s" $(git describe --tags --abbrev=0 ${{ env.VERSION }}^)..${{ env.VERSION }})" >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT

- name: Generate list of contributors
id: contributors
run: |
echo "CONTRIBUTORS<<EOF" >> $GITHUB_OUTPUT
echo "$(git log --pretty=format:"- %aN (%aE)" $(git describe --tags --abbrev=0 ${{ env.VERSION }}^)..${{ env.VERSION }} | sort | uniq)" >> $GITHUB_OUTPUT
echo "EOF" >> $GITHUB_OUTPUT

- name: Create release draft
env:
GITHUB_USER: ${{ github.repository_owner }}
Expand All @@ -142,38 +148,38 @@ jobs:
[![YouTube Release Notes](https://img.youtube.com/vi/FZefCZW7JJk/0.jpg)](https://www.youtube.com/watch?v=FZefCZW7JJk)-->

## 📋 Summary

### 🐛 Bug Fixes:
- TBD

### ✨ New Features:
- TBD

### ⚠️ Breaking Changes:
- TBD

## 📜 All Changes

${{ steps.changelog.outputs.CHANGELOG }}

## ⭐ Contributors

${{ steps.contributors.outputs.CONTRIBUTORS }}

## 📥 Binaries

| System | Architecture | Binary |
|:---:|:---:|:---:|
| <img src="https://simpleicons.org/icons/linux.svg" style="width: 32px;"/> | x86_64 | [era-test-node-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/era_test_node-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz) |
| <img src="https://simpleicons.org/icons/linux.svg" style="width: 32px;"/> | aarch64 | [era-test-node-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/era_test_node-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz) |
| <img src="https://simpleicons.org/icons/apple.svg" style="width: 32px;"/> | x86_64 | [era-test-node-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/era_test_node-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz) |
| <img src="https://simpleicons.org/icons/apple.svg" style="width: 32px;"/> | aarch64 | [era-test-node-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/era_test_node-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz) |
| <img src="https://simpleicons.org/icons/linux.svg" style="width: 32px;"/> | x86_64 | [anvil-zksync-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/anvil-zksync-${{ env.VERSION }}-x86_64-unknown-linux-gnu.tar.gz) |
| <img src="https://simpleicons.org/icons/linux.svg" style="width: 32px;"/> | aarch64 | [anvil-zksync-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/anvil-zksync-${{ env.VERSION }}-aarch64-unknown-linux-gnu.tar.gz) |
| <img src="https://simpleicons.org/icons/apple.svg" style="width: 32px;"/> | x86_64 | [anvil-zksync-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/anvil-zksync-${{ env.VERSION }}-x86_64-apple-darwin.tar.gz) |
| <img src="https://simpleicons.org/icons/apple.svg" style="width: 32px;"/> | aarch64 | [anvil-zksync-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz](https://github.com/${{ env.REPO_NAME }}/releases/download/${{ env.VERSION }}/anvil-zksync-${{ env.VERSION }}-aarch64-apple-darwin.tar.gz) |
| | | |
ENDBODY
)
assets=()
for asset in ./era_test_node-*.tar.gz*; do
for asset in ./anvil-zksync-*.tar.gz*; do
assets+=("$asset/$asset")
done
tag_name="${{ env.VERSION }}"
echo "$body" | gh release create "$tag_name" "${assets[@]}" --draft -F "-" -t "Release: $tag_name"
echo "$body" | gh release create "$tag_name" "${assets[@]}" --draft -F "-" -t "Release: $tag_name"
14 changes: 7 additions & 7 deletions .github/workflows/spec.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Testing era_test_node against ETH spec
name: Testing anvil-zksync against ETH spec
on:
workflow_call:

Expand All @@ -14,14 +14,14 @@ jobs:
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: era_test_node-ubuntu-latest.tar.gz
name: anvil-zksync-ubuntu-latest.tar.gz

- name: Extract era_test_node
- name: Extract anvil-zksync
id: extract_node
run: |
echo "Extracting era_test_node binary"
tar -xzf era_test_node-ubuntu-latest.tar.gz
chmod +x era_test_node
echo "Extracting anvil-zksync binary"
tar -xzf anvil-zksync-ubuntu-latest.tar.gz
chmod +x anvil-zksync

- name: Build ETH spec
id: build_eth_spec
Expand All @@ -33,4 +33,4 @@ jobs:
working-directory: ./spec-tests
run: cargo test
env:
ERA_TEST_NODE_BINARY_PATH: ../era_test_node
ANVIL_ZKSYNC_BINARY_PATH: ../anvil-zksync
Loading
Loading