Open TillaTheHun0 opened 1 year ago
The Empty filepath
issue looks fixed on 1.32.3 (since 8c051dbd1a075ad3c228f78b29b13f0e455972a7) but a different error is thrown, similar to https://github.com/denoland/deno/issues/17176#issuecomment-1364319257
I cannot reproduce the described Empty filepath
issue anymore. Instead I get an error that the npm package that was passed via the -x
flag cannot be found:
error: Uncaught Error: Cannot find module "@commitlint/config-conventional" from "/Users/marvinhagemeister/dev/test/commitlint"
Digging through the code the config is ultimately loaded here:
const dynamicImport = async <T>(id: string): Promise<T> => {
const imported = await import(
path.isAbsolute(id) ? pathToFileURL(id).toString() : id
);
return ('default' in imported && imported.default) || imported;
};
I was trying to use
commitlint
, to "lint" commit messages, but am getting this error:Steps to Reproduce:
In any git repo (with at least 1 commit), run
deno run --allow-read --allow-env --allow-run npm:@commitlint/cli@^17 -x @commitlint/config-conventional --from=HEAD
Expected
commitlint
will validate the commit message ofHEAD
and exit with a 0 status codeActual
deno
crashes due to the uncaught error above.