-
Notifications
You must be signed in to change notification settings - Fork 152
Play store changes => StateError: Bad state: No element #107
Comments
Yes looks like it, thanks for reporting. This will probably break the plugin until I determine the new HTML elements. |
Looks like they are rolling it out gradually? Right now I see the old play store in my browser again. |
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as duplicate.
This comment was marked as duplicate.
@timtraversy So apparently the store changed for more users. Any idea how to proceed? I looked a bit into it myself, but getting the version from the HTML page itself seems more difficult because it doesn't appear in the source code on a page load anymore. It's all javascript-driven it seems. Also: what if they decide to change a class name anytime soon again? Is there is more robust option to get the latest version of an app? |
@peterhijma final additionalInfoElements = document.getElementsByClassName('hAyfc'); This class is not found. beacuse google has changed design of play store. |
This comment was marked as off-topic.
This comment was marked as off-topic.
Unfortunately, there is not an easy fix for this. The new Play Store listing design does not include the app version number. For example: There may be some other site where the version is listed, but someone will have to find it. |
This comment was marked as duplicate.
This comment was marked as duplicate.
In section „about this app“ is the version. Does this help? |
Good catch. That's closer, but that HTML element is only shown after a Javascript function is triggered, so we wouldn't be able to scrape it with a simple HTTP request as we do now. It looks like the version info is pre-fetched though, and hidden in a huge block of in-line JS. So there might be a way to scrape out of there. But who knows if the format they return it in will be consistent. |
https://pub.dev/packages/webdriver is a possibility. Right now, I'm leaning towards turning off Android support and releasing a version without it. But I'll give it another day to see if anything comes up. |
If anyone is up for a challenge:
That's probably the only way. |
JavaScript Code
@timtraversy can u check it out ?.. Java code
|
For me, some changes in _getAndroidStoreVersion worked.
Still not sure if play store HTML will be consistent or not but it worked for now. |
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
To those this is breaking: you will have to release a new version of your apps to fix this issue. I would recommend just doing that now, and removing the calls to this plugin. This was an unforseen change in the Play Console, we're working on a fix. |
Nice concepts above, thank you! @prakasharyaman - This is a clever idea, but people format there versions different ways. Also, the HTML contains multiple version strings from past versions, so we would have to add some logic to fix that as well. @ankitpanwar8979 - This is my preferred solution. The nested array doesn't seem like it will remain stable as the Play site changes, but best we can do for now. |
can u explain code _getCleanVersion is what for? |
Try ThisWorks for now
|
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
Check this function new_version/lib/new_version.dart Line 117 in a71a9b8
|
I have a similar package and am using regex to get the version from the play store you can check it here newVersion = RegExp(r',\[\[\["([0-9,\.]*)"]],') |
Facing same issue since few days and this has broken our force update functionality on android. Can we expect this issue to be resolved in upcoming plugin version? |
But I am using the same package in my app which is already in playstore. If we are using any other package then we loose the old users. |
in both ways, you will update your app because even if they fixed this problem the package will not be fixed automatically on the app on play store you will need to update it |
This is my code.
|
I don't have the environment set up to test it, but |
Google Play store looks very different since yesterday or today?
I've got some error messages popping up now.
So I think changes are necessary. You can find the version of the app in a modal @ "About this app ->"
The text was updated successfully, but these errors were encountered: