Plasmo "plasmo build" failed in CI
plasmo build compiles the extension and writes a packaged build directory. It exits non-zero when an entry file, manifest override, or imported asset cannot be resolved during the build.
What this error means
The plasmo build step fails with a Failed to ... message naming a missing module, entry, or asset, and the build directory is not produced.
plasmo
🟣 Plasmo v0.88
🔴 ERROR | Failed to resolve import "~components/Popup" from "popup.tsx"
🔴 ERROR | Build failedCommon causes
An unresolved import or entry path
A ~-aliased import or a content-script entry points at a file that does not exist at the path Plasmo expects.
A manifest override referencing a missing asset
The manifest field in package.json references an icon or page not present in the build.
How to fix it
Resolve the failing import or entry
- Read the path in the "Failed to resolve" line.
- Correct the import alias or create the missing entry file.
- Re-run
plasmo build.
Terminal
plasmo build --target=chrome-mv3Match the manifest override to real assets
Ensure icons and pages referenced by the package.json manifest override exist in the source.
package.json
"manifest": {
"host_permissions": ["https://*/*"]
}How to prevent it
- Run
plasmo buildin CI on every change. - Keep import aliases and entry paths consistent.
- Reference only existing assets in the manifest override.
Related guides
Plasmo BPP "keys" missing on publish in CIFix Plasmo Browser Platform Publisher (BPP) failures in CI - the publish action aborts because the submit key…
WXT "wxt zip" build / packaging failed in CIFix "wxt zip" failures in CI - WXT could not produce the distributable zip because the build failed first or…
Manifest V3 CSP rejects 'unsafe-eval' in CIFix Manifest V3 Content Security Policy errors in CI - V3 disallows 'unsafe-eval' and remote script sources i…