-
-
Notifications
You must be signed in to change notification settings - Fork 637
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
Add new mapping for google play changes #545
Conversation
hey! Assign @facundoolano as a reviewer please |
Hi @facundoolano |
Looks like it's work for gplay.app, but how to solve the problem of gplay.search。This function (gplay.search) always returns null list |
FYI. If you need it installed you can do:
Additionally, upgrading this broke because
|
This works - 2022/05/27 |
Hi @pvomhoff For example if you check the source of those pages: Or am I'm missing something? |
Hmm you found an interesting problem. It looks like that Google has a different mapping for some countries. To solve this issue we need to introduce multiple mapping depending on the country. Does the |
@kitsunde Makes sense. I pinned the cherrio version till the problem is fixed |
lib/app.js
Outdated
@@ -44,108 +43,243 @@ function app (opts) { | |||
|
|||
const MAPPINGS = { | |||
// FIXME add appId | |||
title: ['ds:5', 0, 0, 0], | |||
title: [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
instead of having each property an array of two elements, I suggest that you have separate mapping objects, your code choses the correct one at the beginning and the rest remains the same with whatever mapping was selected.
This will also help considering that it's not only legacy vs new but also mapping values change by country
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh good point 👍
I split the mapping in a general.v1 and in a general.v2 file. Later on we can also have different mappings by country here.
@pvomhoff i was try with your code, but the search result still return empty array |
@baguse This PR fixes the |
@pvomhoff sadly, i need the search feature too |
@pvomhoff im so sorry if maybe i spam in here, but can you help me to fix the search issue. I will donate some money if you fix that immediately. |
I suspect the rollout will be finished before this update hits npm. Yesterday I got a 100% error rate with 1857 apps. Maybe not worth keeping That said, using |
how to do "google-play-scraper": "git+https://github.com/facundoolano/google-play-scraper#pull/545/head",i dont know where to make this change |
In your You can read about how npm works here https://docs.npmjs.com/cli/v6/configuring-npm/package-json#git-urls-as-dependencies |
Hi, |
@ysb Ohh cool. I was also looking in the the list mapping. I think saw a way via an ajax call to get the top charts. |
@pvomhoff Sure, I think new pagination (batchExecute endpoint) is OK. I just need a start point for category top charts. There is a slider on category pages but it's limited with 45. There is no token for next page. |
@ysb Yeah thats exactly the AJAX endpoint i was referring to. For me it looks like that they actually limited the top charts to just 45 entries. 😞 |
@pvomhoff Yeah, I believe it should be somewhere but we couldn't find yet. I didn't get the point why they hide such a useful information for regular visitors. |
Looks like some of the list URL path construction changed too. For ex, a But the new URL on the redesign is: It seems they eliminated the collection from the path entirely. Would repairing the list construction be in scope for this PR? |
try to take this fix to my project, (and search not work, get "[]") |
I see that BASE_URL= undefined And the search does not work for me - returns an empty array |
Working good! https://github.com/pavi2410/PlayBadges |
Hi, I test this fix in an internal tool of my job and works fine!!! 👏🏻 |
Not sure if it's within the scope of this PR but search still isn't working. |
is it still works now? i got [] from both app() and list() |
Yeah still not getting back a list of apps from the query... not seeing any errors, but also not getting any data back. |
1 similar comment
Yeah still not getting back a list of apps from the query... not seeing any errors, but also not getting any data back. |
closing this as it should be fixed by #557 |
This also contains a fix for |
do you mind sending a separate PR with just that change? |
Again, any fix? |
I fixed the
gplay.app
function to be compatible with the old AND new Google Play Store Version.It looks like that Google doesnt provide all of the information as before the change.
I wasnt able to map the following properties: