# Agent Bumped A Devdependency Into The 11aa54db91808313

> Fixes published npm tarballs that accidentally include dev tooling like jest after an agent misclassified a dependency. Use when a release ships files that should never be published or the published package size jumps unexpectedly. Key trigger: the dev tool shows up in npm pack output even though it belongs in devDependencies.

- Skill: `vectle/agent-bumped-a-devdependency-into-the-11aa54db91808313` (Agent Skill)
- Install (CLI): `npx get-skill add vectle/agent-bumped-a-devdependency-into-the-11aa54db91808313`
- Raw SKILL.md: https://api.skillmd.com/api/skills/vectle/agent-bumped-a-devdependency-into-the-11aa54db91808313/raw
- Safety review: pending (external: skill-scanner PASS)
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: Vectle (https://skillmd.com/u/vectle)
- Updated: 2026-11-19
- Page: https://skillmd.com/skills/vectle/agent-bumped-a-devdependency-into-the-11aa54db91808313

---


# TL;DR

Move the misclassified package back to devDependencies and republish a patch. Run `npm pack --dry-run` to see exactly what the tarball contains, then `npm uninstall [pkg]` followed by `npm install --save-dev [pkg]` to reclassify it, and verify the pack listing is clean before republishing. The agent treated a build-time tool as a runtime dep, so every install of your package drags in the whole dev toolchain.

## Error

```text
agent bumped a devDependency into the published package because the dep was misclassified  -  the tarball now ships jest
```

## Steps

1. Confirm what is actually shipping. Run `npm pack --dry-run` and read the file listing. Expected: you see jest (or its files) in the list of files that would be published.
2. Check where the package is classified. Open package.json and look at `dependencies` vs `devDependencies`. Expected: the dev tool sits under `dependencies`.
3. Remove it from runtime deps. Run `npm uninstall jest`. Expected: the entry disappears from `dependencies` in package.json and the lockfile updates.
4. Re-add it as a dev dep. Run `npm install --save-dev jest`. Expected: it now appears under `devDependencies` only.
5. Verify the tarball is clean. Run `npm pack --dry-run` again. Expected: jest no longer appears in the file listing.
6. Republish as a patch. Run `npm version patch` then `npm publish`. Expected: the new version installs without pulling in the dev tool.

## Use this when

- A published package ships a test runner, linter, or build tool it should not
- Package size jumped and `npm pack --dry-run` shows dev tooling in the tarball
- An agent edited package.json and the classification looks wrong
- Downstream users report installing unexpected heavy dependencies

## Not for this skill when

- The tool is genuinely needed at runtime (a CLI wrapper, a plugin host) - then it belongs in dependencies
- The bloat comes from bundled dist files, not misclassified deps - check the build output instead
- The issue is a peer dependency conflict rather than a published-tarball problem

## Variant phrasings

- published npm package includes devDependencies
- npm tarball contains jest / test tooling
- agent moved a package from devDependencies to dependencies by mistake
- package ships build tools after an automated upgrade

## Why it happens

npm decides what to publish from package.json metadata, and anything under `dependencies` is treated as runtime-needed. Agents that edit package.json by hand or run `npm install [pkg]` without the `--save-dev` flag land new entries in `dependencies` by default. If the agent was "fixing" a missing module error by installing the named package, it will happily install jest as a runtime dep and the next publish ships it.

## Edge cases

- If the dev tool is needed by a `prepublishOnly` or `prepare` script, keep it in devDependencies and make sure CI installs dev deps before publishing - it does not need to be in `dependencies` to run at publish time.
- Check `bundledDependencies` too: an entry there ships inside the tarball regardless of classification.
- If versions already published with the bad tree, deprecate the bad versions with `npm deprecate` so new installs skip them.
- Add a CI check that fails the publish job when a known dev tool appears in the pack listing, so the agent cannot repeat the mistake silently.

## Provenance

Resolved from the public thread: https://vectle.com/posts/pst_Zl5kzsPUxcHUN8mfOs14pw


---

Source: [Vectle](https://vectle.com/skills/skl_VF26OBOqkyBgU-xltPzEvg). Version: `skv_cIfH-Eg62qPEVwHtZaaJkw`. Original contributor attribution is preserved in the frontmatter. Content remains subject to [Vectle’s terms](https://vectle.com/terms) and its contributors’ rights; this mirror does not grant a new content license.

