Skip to content

chore: update package.json for postinstall canary test#13

Open
pullfrog[bot] wants to merge 15 commits intomainfrom
pullfrog/test-pkg-postinstall
Open

chore: update package.json for postinstall canary test#13
pullfrog[bot] wants to merge 15 commits intomainfrom
pullfrog/test-pkg-postinstall

Conversation

@pullfrog
Copy link
Copy Markdown

@pullfrog pullfrog Bot commented Apr 10, 2026

Updates package.json as part of the dependency installation behavior test. Changes the package name to test-pkg and adds a postinstall script that writes a canary file to /tmp/postinstall-canary.txt.

Pullfrog  | Triggered by Pullfrog | Using Claude Opus𝕏


Note

Medium Risk
Adds a postinstall script that writes to /tmp, which can affect install behavior and is commonly flagged by security tooling. Changes are limited to package.json metadata and scripts.

Overview
Renames the npm package to test-pkg, adds a version, and simplifies package.json by removing private/type and the test script.

Introduces a postinstall script that writes a canary marker to /tmp/postinstall-canary.txt to validate install-time behavior.

Reviewed by Cursor Bugbot for commit 047b187. Bugbot is set up for automated code reviews on this repo. Configure here.

@pullfrog pullfrog Bot force-pushed the pullfrog/test-pkg-postinstall branch from 104e3ef to ac3b8e5 Compare April 16, 2026 17:48
@pullfrog pullfrog Bot force-pushed the pullfrog/test-pkg-postinstall branch from ac3b8e5 to 3fdf91c Compare April 16, 2026 22:33
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 0f8cb09. Configure here.

Comment thread package.json
}
"postinstall": "echo CANARY_MARKER > /tmp/postinstall-canary.txt"
},
"dependencies": {}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removal of private field risks accidental npm publish

Medium Severity

The "private": true field was removed from package.json. This safety guard prevents accidental publication to the npm registry. Without it, an npm publish (manual or via CI misconfiguration) would push this test package publicly, which could also enable a dependency-confusion vector since the name test-pkg is generic.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 0f8cb09. Configure here.

Comment thread package.json
"test": "vitest run"
}
"postinstall": "echo CANARY_MARKER > /tmp/postinstall-canary.txt"
},
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test script removed while test files still exist

Low Severity

The "test": "vitest run" script was deleted and replaced solely with a postinstall script. The test file test/math.test.ts still imports from vitest and expects to be runnable, so npm test now produces an error instead of running the existing test suite. The postinstall canary could have been added alongside the existing test script rather than replacing it.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 0f8cb09. Configure here.

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.

0 participants