-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
checkupdate after app installed,but It always rollback after restart #1564
Comments
I check some similar issues,But just doesn't work!
|
Hey @gwl002 You can just use it like this: componentDidMount(){
codePush.notifyAppReady();
this.syncImmediate();
} |
I have the same error: "An update is available, but it is being ignored due to have been previously rolled back." codePush.checkForUpdate(function (update) {
if (update) {
var updateDialogOptions = {
updateTitle: "Actualitzacio pendent",
optionalUpdateMessage: "Vols actualitzar ara?",
optionalIgnoreButtonLabel: "No",
optionalInstallButtonLabel: "Si"
};
var syncStatus = function (status) {
console.log("SyncStatus =", status);
switch (status) {
case SyncStatus.UP_TO_DATE:
break;
case SyncStatus.UPDATE_INSTALLED:
console.log("SyncStatus.UPDATE_INSTALLED");
Utilitats.pantallaEspera(false);
codePush.restartApplication();
break;
case SyncStatus.DOWNLOADING_PACKAGE:
Utilitats.pantallaEspera(true);
console.log("SyncStatus.DOWNLOADING_PACKAGE");
break;
case SyncStatus.INSTALLING_UPDATE:
// Hide "downloading" modal
console.log("SyncStatus.INSTALLING_UPDATE");
break;
case SyncStatus.ERROR:
// Hide "downloading" modal
console.log("SyncStatus.ERROR");
Utilitats.pantallaEspera(false);
break;
}
};
codePush.sync(syncStatus, { updateDialog: updateDialogOptions });
}
}) |
There is a good comment on how rollbacks work. You need to wrap your App in |
Hi @gwl002, I'm going to close this issue for now as I haven't heard from you in a while, unfortunately. I hope your issue is resolved! |
Same issue in android in react native version 0.60.4. |
Same issue in iOS in react native v0.61.5 |
Same issue on Android and iOS on 0.61.5 |
Same issue on both platforms. Updates with |
Same issue on Android 0.59.9 |
any updates? |
Same issue here. Any updates? |
Same issue on android, any update? |
Same issue on both platform. Any solution????? |
We are also having this issue on Android with RN 0.63.4 |
We are also having the same issue on IOS with React Native 0.63.4 Did anyone resolved this issue or know why this is happening? |
Same issue on both platform with ionic cordova. Any solution??? |
Still the same issue with latest CodePush / ReactNative |
Same issue , Please reopen this ticket |
Same issue on codepush version 7.0.4 |
Same here |
for me, that because i forgot to setup at the native side https://github.com/microsoft/react-native-code-push/blob/master/docs/setup-ios.md |
Thanks so much for filing an issue or feature request! Please fill out the following (wherever relevant):
Steps to Reproduce
1.First open the app,It works fine.Check update and downloading the new version,and then restart,show the newest content successfully.
2. However, quit the app and restart,then the logcat shows "An update is available, but it is being ignored due to having been previously rolled back."
Expected Behavior
What you expected to happen?
The second time the app start the checkUpdate function should return null
Actual Behavior
What actually happens?
The checkUpdate function return a obj with info about the newest version.
Reproducible Demo
Examples
folder runnode create-app.js appName react-native@0.47.1 react-native-code-push@5.0.0-beta
command to generate plain CodePushified React Native app. Please see description on top ofcreate-app.js
file content if neededEnvironment
5.6.0,
0.58.6,
android
release
android phone
`
export default class BoardingScreen extends React.Component {
static navigationOptions = {
header:null
};
}
`
(The more info the faster we will be able to address it!)
The text was updated successfully, but these errors were encountered: