Skip to content

Allow network-upgrade preamble marker - #171

Open
ritorhymes wants to merge 1 commit into
ethereum:masterfrom
ritovision:feature/network-upgrade-marker-lint
Open

Allow network-upgrade preamble marker#171
ritorhymes wants to merge 1 commit into
ethereum:masterfrom
ritovision:feature/network-upgrade-marker-lint

Conversation

@ritorhymes

@ritorhymes ritorhymes commented May 10, 2026

Copy link
Copy Markdown

Summary

This PR adds lint support for the network-upgrade preamble field so Meta EIPs can mark the hardfork/network upgrade they describe.

The field is optional on Meta EIPs, rejected on non-Meta proposals, and rejected when present but empty.

This is part of the hardfork/network-upgrade rollout tracked in eips-wg/preprocessor#35. The eips-wg site preprocessor consumes this marker to generate a hardfork index and proposal-page membership metadata.

Example

A Meta EIP can now include:

---
eip: 9999
type: Meta
network-upgrade: Glamsterdam
...
---

Changes

  • Add network-upgrade to the default preamble order between category and created.
  • Reject empty network-upgrade values through the existing length lint.
  • Add a generic AllowedOnlyIfEq preamble lint for fields that are allowed only when another field has a configured value.
  • Configure network-upgrade to be allowed only when type: Meta.
  • Add tests for the generic lint and default network-upgrade behavior.

Notes

AllowedOnlyIfEq mirrors the existing RequiredIfEq lint with inverted semantics: where RequiredIfEq requires a field when another equals a value, AllowedOnlyIfEq forbids a field unless another equals a value.

This PR only teaches eipw to accept and validate the new marker. It does not add network-upgrade markers to EIPs or require the marker on all Meta EIPs.

Allow network-upgrade in EIP preambles and keep the marker optional on
Meta EIPs while rejecting marker use on Standards Track and
Informational proposals.

Reject empty network-upgrade values through the existing length lint and
add the field to the default preamble order between category and
created.

Add a generic preamble lint for fields that are allowed only when
another field has a configured value, and use it to enforce the
network-upgrade Meta-only rule.
@ritorhymes
ritorhymes marked this pull request as ready for review May 11, 2026 00:08
@SamWilsn SamWilsn closed this Jul 8, 2026
@SamWilsn SamWilsn reopened this Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants