Skip to content
Monpediaby Unity Nodes
ClosedPull Request

Add MIP linter, adjust existing MIPs

by pdobaczCreated Oct 12, 2026monad-crypto/MIPs

ReferencesMIP-1

Adds a linter for MIPs and MRCs, modelled on the ethereum/EIPs linter but limited to the rules in MIP-1 and mip-emplate.md, and runs it on every pull request that changes a proposal.

It came out a bit large and quite crude so proposing as draft, feel free to reject and propose sth else instead.

It adjusts the existing MIPs to pass the linter, if any of the changes doesn't seem right, we can relax the rules.

List of linter errors & warnings:

File and text (every document)

  • file-size: the file is larger than 1 MB.
  • file-unreadable: the file cannot be opened.
  • lint-failed: the linter crashed on this file; reported as an error so the run fails.
  • text-invisible-chars: a control, format, private-use or line/paragraph separator character.
  • line-length: a line longer than 10,000 characters; the file is not linted further.
  • preamble-missing: line 1 is not ---, or the closing --- is missing.

Preamble

  • preamble-header: a preamble line is not name: value.
  • preamble-no-dup: a header appears twice.
  • preamble-unknown: a header MIP-1 does not define.
  • preamble-order: headers are not in MIP-1 order.
  • preamble-trim: not exactly one space after the colon, or trailing whitespace.
  • preamble-req: a required header is missing (mip, title, description, author, discussions-to, status, type, created).
  • preamble-uint: mip is not a positive integer.
  • preamble-len-title: title is shorter than 2 or longer than 90 characters.
  • preamble-len-description: description is shorter than 2 or longer than 140 characters.
  • preamble-title-case (warning): title is not in title case.
  • preamble-description-case (warning): description does not start with a capital letter.
  • preamble-re-standard: title or description contains "standard" or a variation of it.
  • preamble-re-dash: title or description references a proposal as MIP N or MIPN.
  • preamble-re-own-number: title or description contains the document's own number.
  • preamble-list: list items are not separated by a comma and one space.
  • preamble-author: an author is not Name, Name (@github), Name or Name (@github) .
  • preamble-author-github: no author has a GitHub username.
  • preamble-discussions-to: not an https URL on forum.monad.xyz.
  • preamble-enum: status, type or category is outside the allowed values.
  • preamble-req-category: a Standards Track or Meta MIP has no category.
  • preamble-category: an Informational MIP has a category.
  • preamble-date: created or last-call-deadline is not a valid yyyy-mm-dd date.
  • preamble-req-last-call-deadline: Last Call without last-call-deadline.
  • preamble-req-withdrawal-reason: Withdrawn without withdrawal-reason.
  • preamble-uint-list: requires is not a comma-separated list of numbers.
  • preamble-requires-exists: requires names a number with no file in the repository.
  • preamble-req-requires: a Hardfork MIP has no requires.
  • file-name: the file is not MIPs/MIP-N.md or MRCs/MRC-N.md matching mip and category, or an unnumbered draft is not MIP-draft_*.md / MRC-draft_*.md.
  • file-name-dup: the number is already used by a file in the other directory.

Body markup (every document, MIP-1 included)

  • markdown-unclosed-fence: a code fence is never closed.
  • markdown-link-syntax: a ]( the link patterns could not parse, such as nested brackets in the text or whitespace in the URL.
  • markdown-no-html: a raw HTML tag other than bare or .
  • markdown-no-kramdown: a kramdown {: attribute list.
  • markdown-html-comments: an HTML comment.
  • markdown-headings-space: a # heading without a space after the hashes.
  • markdown-re-dash: a proposal referenced as MIP N, MIPN or in lower case.
  • markdown-refs: a referenced MIP-N or MRC-N does not exist, or a placeholder number such as MRC-XX, MIP-N, MIP-### or MIP-TBD (placeholders are not checked in MIP-1).
  • markdown-mip-mrc: an MRC referenced as MIP-N, or the reverse.
  • markdown-link-first: the first mention of another proposal is not a relative link to its file.

Template (not applied to MIP-1)

  • markdown-section-name: a template section heading with different capitalization.
  • markdown-req-section: a required section is missing (Abstract, Specification, Rationale, Security Considerations, Copyright); a warning when a Core MIP has no Test Cases.
  • markdown-section-dup: a template section appears twice.
  • markdown-order-section: template sections are out of order.
  • markdown-copyright: the Copyright section is not exactly the CC0 line, with a hint when it contains a non-breaking space.
  • markdown-placeholder: a Final MIP still has TBD in Rationale or Needs discussion. in Security Considerations.
  • markdown-rel-links: an absolute link to this site or repository, an external link not on the allow list, or a relative link that leaves the repository or points to a missing file. EDIT: there are now exceptions from this - external links are discouraged but allowed (lint as a warning) in Rationale and Motivation sections. Reference Impl. is also allowed to point at moand and monad-bft repos under CL
  • markdown-rfc2119: an RFC 2119 keyword outside the Specification section.

Workflow (CI only)

  • asset-type: a changed file under assets/ with an HTML, XML, SVGZ or JavaScript extension.
  • asset-front-matter: a changed asset that starts with ---.
  • "Changes outside the proposals" (warning, no rule id): the PR touches files outside MIPs/, MRCs/ and assets/.