The @apphosting/build@0.1.7 package imports yaml but does not declare it as a dependency in package.json. This causes
firebase deploy to fail with Error: Cannot find module 'yaml'.
details
In @apphosting/build/index.ts:7, there is:
import { parse as parseYaml } from "yaml";
However, @apphosting/buildpackage.json does not include yaml in its dependencies:
"dependencies": {
"@apphosting/common": "*",
"@npmcli/promise-spawn": "^3.0.0",
"colorette": "^2.0.20",
"commander": "^11.1.0",
"npm-pick-manifest": "^9.0.0",
"ts-node": "^10.9.1"
},
"devDependencies": {
"@types/commander": "*",
"ts-mocha": "*",
"ts-node": "*",
"typescript": "*"
}
While firebase-tools does have yaml in its own dependencies, it gets installed nested at node_modules/firebase-tools/node_modules/yaml, which @apphosting/build (installed at top-level node_modules/@apphosting/build) cannot resolve.
The
@apphosting/build@0.1.7package importsyamlbut does not declare it as a dependency inpackage.json. This causesfirebase deployto fail with Error:Cannot find module 'yaml'.details
In @apphosting/build/index.ts:7, there is:
However, @apphosting/buildpackage.json does not include yaml in its dependencies:
While
firebase-toolsdoes haveyamlin its own dependencies, it gets installed nested atnode_modules/firebase-tools/node_modules/yaml, which@apphosting/build(installed at top-levelnode_modules/@apphosting/build) cannot resolve.