You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Platform.sh create non-master environment which is child of master.
Wait for deployment and error.
Expected result
Deployment should pass and step "Updating secure and unsecure URLs in app/etc/env.php file" shouldn't break
Actual result
Getting error message on environments where deployment process has to update base_urls:
09:26:32 [2022-05-16T07:26:32.096155+00:00] INFO: Updating secure and unsecure URLs
09:26:32 [2022-05-16T07:26:32.096223+00:00] INFO: Updating secure and unsecure URLs in core_config_data table.
09:26:32 [2022-05-16T07:26:32.098462+00:00] INFO: Updating secure and unsecure URLs in app/etc/env.php file
09:26:32 [2022-05-16T07:26:32.098831+00:00] INFO: Set flag: var/.deploy_is_failed
09:26:32 [2022-05-16T07:26:32.098906+00:00] ERROR: str_replace(): Argument #3 ($subject) must be of type array|string, int given
09:26:32 [2022-05-16T07:26:32.110349+00:00] INFO: Set flag: var/.deploy_is_failed
09:26:32 W:
09:26:32 W: In Processor.php line 129:
09:26:32 W:
09:26:32 W: str_replace(): Argument #3 ($subject) must be of type array|string, int giv
09:26:32 W: en
09:26:32 W:
09:26:32 W:
09:26:32 W: In Environment.php line 94:
09:26:32 W:
09:26:32 W: str_replace(): Argument #3 ($subject) must be of type array|string, int giv
09:26:32 W: en
09:26:32 W:
09:26:32 W:
09:26:32 W: deploy
09:26:32 W:
The text was updated successfully, but these errors were encountered:
I was able to fix this issue by making sure there is a "http://{default}/" route in .magento/routes.yaml. So there is probably an issue with the MAGENTO_CLOUD_ROUTES variable.
However, I think the code should not assume anything and gracefully handle the situation (or echo an error/hint).
Preconditions
Steps to reproduce
Expected result
Actual result
09:26:32 [2022-05-16T07:26:32.096155+00:00] INFO: Updating secure and unsecure URLs
09:26:32 [2022-05-16T07:26:32.096223+00:00] INFO: Updating secure and unsecure URLs in core_config_data table.
09:26:32 [2022-05-16T07:26:32.098462+00:00] INFO: Updating secure and unsecure URLs in app/etc/env.php file
09:26:32 [2022-05-16T07:26:32.098831+00:00] INFO: Set flag: var/.deploy_is_failed
09:26:32 [2022-05-16T07:26:32.098906+00:00] ERROR: str_replace(): Argument #3 ($subject) must be of type array|string, int given
09:26:32 [2022-05-16T07:26:32.110349+00:00] INFO: Set flag: var/.deploy_is_failed
09:26:32 W:
09:26:32 W: In Processor.php line 129:
09:26:32 W:
09:26:32 W: str_replace(): Argument #3 ($subject) must be of type array|string, int giv
09:26:32 W: en
09:26:32 W:
09:26:32 W:
09:26:32 W: In Environment.php line 94:
09:26:32 W:
09:26:32 W: str_replace(): Argument #3 ($subject) must be of type array|string, int giv
09:26:32 W: en
09:26:32 W:
09:26:32 W:
09:26:32 W: deploy
09:26:32 W:
The text was updated successfully, but these errors were encountered: