Page MenuHomePhabricator

Parsoid internal error with mw:Extension/references
Closed, DuplicatePublic

Description

Steps to reproduce:

  1. Go to http://parsoid-lb.eqiad.wikimedia.org/_html/
  2. Use <ol typeof="mw:Extension/references"></ol>
  3. Submit

Expect results: No error
Actual results: Error 503 Service Unavailable
Service Unavailable
Guru Meditation:
XID: 640881439

This breaks content translation publishing on some pages, see bug 73119


Version: unspecified
Severity: normal

Details

Reference
bz73121

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 3:56 AM
bzimport added a project: Parsoid.
bzimport set Reference to bz73121.

We actually require an about id and a data-mw for extension content. I just noticed there is a minor gap in our spec for the references extension (that section show the data-mw for the references block in <ol>). However, all transclusions and extensions do show data-mw.

I'll fix this.

But, we would need this for it to serialize properly.

<ol class="references" typeof="mw:Extension/references" about="#mwt2" data-mw='{"name":"references","attrs":{}}'></ol>

We should perhaps not throw a 503 and instead ignore this and generate an error message perhaps. We'll discuss that internally.

We could also perhaps tweak our serializer to infer empty attributes from the typeof and generate a self-closing empty tag. To be investigated.

But, if you your content translation engine to publish the data-mw and about attributes, it should work.

Even if the issue has been solved in the Content Translation tool by keeping data-mw, I've uploaded a patch that logs an error instead of returning 503 in this case: https://gerrit.wikimedia.org/r/#/c/176950/ .