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

Parcel 2: .env files aren't watched for changes #3942

Open
Banou26 opened this issue Dec 26, 2019 · 4 comments
Open

Parcel 2: .env files aren't watched for changes #3942

Banou26 opened this issue Dec 26, 2019 · 4 comments

Comments

@Banou26
Copy link
Contributor

Banou26 commented Dec 26, 2019

🐛 bug report

.env files aren't watched for changes, you need to delete the cache to update .env variables.

@Banou26 Banou26 changed the title Parcel 2: .env files doesn't accept "_" in variable names, .env files not watched Parcel 2: .env files aren't watched for changes Dec 26, 2019
@Banou26
Copy link
Contributor Author

Banou26 commented Dec 26, 2019

If the package is from a lerna monorepo, the .env file used is the one at the root of the lerna monorepo and not the sub package.
I don't know if that's the desired behavior but it seems weird to me since it remove configuration isolation from each packages in the monorepo.

may be related to #3917 since both are related to lerna's use and config scope ?

@Banou26
Copy link
Contributor Author

Banou26 commented Jan 6, 2020

For my previous comment, should i open another issue ?
Actually have both of the behaviors i've described would be best, use both the .env at the top of the monorepo, and use the .env in each sub packages as it'd allow for both shared config, and configuration isolation.
Any opinions on that ?

@mischnic
Copy link
Member

mischnic commented Jan 6, 2020

Yes, it would make sense to have env files in the packages overwrite env files further up.

@devongovett
Copy link
Member

Partially fixed by #3942. You won't need to clear the cache anymore, but .env files still aren't in the graph so won't be watched in dev mode. Restarting Parcel should at least work though. We'll eventually get the env file in the graph too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants