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

please remember increasing versionCode for each release #9

Closed
IzzySoft opened this issue Apr 19, 2021 · 4 comments
Closed

please remember increasing versionCode for each release #9

IzzySoft opened this issue Apr 19, 2021 · 4 comments

Comments

@IzzySoft
Copy link

Just to notify you: todays v1.1.3 identifies with versionCode: 1001 – the same versionCode v1.0.2 already had, so Android will not accept it as update. Please remember to always increase versionCode with each new release πŸ˜‰ Thanks!

@JobinBiju
Copy link
Owner

JobinBiju commented Apr 20, 2021

@IzzySoft I already changed the version number in pubspec.yaml & the app updated just fine. Please elaborate your issue so that I can look into it.

@IzzySoft
Copy link
Author

Just take the two APKs from releases and run aapt d badging against them. You'll see they both report the very same versionCode. Your pubspec.yaml sets versionCode to 1, which is the initial one:

version: 1.1.3+1

so you need to increase the value following the +. It seems with your configuration, something is just adding 1000 to it. So if for the next version you make this e.g.

version: 1.1.4+4

(assuming it will be v1.1.4 – and I've picked the 4 as it's your 4th release then), it should be fine: the 1000 gets added again turning it into a 1004, which is higher than 1001 and thus accepted as update by Android. Cross-checking the resulting APK cannot hurt, though – as pointed out, aapt d badging *.apk does the trick. The values you're after should be at the very beginning of the output, and you could eg grep for versionCode.

@JobinBiju
Copy link
Owner

Thanks for the info @IzzySoft. I have only changed the version_name and didn't change the version_code. I edited the release just now. I tried updating the app before this and it worked just fine. Anyway, I'll update the version codes from now on.

@IzzySoft
Copy link
Author

Thanks! Looking forward to the next release then.

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

No branches or pull requests

2 participants