Skip to content

Commit

Permalink
feat: change zkSync occurences to ZKsync (#2227)
Browse files Browse the repository at this point in the history
## What ❔
This PR changes `zkSync` occurences to `ZKsync`

## Why ❔

`ZKsync` is new valid way of writing the name.

## 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).
- [ ] 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`.

---------

Co-authored-by: Fedor Sakharov <fedor.sakharov@gmail.com>
  • Loading branch information
maciekzygmunt and montekki committed Jun 19, 2024
1 parent 3ee34be commit 0b4104d
Show file tree
Hide file tree
Showing 140 changed files with 392 additions and 392 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ We aim to make it as easy as possible to contribute to the mission. This is stil
and suggestions here too. Some resources to help:

1. [In-repo docs aimed at developers](docs)
2. [zkSync Era docs!](https://docs.zksync.io)
2. [ZKsync Era docs!](https://docs.zksync.io)
3. Company links can be found in the [repositories' readme](README.md)

## Code of Conduct
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# zkSync Era: A ZK Rollup For Scaling Ethereum
# ZKsync Era: A ZK Rollup For Scaling Ethereum

[![Logo](eraLogo.png)](https://zksync.io/)

zkSync Era is a layer 2 rollup that uses zero-knowledge proofs to scale Ethereum without compromising on security or
ZKsync Era is a layer 2 rollup that uses zero-knowledge proofs to scale Ethereum without compromising on security or
decentralization. Since it's EVM compatible (Solidity/Vyper), 99% of Ethereum projects can redeploy without refactoring
or re-auditing a single line of code. zkSync Era also uses an LLVM-based compiler that will eventually let developers
or re-auditing a single line of code. ZKsync Era also uses an LLVM-based compiler that will eventually let developers
write smart contracts in C++, Rust and other popular languages.

## Knowledge Index
Expand All @@ -27,7 +27,7 @@ The following questions will be answered by the following resources:

## License

zkSync Era is distributed under the terms of either
ZKsync Era is distributed under the terms of either

- Apache License, Version 2.0, ([LICENSE-APACHE](LICENSE-APACHE) or <http://www.apache.org/licenses/LICENSE-2.0>)
- MIT license ([LICENSE-MIT](LICENSE-MIT) or <https://opensource.org/blog/license/mit/>)
Expand All @@ -47,7 +47,7 @@ at your option.

## Disclaimer

zkSync Era has been through lots of testing and audits. Although it is live, it is still in alpha state and will go
ZKsync Era has been through lots of testing and audits. Although it is live, it is still in alpha state and will go
through more audits and bug bounty programs. We would love to hear our community's thoughts and suggestions about it! It
is important to state that forking it now can potentially lead to missing important security updates, critical features,
and performance improvements.
6 changes: 3 additions & 3 deletions checks-config/era.dic
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ boolean
prover
timestamp
H160
zkSync
ZKsync
AccessList
miniblock
member₁
Expand Down Expand Up @@ -212,7 +212,7 @@ EOAs
zeroized
cardinality

// zkSync-related words
// ZKsync-related words
matterlabs
zkweb
zksync
Expand Down Expand Up @@ -610,7 +610,7 @@ DBs
unexecutable
RLP
DAL
zkSync's
ZKsync's
l2_to_l1
PoW
coinbase
Expand Down
2 changes: 1 addition & 1 deletion core/bin/contract-verifier/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ async fn update_compiler_versions(connection_pool: &ConnectionPool<Core>) {
use zksync_config::configs::DatabaseSecrets;

#[derive(StructOpt)]
#[structopt(name = "zkSync contract code verifier", author = "Matter Labs")]
#[structopt(name = "ZKsync contract code verifier", author = "Matter Labs")]
struct Opt {
/// Number of jobs to process. If None, runs indefinitely.
#[structopt(long)]
Expand Down
2 changes: 1 addition & 1 deletion core/bin/external_node/README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# zkSync External Node
# ZKsync External Node

This application is a read replica that can sync from the main node and serve the state locally.

Expand Down
2 changes: 1 addition & 1 deletion core/bin/external_node/src/config/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -647,7 +647,7 @@ pub(crate) struct RequiredENConfig {
/// L1 chain ID (e.g., 9 for Ethereum mainnet). This ID will be checked against the `eth_client_url` RPC provider on initialization
/// to ensure that there's no mismatch between the expected and actual L1 network.
pub l1_chain_id: L1ChainId,
/// L2 chain ID (e.g., 270 for zkSync Era mainnet). This ID will be checked against the `main_node_url` RPC provider on initialization
/// L2 chain ID (e.g., 270 for ZKsync Era mainnet). This ID will be checked against the `main_node_url` RPC provider on initialization
/// to ensure that there's no mismatch between the expected and actual L2 network.
pub l2_chain_id: L2ChainId,

Expand Down
2 changes: 1 addition & 1 deletion core/bin/external_node/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -692,7 +692,7 @@ async fn shutdown_components(
Ok(())
}

/// External node for zkSync Era.
/// External node for ZKsync Era.
#[derive(Debug, Parser)]
#[command(author = "Matter Labs", version)]
struct Cli {
Expand Down
2 changes: 1 addition & 1 deletion core/bin/zksync_server/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ mod node_builder;
#[global_allocator]
static GLOBAL: tikv_jemallocator::Jemalloc = tikv_jemallocator::Jemalloc;
#[derive(Debug, Parser)]
#[command(author = "Matter Labs", version, about = "zkSync operator node", long_about = None)]
#[command(author = "Matter Labs", version, about = "ZKsync operator node", long_about = None)]
struct Cli {
/// Generate genesis block for the first contract deployment using temporary DB.
#[arg(long)]
Expand Down
12 changes: 6 additions & 6 deletions core/lib/basic_types/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! The declaration of the most primitive types used in zkSync network.
//! The declaration of the most primitive types used in ZKsync network.
//!
//! Most of them are just re-exported from the `web3` crate.

Expand Down Expand Up @@ -86,7 +86,7 @@ impl TryFrom<U256> for AccountTreeId {
}
}

/// ChainId in the zkSync network.
/// ChainId in the ZKsync network.
#[derive(Copy, Clone, Debug, Serialize, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct L2ChainId(u64);

Expand Down Expand Up @@ -183,13 +183,13 @@ impl From<u32> for L2ChainId {
}

basic_type!(
/// zkSync network block sequential index.
/// ZKsync network block sequential index.
L2BlockNumber,
u32
);

basic_type!(
/// zkSync L1 batch sequential index.
/// ZKsync L1 batch sequential index.
L1BatchNumber,
u32
);
Expand All @@ -201,13 +201,13 @@ basic_type!(
);

basic_type!(
/// zkSync account nonce.
/// ZKsync account nonce.
Nonce,
u32
);

basic_type!(
/// Unique identifier of the priority operation in the zkSync network.
/// Unique identifier of the priority operation in the ZKsync network.
PriorityOpId,
u64
);
Expand Down
4 changes: 2 additions & 2 deletions core/lib/basic_types/src/network.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! The network where the zkSync resides.
//! The network where the ZKsync resides.
//!

// Built-in uses
Expand All @@ -12,7 +12,7 @@ use crate::L1ChainId;

// Local uses

/// Network to be used for a zkSync client.
/// Network to be used for a ZKsync client.
#[derive(Debug, Serialize, Deserialize, Clone, Copy, PartialEq, Eq)]
#[serde(rename_all = "camelCase")]
pub enum Network {
Expand Down
10 changes: 5 additions & 5 deletions core/lib/config/src/configs/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ use zksync_basic_types::{
pub struct NetworkConfig {
/// Name of the used Ethereum network, e.g. `localhost` or `rinkeby`.
pub network: Network,
/// Name of current zkSync network
/// Name of current ZKsync network
/// Used for Sentry environment
pub zksync_network: String,
/// ID of current zkSync network treated as ETH network ID.
/// Used to distinguish zkSync from other Web3-capable networks.
/// ID of current ZKsync network treated as ETH network ID.
/// Used to distinguish ZKsync from other Web3-capable networks.
pub zksync_network_id: L2ChainId,
}

Expand All @@ -29,10 +29,10 @@ impl NetworkConfig {
}

/// An enum that represents the version of the fee model to use.
/// - `V1`, the first model that was used in zkSync Era. In this fee model, the pubdata price must be pegged to the L1 gas price.
/// - `V1`, the first model that was used in ZKsync Era. In this fee model, the pubdata price must be pegged to the L1 gas price.
/// Also, the fair L2 gas price is expected to only include the proving/computation price for the operator and not the costs that come from
/// processing the batch on L1.
/// - `V2`, the second model that was used in zkSync Era. There the pubdata price might be independent from the L1 gas price. Also,
/// - `V2`, the second model that was used in ZKsync Era. There the pubdata price might be independent from the L1 gas price. Also,
/// The fair L2 gas price is expected to both the proving/computation price for the operator and the costs that come from
/// processing the batch on L1.
#[derive(Debug, Clone, Copy, Deserialize, PartialEq, Eq)]
Expand Down
6 changes: 3 additions & 3 deletions core/lib/crypto/README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# zkSync crypto. Essential cryptography primitives for the zkSync network
# ZKsync crypto. Essential cryptography primitives for the ZKsync network

`zksync_crypto` is a crate containing essential zkSync cryptographic primitives, such as private keys and hashers.
`zksync_crypto` is a crate containing essential ZKsync cryptographic primitives, such as private keys and hashers.

## License

`zksync_crypto` is a part of zkSync stack, which is distributed under the terms of both the MIT license and the Apache
`zksync_crypto` is a part of ZKsync stack, which is distributed under the terms of both the MIT license and the Apache
License (Version 2.0).

See [LICENSE-APACHE](../../../LICENSE-APACHE), [LICENSE-MIT](../../../LICENSE-MIT) for details.
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ impl Eip712Domain {
pub const NAME: &'static str = "zkSync";
/// Version of the protocol. While there may be `2.x` releases, the minor release version bump
/// should not be breaking, meaning that clients from the `2.x-1` version should be able to communicate
/// with zkSync server. Thus `VERSION` corresponds to the major version only.
/// with ZKsync server. Thus `VERSION` corresponds to the major version only.
pub const VERSION: &'static str = "2";

pub fn new(chain_id: L2ChainId) -> Self {
Expand Down
2 changes: 1 addition & 1 deletion core/lib/dal/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Data access layer (DAL) for zkSync Era.
//! Data access layer (DAL) for ZKsync Era.

// Linter settings.
#![warn(clippy::cast_lossless)]
Expand Down
2 changes: 1 addition & 1 deletion core/lib/eth_client/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ pub trait EthInterface: Sync + Send {
///
/// The example use cases for this trait would be:
///
/// - An operator that sends transactions and interacts with zkSync contract.
/// - An operator that sends transactions and interacts with ZKsync contract.
/// - A wallet implementation in the SDK that is tied to a user's account.
///
/// When adding a method to this trait:
Expand Down
2 changes: 1 addition & 1 deletion core/lib/l1_contract_interface/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Utilities for interacting with the zkSync L1 contract
//! Utilities for interacting with the ZKsync L1 contract
//!
//! Provides utilities both to encode input data for the contract and to decode
//! the data provided by the contract.
Expand Down
2 changes: 1 addition & 1 deletion core/lib/state/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Execution of transaction in zkSync Era
//! Execution of transaction in ZKsync Era

// Linter settings.
#![warn(missing_debug_implementations, missing_docs, bare_trait_objects)]
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/api/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ impl<'de> Deserialize<'de> for BlockNumber {
}
}

/// Block unified identifier in terms of zkSync
/// Block unified identifier in terms of ZKsync
///
/// This is an utility structure that cannot be (de)serialized, it has to be created manually.
/// The reason is because Web3 API provides multiple methods for referring block either by hash or number,
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ pub struct L2BlockHasher {
}

impl L2BlockHasher {
/// At the beginning of the zkSync, the hashes of the blocks could be calculated as the hash of their number.
/// At the beginning of the ZKsync, the hashes of the blocks could be calculated as the hash of their number.
/// This method returns the hash of such L2 blocks.
pub fn legacy_hash(l2_block_number: L2BlockNumber) -> H256 {
H256(keccak256(&l2_block_number.0.to_be_bytes()))
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/commitment/mod.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! Data structures that have more metadata than their primary versions declared in this crate.
//! For example, L1 batch defined here has the `root_hash` field which is absent in `L1BatchHeader`.
//!
//! Existence of this module is caused by the execution model of zkSync: when executing transactions,
//! Existence of this module is caused by the execution model of ZKsync: when executing transactions,
//! we aim to avoid expensive operations like the state root hash recalculation. State root hash is not
//! required for the rollup to execute L1 batches, it's needed for the proof generation and the Ethereum
//! transactions, thus the calculations are done separately and asynchronously.
Expand Down
4 changes: 2 additions & 2 deletions core/lib/types/src/fee.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,9 @@ impl Default for TransactionExecutionMetrics {
pub struct Fee {
/// The limit of gas that are to be spent on the actual transaction.
pub gas_limit: U256,
/// zkSync version of EIP1559 maxFeePerGas.
/// ZKsync version of EIP1559 maxFeePerGas.
pub max_fee_per_gas: U256,
/// zkSync version of EIP1559 maxPriorityFeePerGas.
/// ZKsync version of EIP1559 maxPriorityFeePerGas.
pub max_priority_fee_per_gas: U256,
/// The maximal gas per pubdata byte the user agrees to.
pub gas_per_pubdata_limit: U256,
Expand Down
4 changes: 2 additions & 2 deletions core/lib/types/src/fee_model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -157,10 +157,10 @@ pub struct PubdataIndependentBatchFeeModelInput {
}

/// The enum which represents the version of the fee model. It is used to determine which fee model should be used for the batch.
/// - `V1`, the first model that was used in zkSync Era. In this fee model, the pubdata price must be pegged to the L1 gas price.
/// - `V1`, the first model that was used in ZKsync Era. In this fee model, the pubdata price must be pegged to the L1 gas price.
/// Also, the fair L2 gas price is expected to only include the proving/computation price for the operator and not the costs that come from
/// processing the batch on L1.
/// - `V2`, the second model that was used in zkSync Era. There the pubdata price might be independent from the L1 gas price. Also,
/// - `V2`, the second model that was used in ZKsync Era. There the pubdata price might be independent from the L1 gas price. Also,
/// The fair L2 gas price is expected to both the proving/computation price for the operator and the costs that come from
/// processing the batch on L1.
#[derive(Debug, Clone, Copy, Serialize, Deserialize)]
Expand Down
4 changes: 2 additions & 2 deletions core/lib/types/src/l1/mod.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Definition of zkSync network priority operations: operations initiated from the L1.
//! Definition of ZKsync network priority operations: operations initiated from the L1.

use std::convert::TryFrom;

Expand Down Expand Up @@ -119,7 +119,7 @@ pub struct L1TxCommonData {
pub op_processing_type: OpProcessingType,
/// Priority operations queue type.
pub priority_queue_type: PriorityQueueType,
/// Tx hash of the transaction in the zkSync network. Calculated as the encoded transaction data hash.
/// Tx hash of the transaction in the ZKsync network. Calculated as the encoded transaction data hash.
pub canonical_tx_hash: H256,
/// The amount of ETH that should be minted with this transaction
pub to_mint: U256,
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/l2/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ pub enum TransactionType {
LegacyTransaction = 0,
EIP2930Transaction = 1,
EIP1559Transaction = 2,
// EIP 712 transaction with additional fields specified for zkSync
// EIP 712 transaction with additional fields specified for ZKsync
EIP712Transaction = EIP_712_TX_TYPE as u32,
PriorityOpTransaction = PRIORITY_OPERATION_L2_TX_TYPE as u32,
ProtocolUpgradeTransaction = PROTOCOL_UPGRADE_TX_TYPE as u32,
Expand Down
6 changes: 3 additions & 3 deletions core/lib/types/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! zkSync types: essential type definitions for zkSync network.
//! ZKsync types: essential type definitions for ZKsync network.
//!
//! `zksync_types` is a crate containing essential zkSync network types, such as transactions, operations and
//! `zksync_types` is a crate containing essential ZKsync network types, such as transactions, operations and
//! blockchain primitives.

#![allow(clippy::upper_case_acronyms, clippy::derive_partial_eq_without_eq)]
Expand Down Expand Up @@ -63,7 +63,7 @@ pub mod proto;
pub mod transaction_request;
pub mod utils;

/// Denotes the first byte of the special zkSync's EIP-712-signed transaction.
/// Denotes the first byte of the special ZKsync's EIP-712-signed transaction.
pub const EIP_712_TX_TYPE: u8 = 0x71;

/// Denotes the first byte of the `EIP-1559` transaction.
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/protocol_upgrade.rs
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,7 @@ pub struct ProtocolUpgradeTxCommonData {
pub gas_per_pubdata_limit: U256,
/// Block in which Ethereum transaction was included.
pub eth_block: u64,
/// Tx hash of the transaction in the zkSync network. Calculated as the encoded transaction data hash.
/// Tx hash of the transaction in the ZKsync network. Calculated as the encoded transaction data hash.
pub canonical_tx_hash: H256,
/// The amount of ETH that should be minted with this transaction
pub to_mint: U256,
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/tokens.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ pub struct TokenInfo {
pub metadata: TokenMetadata,
}

/// Relevant information about tokens supported by zkSync protocol.
/// Relevant information about tokens supported by ZKsync protocol.
#[derive(Debug, Serialize, Deserialize, Clone, PartialEq)]
pub struct TokenMetadata {
/// Token name (e.g. "Ethereum" or "USD Coin")
Expand Down
2 changes: 1 addition & 1 deletion core/lib/types/src/tx/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! `transactions` is module that holds the essential information for every transaction.
//!
//! Since in zkSync Era every operation can be executed either from the contract or rollup,
//! Since in ZKsync Era every operation can be executed either from the contract or rollup,
//! it makes more sense to define the contents of each transaction chain-agnostic, and extent this data
//! with metadata (such as fees and/or signatures) for L1 and L2 separately.

Expand Down
2 changes: 1 addition & 1 deletion core/lib/utils/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Various helpers used in the zkSync stack.
//! Various helpers used in the ZKsync stack.

pub mod bytecode;
mod convert;
Expand Down
2 changes: 1 addition & 1 deletion core/lib/web3_decl/src/client/network.rs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ impl From<L2ChainId> for L2 {
}
}

/// Associates a type with a particular type of RPC networks, such as Ethereum or zkSync Era. RPC traits created using `jsonrpsee::rpc`
/// Associates a type with a particular type of RPC networks, such as Ethereum or ZKsync Era. RPC traits created using `jsonrpsee::rpc`
/// can use `ForNetwork` as a client boundary to restrict which implementations can call their methods.
pub trait ForNetwork {
/// Network that the type is associated with.
Expand Down
2 changes: 1 addition & 1 deletion core/lib/web3_decl/src/error.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! Definition of errors that can occur in the zkSync Web3 API.
//! Definition of errors that can occur in the ZKsync Web3 API.

use std::{
collections::HashMap,
Expand Down
2 changes: 1 addition & 1 deletion core/lib/web3_decl/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//! `zksync_web3_decl` is a collection of common types required for zkSync Web3 API
//! `zksync_web3_decl` is a collection of common types required for ZKsync Web3 API
//! and also `jsonrpsee`-based declaration of server and client traits.
//!
//! Web3 namespaces are declared in `namespaces` module.
Expand Down
Loading

0 comments on commit 0b4104d

Please sign in to comment.