按照Heroku的Python入门教程,我遇到了一个错误
当我运行时:
heroku local web
我得到了错误:
internal/fs/utils.js:269
throw err;
^
Error: EISDIR: illegal operation on a directory, read
at Object.readSync (fs.js:568:3)
at tryReadSync (fs.js:353:20)
at Object.readFileSync (fs.js:390:19)
at loadEnvsFile (/usr/local/Cellar/heroku/7.59.0/libexec/node_modules/foreman/lib/envs.js:132:15)
at Array.map (<anonymous>)
at loadEnvs (/usr/local/Cellar/heroku/7.59.0/libexec/node_modules/foreman/lib/envs.js:147:30)
at Command.<anonymous> (/usr/local/Cellar/heroku/7.59.0/libexec/node_modules/foreman/nf.js:72:16)
at Command.listener (/usr/local/Cellar/heroku/7.59.0/libexec/node_modules/foreman/node_modules/commander/index.js:315:8)
at Command.emit (events.js:314:20)
at Command.parseArgs (/usr/local/Cellar/heroku/7.59.0/libexec/node_modules/foreman/node_modules/commander/index.js:654:12) {
errno: -21,
syscall: 'read',
code: 'EISDIR'
}发布于 2021-09-22 21:17:01
此错误是由于我对python venv文件夹使用了.env而导致的
python3.9 -m venv .env --prompt='heroku-getting-started'
看起来heroku的python入门期望.env是这样的
$ cat .env
TIMES=2我最终将python venv移到了.venv,这个错误就消失了。
https://stackoverflow.com/questions/69291369
复制相似问题