π OpenHands: AI-Driven Development
chore(deps): enforce seven-day third-party release-age policy (#18800)
πΎ smolpaws542aa917de74
diff --git a/.agents/skills/custom-codereview-guide.md b/.agents/skills/custom-codereview-guide.mdindex bf5fd68f2f..3d08375d0b 100644--- a/.agents/skills/custom-codereview-guide.md+++ b/.agents/skills/custom-codereview-guide.md@@ -373,3 +373,24 @@ temporary `.pr/` artifacts. Do not manufacture feedback to avoid approval.For every finding, trace the call or data flow far enough to show the concreteuser-visible or architectural consequence. Prefer one root-cause comment overseveral symptoms, and suggest the smallest viable correction.++## Dependency release-age review++For dependency additions or updates, inspect every changed third-party npm or+PyPI version, including transitive lockfile changes. Require at least seven days+since publication of that exact version. Use npm or PyPI registry publication/+upload metadata; this repository has no `uv.lock`. Include PyPI version changes+in Docker or launcher install commands. A weekly bot schedule, an old package+name, or a passing install is not age evidence.++For an under-seven-day artifact, leave a COMMENT naming the package, version,+publication time, and source, and defer approval until it ages out or a maintainer+explicitly approves a narrowly documented exception. If publication time is+unavailable, ask for that evidence. Existing named first-party exemptions apply+only to those packages, not their third-party dependencies or blanket approval+of the lockfile. Apply this check before any dependency-bump fast path.++Flag removal or weakening of the npm Dependabot cooldown or new broad+exemptions. Dependabot security updates bypass cooldown, so review them under+the explicit maintainer-exception rule in `AGENTS.md`; agents cannot approve+their own bypass.diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex 4aba6439a3..4f2ffe91f8 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -72,6 +72,9 @@ jobs:node-version: "24.15"cache: npm+ - name: Use pinned npm+ run: npm install --global [email protected] --ignore-scripts --no-audit --no-fund+- name: Install dependenciesrun: npm cidiff --git a/.pr/cloud-first-run.png b/.pr/cloud-first-run.pngnew file mode 100644index 0000000000..01d2ea0550Binary files /dev/null and b/.pr/cloud-first-run.png differdiff --git a/AGENTS.md b/AGENTS.mdindex 6622369d24..ff96361ee0 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -93,3 +93,33 @@ Use the `e2e-testing` skill for suite selection and E2E-specific requirements.## DigitalOcean Managed AgentsBefore changing `scripts/mars-*` / `scripts/tunnel-*`, `src/api/mars/`, the Managed Agents UI (`src/components/features/backends/managed-agents/`) or the MARS hooks, read `src/api/mars/AGENTS.md`.++## Dependency release-age policy++- Wait at least seven days after publication before adding or updating a+ third-party npm or PyPI version, including transitive lockfile changes.+ A weekly update schedule alone does not enforce this minimum age.+- Keep the npm Dependabot `cooldown.default-days: 7`. This repository has+ no Python Dependabot entry or uv project/lock. Apply the PyPI age rule to+ version changes in Docker or launcher install commands as well.+ Existing named first-party exceptions do not exempt their third-party+ dependencies. Do not add broad exemptions or disable the cutoff to make a+ resolver succeed.+- Verify the exact version's publication/upload time from npm or PyPI metadata+ rather than the package's creation date.+ If age cannot be established, report the missing evidence rather than guess.+- Security updates can bypass Dependabot cooldown. An urgent exception needs+ explicit maintainer approval recorded in the PR with the package, version,+ advisory/reason, and publication time. Agents must not grant themselves an+ exception. Keep overrides narrow and remove temporary exceptions afterward.+- Repository resolver settings do not protect downstream `pip install` or+ `uv tool install` consumers, and do not retroactively validate existing locks.+ Use the committed lock for reproducible installs; review newly resolved+ artifacts before committing a lock update.++This repository pins npm 11.12.1 in `package.json` (`packageManager` and Volta);+use `npm --version` to confirm the active tool. The previous npm 10.5.0 pin+silently ignored `--min-release-age`. For manual npm dependency resolution, run+`npm install --min-release-age=7` (days), or verify registry timestamps before+committing the result. The option requires npm >= 11.10. `npm ci` replays the+lock and is not proof that newly locked versions meet the age rule.diff --git a/README.md b/README.mdindex 081f47badc..f4d77c4535 100644--- a/README.md+++ b/README.md@@ -126,12 +126,18 @@ This setting isolates conversation execution; it does not move the entire Canvas> [!WARNING]> This runs the agent-server directly on the machine you're installing on β the agent will have full access to your filesystem!-**Prerequisites**: [Node.js](https://nodejs.org/) 24 or later, `npm`, `uv` (for running the agent server via `uvx`)+**Prerequisites**: [Node.js](https://nodejs.org/) 24 or later, npm 11.12.1 (the repository pin), `uv` (for running the agent server via `uvx`)++Check `npm --version` before resolving dependencies. The seven-day release-age+filter (`npm install --min-release-age=7`) requires npm >=11.10; older versions+do not enforce it. Use `npm ci` to replay the committed lockfile. This npm+requirement is for contributor dependency resolution, not for installing the+published Canvas package.```shgit clone https://github.com/OpenHands/OpenHands.gitcd OpenHands-npm install+npm cinpm run dev```diff --git a/package.json b/package.jsonindex 0ab381551b..54aceb5f74 100644--- a/package.json+++ b/package.json@@ -179,9 +179,10 @@"vite-plugin-svgr": "5.2.0","vitest": "5.0.0"},- "packageManager": "[email protected]",+ "packageManager": "[email protected]","volta": {- "node": "24.21.0"+ "node": "24.21.0",+ "npm": "11.12.1"},"msw": {"workerDirectory": [