• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

wikimedia / parsoid / 1818 / 2
85%
master: 85%

Build:
DEFAULT BRANCH: master
Ran 27 Feb 2018 07:35PM UTC
Files 86
Run time 5s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

27 Feb 2018 07:25PM UTC coverage: 86.077% (+0.008%) from 86.069%
1818.2

push

travis-ci

jenkins-bot
Don't process token attributes unnecessarily

* The async flag is false in AttributeTransformManager only when the
  attributes of the token being processed won't get updated or expanded.

* Given that, there is no reason going async and then rebuilding
  new attributes. Based on some logging, I found that > 60% of tokens
  went through buildExpandedAttrs even though ~1% of all tokens
  actually got their attributes updated.

  Accordingly, juggled around some yield/async logic to bypass the
  buildExpandedAttrs method altogether where possible.

* Eliminated unnecessary promise creation from the common case path
  where the attributes come through unchanged. So, I moved back from
  async/yield to promises in AttributeExpander.onToken
  (and TemplateHandler.onTemplate just to be consistent).

* Together, the previous two optimizations lead to significant perf
  improvement.

  On enwiki:Berlin, went from 8.3s -> 8.1s -> 7.9s on my laptop

  parserTests complete faster as well.

* There is another source of inefficiency lurking around still that will be
  addressed later. While the 60% of tokens now bypass buildExpandedAttrs,
  they still go through AttributeTransformManager.process and build a new
  key-value array that is not actually used. It would be useful to skip
  that as well in a subsequent patch.

Change-Id: I2e8d90dcc

8910 of 10955 branches covered (81.33%)

14250 of 16555 relevant lines covered (86.08%)

25512.21 hits per line

Source Files on job 1818.2
  • Tree
  • List 0
  • Changed 31
  • Source Changed 3
  • Coverage Changed 31
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses
  • Back to Build 1
  • Travis Job 1818.2
  • 0c3abce0 on github
  • Prev Job for on master (#1817.1)
  • Next Job for on master (#1819.4)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc