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 update documentation on how to use the plugin #3

Open
tahirQaiser opened this issue Aug 20, 2020 · 17 comments
Open

Please update documentation on how to use the plugin #3

tahirQaiser opened this issue Aug 20, 2020 · 17 comments

Comments

@tahirQaiser
Copy link

Currently, this plugin is not much documented, For a Junior Developer like me, if the plugin has good documentation it would be easy to use.
Can you please document it properly ? Like how to use In App Updates ? How to use Flexible & Immediate updates using this plugin ?

@dpogue
Copy link
Member

dpogue commented Aug 20, 2020

Hi @rajatahirqaiser, thanks for pointing out gaps in the current documentation. I will try to update the README with more details in the next few days.
In the meantime, to try to answer some of your questions:

  • Using the plugin should be as easy as installing it into your project. There's no JavaScript API that you need to work with.
    After installing, every time the app launches it will call Siren or Play Services to check for updates, and automatically pop up an alert if a new version is available.

  • I need to do a bit more work/testing around Android flexible vs immediate updates, but all of the configuration for those happens in the Play Store API rather than the plugin. Unfortunately Google's documentation is also pretty poor at describing how to set these values using the API: https://developer.android.com/guide/playcore/in-app-updates#check-priority

@tahirQaiser
Copy link
Author

tahirQaiser commented Aug 21, 2020

Thanks for a detailed response, For me I installed the plugin. It POP Ups as Update Available -> Download -> Installs BUT
AGAIN NEXT TIME it shows POP UP AGAIN when app is opened to download again and loop() but the app is not updated .

Can you please share step by step way to use the plugin, I am super confused

@jdpsah
Copy link

jdpsah commented Jan 6, 2021

There is no documentation on how to use it . I got it that we just need to install the plugin then all other work it will handle . But how to use flexible and immediate update ?

@dpogue
Copy link
Member

dpogue commented Jan 6, 2021

But how to use flexible and immediate update ?

On Android, you configure that per-version using the Play Store API.

On iOS, currently it does the default Siren behaviour, but there's a PR to make that configurable via config.xml.

@CheckpointAccess
Copy link

Anyone ever get this working properly on Android w/ Cordova? Documentation has still not been updated.

@tahirQaiser
Copy link
Author

@CheckpointAccess , I found this to be working without any configuration needed. This will work if app is in real time deployed to Playstore and there is no release, can't be checked in DEV

@CheckpointAccess
Copy link

@CheckpointAccess , I found this to be working without any configuration needed. This will work if app is in real time deployed to Playstore and there is no release, can't be checked in DEV

Ok thank you! I have been trying it while in testing releases, that could explain why it's not working.

@knoxwebies
Copy link

@CheckpointAccess or @rajatahirqaiser is it working when the app is in internal testing?

@tinemlakar
Copy link

Hi.
Is there a way to test this plugin (on both platforms) or it works only in production?

@abnersouza
Copy link

Hi. Is there a way to test this plugin (on both platforms) or it works only in production?

In iOS you can test using Xcode, just set the version of your app to be lower than the one you have published in the App Store. e.g if your actual version released is 1.1.0 you can run the app in the Xcode and set the version to be 1.0.0 and then open in the simulator you should see the update notifier.

One tip as well is that once you have it published, it will show the notifier when the latest version has been released for at least one day (24hrs).

For Android as far as I read it's not possible to verify when is not in production.

@tinemlakar
Copy link

tinemlakar commented Nov 24, 2021

I found this article regarding testing in android.
https://developer.android.com/guide/playcore/in-app-updates/test

One tip as well is that once you have it published, it will show the notifier when the latest version has been released for at least one day (24hrs).

Is this true for both, App Store and Google play store? I just tested in production in google play (plugin v1.0.1) and it doesn't seem to work. It hasn't been 24 h though.

@satinder1208
Copy link

Hi,
I am using it on Android 9... I deployed it in production and then made another release to the play store (on play store I can see the update button for my app)... But, for me, it is not coming with any popup or anything... any idea how to debug?

@felicienfrancois
Copy link

@satinder1208 same issue with my app on my device (pixel 5 - android 12). And it does not seems to work on other devices too with my app (so may be app related).
When debugging with logcat, it seems to always fallback in "getAppUpdateInfo: Unhandled case".
https://github.com/AyogoHealth/cordova-plugin-update-notifier/blob/main/src/android/UpdateNotifierPlugin.java#L109

To further debug, we need to add more logs

@satinder1208
Copy link

satinder1208 commented Dec 13, 2021

@felicienfrancois Just to add more info... it worked for me after 4-5 days... then it was giving me an alert every time I was opening the app until I clicked on Update. Still, I am not clear about the root cause of this delay. May the reading source is cached in the play store or something. so it works after a good time only

@alanmilinovic
Copy link

alanmilinovic commented Jan 5, 2022

Same thing on my side. I can see app on the list of pending downloads with update button in Play store app, but no popup in app itself. Will wait for some time to see if it will start to work. It is not that usefull if it is not immediate and in sync with play store.

I also removed "Enable auto-update" from the app in Play Store app to prevent automatic update of the app and test things. My app is in release track.

@dpogue
Copy link
Member

dpogue commented Jan 5, 2022

On Android, this is using Google's Play Core library which is the official flow for in-app updates. That library is responsible for all the update detection and notification, so any delays are unfortunately an issue with their library or their API 😞

@alanmilinovic
Copy link

That is a pitty, maybe they will improve it in the future.

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

No branches or pull requests

10 participants