Page MenuHomePhabricator

Improperly stripping out parenthetical content in share a fact
Closed, InvalidPublic2 Estimated Story Points

Description

#shareafact #sharing TextExtracts

Steps to reproduce:

  1. Go to the "Foobar" page
  2. Select text from the lead sentence
  3. Click share (either the text action or bottom toolbar)

Expected results

"(and alternatively qux)" is included in the shared text

Actual results

Parenthetical content is stripped out:

selection.png (1×750 px, 592 KB)

bad selection.png (1×750 px, 717 KB)

Event Timeline

BGerstle-WMF raised the priority of this task from to Needs Triage.
BGerstle-WMF updated the task description. (Show Details)
BGerstle-WMF moved this task to Bug Backlog on the Wikipedia-iOS-App-Backlog board.
BGerstle-WMF subscribed.
BGerstle-WMF renamed this task from [4.1.3 (122)] Improperly stripping out parenthetical content to 4.1.3 (122) Improperly stripping out parenthetical content.May 12 2015, 4:30 PM
BGerstle-WMF set Security to None.
BGerstle-WMF updated the task description. (Show Details)

To be clear, this is a client-side bug. Could be fixed by using TextExtracts API:

# response from: http://en.wikipedia.org/w/api.php?action=query&prop=extracts&exchars=175&titles=Foobar&explaintext
{
    "query": {
        "pages": {
            "11178": {
                "pageid": 11178,
                "ns": 0,
                "title": "Foobar",
                "extract": "The terms foobar (/\u02c8fu\u02d0b\u0251r/), fubar, or foo, bar, baz and qux (alternatively, quux) and sometimes norf and many others are sometimes used as placeholder names (also referred to..."
            }
        }
    }
}
Fjalapeno renamed this task from 4.1.3 (122) Improperly stripping out parenthetical content to 4.1.3 (122) Improperly stripping out parenthetical content in share a fact.Jul 6 2015, 12:06 AM
JMinor renamed this task from 4.1.3 (122) Improperly stripping out parenthetical content in share a fact to Improperly stripping out parenthetical content in share a fact.May 9 2016, 7:07 PM
JMinor triaged this task as Low priority.
JMinor added a project: iOS-app-Bugs.

May want to ping @dr0ptp4kt for context on why certain things are stripped.

Clarification - we should attempt to do this locally with the HTML rather than using an API to get clean text

I don't remember all of the history of this, although I believe the aggressive text filtering was only applied for a default share card (now no longer an option IIRC?), not a user initiated text selection share.

Fjalapeno set the point value for this task to 1.Jun 20 2016, 3:36 PM
Fjalapeno changed the point value for this task from 1 to 2.Jun 21 2016, 2:59 PM

@Fjalapeno I can reproduce the issue with a latest version downloaded from App Store, which is not the case for our develop build. The context menu had been changed, and by clicking neither 'Share...' nor 'Share-a-fact' could I reproduce it.

IMG_3226.PNG (1×750 px, 168 KB)

Can no longer repro.