Closed RishabhKarnad closed 5 months ago
Hi @RishabhKarnad! I opened PR: https://github.com/microsoft/appcenter-cli/pull/1115 with a fix for this issue. Take a look if you have time.
Hello,
We also experience this issue for some builds in our CI. Sometimes, the builds silently fails, and the faulty bundle is sent to AppCenter.
I think I know where the issue comes from:
The check to assert if the subprocess has failed is: https://github.com/microsoft/appcenter-cli/blob/ada80998fdbd46657ea9cb1b8d04d3264a93953a/src/commands/codepush/lib/react-native-utils.ts#L342
However, if the process is killed, exitCode
will be null
(and signal
will be non-null
)
References:
Opened #2004 as an attempt to fix this issue.
When running the
codepush release-react
subcommand, if there is a failure when creating the React Native bundle due to a lack of heap space in the node process, a release is still created.Steps to reproduce:
CODE_PUSH_NODE_ARGS
to reduce node max_old_space_size to a small enough number, so that the bundler runs out of memory. e.g.export CODE_PUSH_NODE_ARGS='--max_old_space_size=256'
appcenter codepush release-react
. e.g.appcenter codepush release-react -a <appName> -d <deployment>
Expected result
Since the bundler fails, a release should not be created
Actual result
A release is created. This causes CI builds to pass. The size of the bundle is only a few bytes and results in a crash and rollback when installed in the RN app.
react-native version
0.62
react-native-code-push version
6.2.0
Example logs
Release details in AppCenter dashboard