{
  "schemaVersion": "ebb.rule.v1",
  "id": "npm.package.read-package-json.eol",
  "ecosystem": "npm",
  "purl": "pkg:npm/read-package-json",
  "affectedVersions": "vers:npm/*",
  "event": "end-of-life",
  "severity": "high",
  "title": "read-package-json is no longer supported",
  "summary": "npm states that read-package-json is no longer supported and recommends @npmcli/package-json.",
  "replacement": "@npmcli/package-json",
  "sources": [
    {
      "title": "read-package-json package deprecation notice",
      "url": "https://www.npmjs.com/package/read-package-json",
      "accessedAt": "2026-10-16"
    },
    {
      "title": "read-package-json registry metadata",
      "url": "https://registry.npmjs.org/read-package-json/latest",
      "accessedAt": "2026-10-16"
    }
  ],
  "provenance": {
    "observedAt": "2026-10-16",
    "reviewedAt": "2026-10-16",
    "reviewer": "arminazimi"
  },
  "migration": {
    "constraints": [
      "Preserve package normalization, extra metadata loading, error handling, file paths, warnings, and callback or promise timing relied on by callers."
    ],
    "steps": [
      {
        "id": "replace-read-package-json",
        "title": "Move to @npmcli/package-json",
        "instructions": "Replace the dependency and reads with @npmcli/package-json, adapting its promise-based API and normalized result shape.",
        "targets": "all"
      }
    ],
    "verification": [
      {
        "command": "npm run test --if-present",
        "purpose": "Run valid, malformed, missing, and normalized package metadata tests."
      }
    ]
  }
}
