Page MenuHomePhabricator

Use topic article as the source of news item primary image
Closed, ResolvedPublic

Description

Currently, the app only removes text within ( ) if it doesn't contain links. In this case, the link and the 'pictured' indication is within the ( ).

Note: story links are now ordered from the MCS. The first link can be assumed to be the primary article for the story:

https://gerrit.wikimedia.org/r/#/c/323087/5

Note, just like in the client logic, this is a best guess. If a story has multiple bold links than we can't be sure.

In the future we are trying to establish a specific HTML class to identify the primary story

Event Timeline

JoeWalsh created this task.Nov 3 2016, 1:26 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptNov 3 2016, 1:26 PM

I added a basic semantic lookup based on "pictured". Which other languages are we supporting for this feature and what would be their equivalent lookup? Anything other than "pictured" I should match on for english?

JMinor triaged this task as Low priority.Nov 10 2016, 7:11 PM
JMinor added a subscriber: JMinor.Nov 10 2016, 7:16 PM

I'd prefer to do 3, but for initial launch purposes, 2 seems best. Here are the languages we currently have news support for and their (pictured) equivalent. Note that in all cases parenthesis are used.

Swedish: (se bild)
German: (Bild)
Hebrew: (בתמונה) --> careful of RTL
Russian: (на илл.)

@JMinor what is the current task for this ticket?

Is it just for adding the additional language support? Or is it "3" where we need to do something on the MCS?

JMinor added a comment.Dec 7 2016, 1:43 AM

@Fjalapeno this update was submitted for MCS endpoint:
T148444

which identifies the main topic article for news items. This task is now to use this value to select the focus image of the news item in the iOS client. Title updated.

Note that this may still result in a mismatch between the picture and the item described as "pictured" if PageImages misfires on picking the page image.

JMinor renamed this task from [BUG] In the news image mismatches with "pictured" caption to [BUG] Use topic article as the source of news item primary image.Dec 7 2016, 1:44 AM
JMinor removed JMinor as the assignee of this task.Dec 8 2016, 7:13 PM

Once the above PR is merged we will need to update our parsing to take advantage of the API changes

JMinor added a comment.Dec 8 2016, 8:55 PM

In cases where the topic article has no image returned, we should try to get an image for any article in the news item, so there is some focus image.

Mhurd added a subscriber: Mhurd.Dec 8 2016, 8:58 PM

Per Josh's comment above, if the user taps on the following news item, which doesn't have a thumb...

The full view should probably grab an image from the first item that does have an image and use that as the main image...

Moving to next version while we wait on upstream changes.

Note: story links are now ordered from the MCS. The first link can be assumed to be the primary article for the story:

https://gerrit.wikimedia.org/r/#/c/323087/5

Note, just like in the client logic, this is a best guess. If a story has multiple bold links than we can't be sure.

In the future we are trying to establish a specific HTML class to identify the primary story

JMinor renamed this task from [BUG] Use topic article as the source of news item primary image to Use topic article as the source of news item primary image.Jan 3 2017, 10:32 PM
JMinor removed a project: iOS-app-Bugs.
JMinor updated the task description. (Show Details)Feb 23 2017, 5:21 PM
JoeWalsh claimed this task.Feb 27 2017, 4:56 PM
JoeWalsh moved this task from Ready for Development to Doing on the iOS-app-v5.4.0-Hiking-Boot board.

Testing criteria - verify that the large image that appears at the top of the news detail view matches the first item in the list.

ABorbaWMF added a subscriber: ABorbaWMF.EditedMar 3 2017, 7:20 PM

I may have picked a bad day for news items with images, but this is the behavior I am seeing on today's news items using the Beta build. When I tap on the news items that show no image, I am presented with a list of items with images. It seems like the first item in the list should populate the image on the news item, but I'm not sure that's the case.
News Items List


First 'no-image' item

Second 'no-image' item

JMinor added a comment.Mar 3 2017, 7:37 PM

So it looks like the specific issue here is fixed (the lead image of the news modal matches the image of the first article on the list). The images not loading on the feed is likely a slow network or other feed loading issue. If it persists, lets file that as a new ticket...

@JMinor I broke the feed images with the fix for this ticket. I have the fix for the broken feed images ready for code review.

Testing on iPhone 7 (iOS 10.2) and Wikipedia app 5.4.0 (1083). This is fixed as the lead image for news items match the first article in the list (in this case, Abiogenesis):

JMinor closed this task as Resolved.Mar 6 2017, 9:47 PM