-
-
Notifications
You must be signed in to change notification settings - Fork 66
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
Can't change environment type in Bundles.php #481
Comments
hello, shouldn't it be like this? Zenstruck\Foundry\ZenstruckFoundryBundle::class => ['dev' => true, 'dev_api' => true, 'test' => true] |
Hi ! |
please provide more information:
|
1 similar comment
please provide more information:
|
seems something is missing: when@dev_api: *dev but the problem does not come from here I think when I was talking about please also could you provide a full stacktrace? (add |
I want to change the environment type inside the bundle instead of changing it for the whole project, I tried to change it in .env to "dev" and it worked, I'm creating factories successfully but if I want to do it the other way around it doesn't work. |
not sure what you mean here? why do you want to achieve this? the environment is set for the whole app, not at bundle's level. the error is weird: it seems the app does not load Foundry's config 🤔 |
I just want the bundle to work in the dev_api environment, somewhow at the bundle's level, it's not getting the dev_api environment, it's getting dev |
yes, but it really not sounds like a Foundry problem: the bundle is agnostic of the app's environment. maybe it would help if you can create a public reproducerr |
I have two different development environments (dev/dev_api) and when I change the environment in config/bundles.php and in package yaml file I got this error below:
CODE:
bundles.php
return [ Zenstruck\Foundry\ZenstruckFoundryBundle::class => ['dev_api' => true, 'test' => true], ];
zenstruck_foundry.yaml
when@dev: &dev_api zenstruck_foundry: auto_refresh_proxies: true when@test: *dev_api
Error:
![image](https://private-user-images.githubusercontent.com/87384147/253967505-d3d4409a-a22b-49e0-983d-90b5a0a5a1a2.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjE3NTQ2OTQsIm5iZiI6MTcyMTc1NDM5NCwicGF0aCI6Ii84NzM4NDE0Ny8yNTM5Njc1MDUtZDNkNDQwOWEtYTIyYi00OWUwLTk4M2QtOTBiNWEwYTVhMWEyLnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA3MjMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNzIzVDE3MDYzNFomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTU5YjgwYzlmMTk5OTQzN2QxOWYxN2JlZDVjMzFmMGZlNTExMmM1NTdiNGMyYjdhNmUyY2VhZmFjYWE0YzJkMzYmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.1JjOcMmLJpUwf5rmdhachIS1NhyReseM3O9G-0MkrwM)
Version :
"zenstruck/foundry": "^1.34"
Any help please ?
The text was updated successfully, but these errors were encountered: