Commit b7f5a67
fix bug: DotEnv._get_stream raise IOError when
# How this bug happened ?
The function `find_dotenv` try to find a file named `.env`, if there is a directory named `.env` by coincidence, then `DotEnv._get_stream` will raise IOError.
# Fix this bug
use `os.path.isfile` instead of `os.path.exists`..env is a directory rather than a file (theskumar#120)1 parent ea0604d commit b7f5a67
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
57 | 57 | | |
58 | 58 | | |
59 | 59 | | |
60 | | - | |
| 60 | + | |
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
| |||
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | | - | |
| 244 | + | |
245 | 245 | | |
246 | 246 | | |
247 | 247 | | |
| |||
0 commit comments