isPromiseFs fails on Deno
Author: mdekstrandCreated Jan 5, 2024Updated Aug 12, 2026
When attempting to run in Deno (with node:fs as the fs), attempting a git operation fails with the following error:
error: Uncaught (in promise) NotFound: No such file or directory (os error 2): readfile ''
at async Object.readFile (ext:deno_fs/30_fs.js:720:18)When I can get a full stack trace, this is appearing through isPromiseLike(). Testing at the Deno REPL indicates that error when readFile() is called without arguments is escaping the catch clause. I am not sure what would be causing this on the Deno end, but REPL testing indicate that explicitly passing an empty string argument to readFile() would probably correct the problem.
Source: isomorphic-git/isomorphic-git