Skip to content

Update Android parser for new Play Store format#1044

Open
imperador wants to merge 1 commit intommatyas:masterfrom
imperador:master
Open

Update Android parser for new Play Store format#1044
imperador wants to merge 1 commit intommatyas:masterfrom
imperador:master

Conversation

@imperador
Copy link
Copy Markdown
Contributor

Updating AndroidAppsMetadata to parse latestPlay Store format

Updating AndroidAppsMetadata to parse newest Play Store format
Copy link
Copy Markdown
Owner

@mmatyas mmatyas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! I've added some comments.

, rx_background(QStringLiteral(R""(<meta property="og:image" content="(.+?)")""))
, rx_developer(QStringLiteral(R""(<a href="/store\/apps\/dev(eloper)?\?id=.+?" class=".*?">([^<]+)<\/a><\/span>)""))
, rx_category(QStringLiteral(R""(<a itemprop="genre".*?>([^<]+)<\/a>)""))
, rx_category(QStringLiteral(R""(href="\/store\/apps\/category\/([^"]+)" aria-label)""))
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems to me that the category href is uppercase; perhaps we could use the aria label instead? An example:

<a class="..." href="/store/apps/category/TOOLS" aria-label="Tools" jsname="...">

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is a good approach. What about this then:

Suggested change
, rx_category(QStringLiteral(R""(href="\/store\/apps\/category\/([^"]+)" aria-label)""))
, rx_category(QStringLiteral(R""(href="\/store\/apps\/category\/[^"]+" aria-label="(.*?)")""))

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this looks better.

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

Successfully merging this pull request may close these issues.

2 participants