diff --git a/EIPS/eip-1845.md b/EIPS/eip-1845.md index e1c1c80b229209..eae4dc053c7202 100644 --- a/EIPS/eip-1845.md +++ b/EIPS/eip-1845.md @@ -1,54 +1,64 @@ --- eip: -title: -author: , FirstName (@GitHubUsername) and GitHubUsername (@GitHubUsername)> -discussions-to: +title: Fork Name Standards +author: (winsvega) +discussions-to: https://github.com/ethereum/retesteth/issues/23 status: Draft -type: -category (*only required for Standard Track): -created: -requires (*optional): -replaces (*optional): +category: Informational +created: 2019-03-18 --- - -This is the suggested template for new EIPs. - -Note that an EIP number will be assigned by an editor. When opening a pull request to submit your EIP, please use an abbreviated title in the filename, `eip-draft_title_abbrev.md`. - -The title should be 44 characters or less. +Fork Name Standards ## Simple Summary - -If you can't explain it simply, you don't understand it well enough." Provide a simplified and layman-accessible explanation of the EIP. +Name forks like `ETH-0001, ETH-0002, ETH-0003` and son on. ## Abstract - -A short (~200 word) description of the technical issue being addressed. +Each client parse `ETH-0001` kind of indexes into ethereum fork rules. `ETH-0001` stands for Frontier rules, and so on. +There for if in any config instead of Frontier, a `ETH-0001` provided, the client must parse it as Frontier rule. Parsing previous naming convention (`Frontier, Homestead, EIP150`) becomes optional, `ETH-xxxx` naming convention is mandatory for all clients to implement. ## Motivation - -The motivation is critical for EIPs that want to change the Ethereum protocol. It should clearly explain why the existing protocol specification is inadequate to address the problem that the EIP solves. EIP submissions without sufficient motivation may be rejected outright. +**Clients:** +Different clients use different fork names even for the main network on their genesis config. If we want a generic genesis format, we have to use a standard for the fork names. + +**Development:** +After ConstantinopleFix release, devs wanted to rename it into Petersburg. That require code changes which is development time and money. And code changes to the client might result in errors and bugs if not tested and reviewed properly. +During hardfork development the name is not fixed, thus closer to the release date, need to change the fork name again in the code. + +Following standard for the fork names will allow to hardcode fork names without issues. ## Specification - -The technical specification should describe the syntax and semantics of any new feature. The specification should be detailed enough to allow competing, interoperable implementations for any of the current Ethereum platforms (go-ethereum, parity, cpp-ethereum, ethereumj, ethereumjs, and [others](https://github.com/ethereum/wiki/wiki/Clients)). +In genesis config the following fields must be understood by all clients: + +``` +"ETH-0001-FB": "5000", +"ETH-0002-FB": "15000", +... +"ETH-xxxx-FB": "25000" +``` + +Where `ETH-0001-FB` stands for Frontier fork block number. ## Rationale - -The rationale fleshes out the specification by describing what motivated the design and why particular design decisions were made. It should describe alternate designs that were considered and related work, e.g. how the feature is supported in other languages. The rationale may also provide evidence of consensus within the community, and should discuss important objections or concerns raised during discussion.--> +Rationale is to get a fork name standard for generic genesis format. So that RPC test tools provide clients with a uniform genesis configuration. It is easy to add +1 to the next form name number rather then discuss ConstantinopleFix vs Petersburg and change the constant string everywhere both in code and tests when we want to rename. ## Backwards Compatibility - -All EIPs that introduce backwards incompatibilities must include a section describing these incompatibilities and their severity. The EIP must explain how the author proposes to deal with these incompatibilities. EIP submissions without a sufficient backwards compatibility treatise may be rejected outright. +Clients could support Frontier, Homestead and so on naming convention. ## Test Cases - -Test cases for an implementation are mandatory for EIPs that are affecting consensus changes. Other EIPs can choose to include links to test cases if applicable. +Retesteth will generate genesis.json and run all tests with this specification. ## Implementation - -The implementations must be completed before any EIP is given status "Final", but it need not be completed before the EIP is accepted. While there is merit to the approach of reaching consensus on the specification and rationale before writing code, the principle of "rough consensus and running code" is still useful when it comes to resolving many discussions of API details. +**Aleth:** +Aleth replace hardcoded variable names with and array that resolve +``` +chainParams().forkblocks["ETH-0002-FB"] +``` +into DAO fork block number, rather then using: + +``` +u256 const& daoHardfork = chainParams().daoHardforkBlock; +``` ## Copyright Copyright and related rights waived via [CC0](https://creativecommons.org/publicdomain/zero/1.0/).