Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

--env reports dotenv files as not found when the dotenv file has a syntax error, despite reading from it #23674

Open
KlaasSkelteAtEnatom opened this issue May 3, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@KlaasSkelteAtEnatom
Copy link

Version: Deno 1.43.1

To reproduce:
.env

VALID=valid
INVALID=c:\path

test.ts

console.log(Deno.env.get("VALID"));
console.log(Deno.env.get("INVALID"));

Run with deno -A --env test.ts

Output:

Warning The `--env` flag was used, but the dotenv file '.env' was not found.
valid
undefined

This is an improvement over older versions, because it at least loads something. Still, I'd rather have deno not show the warning, because it is factually wrong.

@dsherret dsherret added the bug Something isn't working label May 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants