Skip to content

Commit

Permalink
Small Release/README Fixes (#949)
Browse files Browse the repository at this point in the history
* monorepo: small README fixes and corrections

* Apply suggestions from code review

Co-authored-by: Ev <ev@ethereum.org>

Co-authored-by: Ryan Ghods <ryan@ryanio.com>
Co-authored-by: Ev <ev@ethereum.org>
  • Loading branch information
3 people authored Nov 14, 2020
1 parent e8c5c54 commit 222283b
Show file tree
Hide file tree
Showing 7 changed files with 89 additions and 49 deletions.
5 changes: 3 additions & 2 deletions packages/block/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# ethereumjs-block
# @ethereumjs/block

[![NPM Package][block-npm-badge]][block-npm-link]
[![GitHub Issues][block-issues-badge]][block-issues-link]
[![Actions Status][block-actions-badge]][block-actions-link]
[![Code Coverage][block-coverage-badge]][block-coverage-link]
[![Discord][discord-badge]][discord-link]

Implements schema and functions related to Ethereum's block.
| Implements schema and functions related to Ethereum's block. |
| --- |

Note: this `README` reflects the state of the library from `v3.0.0` onwards. See `README` from the [standalone repository](https://github.com/ethereumjs/ethereumjs-block) for an introduction on the last preceeding release.

Expand Down
5 changes: 3 additions & 2 deletions packages/blockchain/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# ethereumjs-blockchain
# @ethereumjs/blockchain

[![NPM Package][blockchain-npm-badge]][blockchain-npm-link]
[![GitHub Issues][blockchain-issues-badge]][blockchain-issues-link]
[![Actions Status][blockchain-actions-badge]][blockchain-actions-link]
[![Code Coverage][blockchain-coverage-badge]][blockchain-coverage-link]
[![Discord][discord-badge]][discord-link]

A module to store and interact with blocks.
| A module to store and interact with blocks. |
| --- |

Note: this `README` reflects the state of the library from `v5.0.0` onwards. See `README` from the [standalone repository](https://github.com/ethereumjs/ethereumjs-blockchain) for an introduction on the last preceeding release.

Expand Down
103 changes: 66 additions & 37 deletions packages/common/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# ethereumjs-common
# @ethereumjs/common

[![NPM Package][common-npm-badge]][common-npm-link]
[![GitHub Issues][common-issues-badge]][common-issues-link]
[![Actions Status][common-actions-badge]][common-actions-link]
[![Code Coverage][common-coverage-badge]][common-coverage-link]
[![Discord][discord-badge]][discord-link]

Resources common to all Ethereum implementations.
| Resources common to all Ethereum implementations. |
| --- |

Note: this `README` reflects the state of the library from `v2.0.0` onwards. See `README` from the [standalone repository](https://github.com/ethereumjs/ethereumjs-common) for an introduction on the last preceeding release.

Expand Down Expand Up @@ -68,9 +69,57 @@ to ease `blockNumber` based access to parameters.

- [API Docs](./docs/README.md)

# Hardfork Params
# SETUP

## Active Hardforks
## Chains

The `chain` can be set in the constructor like this:

```typescript
const c = new Common({ chain: 'ropsten' })
```

Supported chains:

- `mainnet`
- `ropsten`
- `rinkeby`
- `kovan`
- `goerli`
- Private/custom chain parameters

The following chain-specific parameters are provided:

- `name`
- `chainId`
- `networkId`
- `consensusType` (e.g. `pow` or `poa`)
- `consensusAlgorithm` (e.g. `ethash` or `clique`)
- `genesis` block header values
- `hardforks` block numbers
- `bootstrapNodes` list

To get an overview of the different parameters have a look at one of the chain-specifc
files like `mainnet.json` in the `chains` directory, or to the `Chain` type in [./src/types.ts](./src/types.ts).

### Working with private/custom chains

There are two ways to set up a common instance with parameters for a private/custom chain:

1. You can pass a dictionary - conforming to the parameter format described above - with your custom values in
the constructor or the `setChain()` method for the `chain` parameter.

2. You can base your custom chain's config in a standard one, using the `Common.forCustomChain` method.

## Hardforks

The `hardfork` can be set in constructor like this:

```typescript
const c = new Common({ chain: 'ropsten', hardfork: 'byzantium' })
```

### Active Hardforks

There are currently parameter changes by the following past and future hardfork by the
library supported:
Expand All @@ -86,15 +135,15 @@ library supported:
- `istanbul` (`DEFAULT_HARDFORK` (`v2.0.0` release series))
- `muirGlacier` (since `v1.5.0`)

## Future Hardforks
### Future Hardforks

General support for the `berlin` hardfork has been added along `v2.0.0`, specification of the hardfork regarding EIPs included was not finalized upon release date.

Currently supported `berlin` EIPs:

- `EIP-2315`

## Parameter Access
### Parameter Access

For hardfork-specific parameter access with the `param()` and `paramByBlock()` functions
you can use the following `topics`:
Expand All @@ -111,46 +160,26 @@ hardfork.
The hardfork-specific json files only contain the deltas from `chainstart` and
shouldn't be accessed directly until you have a specific reason for it.

# Chain Params

Supported chains:

- `mainnet`
- `ropsten`
- `rinkeby`
- `kovan`
- `goerli`
- Private/custom chain parameters

The following chain-specific parameters are provided:

- `name`
- `chainId`
- `networkId`
- `consensusType` (e.g. `pow` or `poa`)
- `consensusAlgorithm` (e.g. `ethash` or `clique`)
- `genesis` block header values
- `hardforks` block numbers
- `bootstrapNodes` list

To get an overview of the different parameters have a look at one of the chain-specifc
files like `mainnet.json` in the `chains` directory, or to the `Chain` type in [./src/types.ts](./src/types.ts).
## EIPs

## Working with private/custom chains
Starting with the `v2.0.0` release of the library, EIPs are now native citizens within the library
and can be activated like this:

There are two ways to set up a common instance with parameters for a private/custom chain:
```typescript
const c = new Common({ chain: 'mainnet', eips: [2537] })
```

1. You can pass a dictionary - conforming to the parameter format described above - with your custom values in
the constructor or the `setChain()` method for the `chain` parameter.
The following EIPs are currently supported:

2. You can base your custom chain's config in a standard one, using the `Common.forCustomChain` method.
- [EIP-2537](https://eips.ethereum.org/EIPS/eip-2537): BLS precompiles
- [EIP-2929](https://eips.ethereum.org/EIPS/eip-2929): gas cost increases for state access opcodes

# Bootstrap Nodes
## Bootstrap Nodes

There is no separate config file for bootstrap nodes like in the old `ethereum-common` library.
Instead use the `common.bootstrapNodes()` function to get nodes for a specific chain/network.

# Genesis States
## Genesis States

Network-specific genesis files are located in the `genesisStates` folder.

Expand Down
5 changes: 3 additions & 2 deletions packages/ethash/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@
[![Code Coverage][ethash-coverage-badge]][ethash-coverage-link]
[![Discord][discord-badge]][discord-link]

Implements [Ethash](https://github.com/ethereum/wiki/wiki/Ethash).
| [Ethash](https://github.com/ethereum/wiki/wiki/Ethash) implementation in TypeScript. |
| --- |

Note: this `README` reflects the state of the library from `v1.0.0` onwards. See `README` from the [standalone repository](https://github.com/ethereumjs/ethashjs) for an introduction on the last preceeding release.

Expand Down Expand Up @@ -90,7 +91,7 @@ An `Object` containing:

# TESTS

`npm test`
`npm run test`

# LICENSE

Expand Down
2 changes: 2 additions & 0 deletions packages/tx/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)

## 3.0.0-beta.2 - 2020-11-12

This is the second beta release towards a final library release, see [beta.1 release notes](https://github.com/ethereumjs/ethereumjs-vm/releases/tag/%40ethereumjs%2Ftx%403.0.0-beta.1) for an overview on the full changes since the last publicly released version.

- Added `freeze` option to allow for transaction freeze deactivation (e.g. to allow for subclassing tx and adding additional parameters), see PR [#941](https://github.com/ethereumjs/ethereumjs-vm/pull/941)
- **Breaking:** Reworked constructor to take in data as a `TxData` typed dictionary instead of single values, the `Tx.fromTxData()` factory method becomes an alias for the constructor with this change, see PR [#944](https://github.com/ethereumjs/ethereumjs-vm/pull/944)

Expand Down
13 changes: 9 additions & 4 deletions packages/tx/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
[![Code Coverage][tx-coverage-badge]][tx-coverage-link]
[![Discord][discord-badge]][discord-link]

| Implements schema and functions related to Ethereum's transaction. |
| --- |

Note: this `README` reflects the state of the library from `v3.0.0` onwards. See `README` from the [standalone repository](https://github.com/ethereumjs/ethereumjs-tx) for an introduction on the last preceeding release.

# INSTALL
Expand Down Expand Up @@ -65,21 +68,23 @@ _getFakeTransaction(txParams: TxParams): Transaction {
}
```

# Chain and Hardfork Support
# SETUP

## Chain and Hardfork Support

The `Transaction` constructor receives a parameter of an [`@ethereumjs/common`](https://github.com/ethereumjs/ethereumjs-vm/blob/master/packages/common) object that lets you specify the chain and hardfork to be used. By default, `mainnet` and `istanbul` will be used.

## MuirGlacier Support
### MuirGlacier Support

The `MuirGlacier` hardfork is supported by the library since the `v2.1.2` release.

## Istanbul Support
### Istanbul Support

Support for reduced non-zero call data gas prices from the `Istanbul` hardfork
([EIP-2028](https://eips.ethereum.org/EIPS/eip-2028)) has been added to the library
along with the `v2.1.1` release.

# EIP-155 support
## EIP-155 support

`EIP-155` replay protection is activated since the `spuriousDragon` hardfork. To disable it, set the hardfork to one earlier than `spuriousDragon`.

Expand Down
5 changes: 3 additions & 2 deletions packages/vm/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# ethereumjs-vm
# @ethereumjs/vm

[![NPM Package][vm-npm-badge]][vm-npm-link]
[![GitHub Issues][vm-issues-badge]][vm-issues-link]
[![Actions Status][vm-actions-badge]][vm-actions-link]
[![Code Coverage][vm-coverage-badge]][vm-coverage-link]
[![Discord][discord-badge]][discord-link]

Implements Ethereum's VM in `TypeScript`.
| TypeScript implementation of the Ethereum VM. |
| --- |

Note: this `README` reflects the state of the library from `v5.0.0` onwards. See `README` from the [standalone repository](https://github.com/ethereumjs/ethereumjs-vm) for an introduction on the last preceeding release.

Expand Down

0 comments on commit 222283b

Please sign in to comment.