Page MenuHomePhabricator

Paragraph wrapping bug when inline tags wrap block tags
Closed, ResolvedPublic


In 8a7195d6b9557cc57061d18d5a643a424ff44f72, as part of the fix for T66901: Paragraph wrapping bug, I introduced a bug for the following test case:

[subbu@earth parsoid] echo '<span><div>x</div></span>' | parse.js --normalize

whereas PHP Parser + tidy combo only generates


The p-tags are introduce only when there is content after the <span> or before the </span> tags. So, my p-wrapper fix overreached a bit.

This is now introducing another set of false positives in T176363

Event Timeline

ssastry triaged this task as High priority.Sep 29 2017, 9:14 PM
ssastry added a project: Parsoid.

Change 381518 had a related patch set uploaded (by Subramanya Sastry; owner: Subramanya Sastry):
[mediawiki/services/parsoid@master] Apply removeUselessPWrappers to all tags except void tags

Change 381518 merged by jenkins-bot:
[mediawiki/services/parsoid@master] P-wrapper: Generalize removal of useless p-wrappers