Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More speedups of doc workflow #710

Merged
merged 1 commit into from
Feb 25, 2022

Conversation

sparkiegeek
Copy link
Contributor

More efforts on #559

Done

  • Use fast-path for reading redirects table.
  • Avoid str(soup) if we're on the fast-path.
  • Only create the notification template if we need it (we don't for
    the index document)

All of these combined give a speed-up of parsing MAAS' index topic
from ~0.75s to ~0.6s on my machine (reading an on-disk version of the index)

QA

Confirmed exact same behaviour for MAAS docs

Issue / Card

#559

Screenshots

More efforts on canonical#559

* Use fast-path for reading redirects table.
* Avoid str(soup) if we're on the fast-path.
* Only create the notification template if we need it (we don't for
the index document)

All of these combined give a speed-up of parsing MAAS' index topic
from ~0.75s to ~0.6s on my machine (reading an on-disk version of the index)
@webteam-app
Copy link

Demo starting at https://maas-io-710.demos.haus

@sparkiegeek sparkiegeek added python Pull requests that update Python code Review: Code needed labels Feb 24, 2022
@codecov
Copy link

codecov bot commented Feb 24, 2022

Codecov Report

Merging #710 (1dd1502) into main (662276e) will decrease coverage by 0.05%.
The diff coverage is 65.71%.

❗ Current head 1dd1502 differs from pull request most recent head 7699247. Consider uploading reports for the commit 7699247 to get more accurate results

Impacted Files Coverage Δ
webapp/doc_parser.py 65.71% <65.71%> (-0.66%) ⬇️

Copy link
Contributor

@jkfran jkfran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! 👍🏽

@sparkiegeek sparkiegeek merged commit 695538a into canonical:main Feb 25, 2022
@sparkiegeek sparkiegeek deleted the doc-speedups-next branch February 25, 2022 10:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
python Pull requests that update Python code Review: Code needed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants