Closed mdbenito closed 7 months ago
Attention: Patch coverage is 55.55556%
with 4 lines
in your changes are missing coverage. Please review.
Project coverage is 96.20%. Comparing base (
1496fab
) to head (696189d
). Report is 4 commits behind head on main.
Files | Patch % | Lines |
---|---|---|
src/mkdocs_bibtex/plugin.py | 55.55% | 4 Missing :warning: |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@shyamd I see the errors. Sorry about that. I'll look into it and get back to you
Thanks for all these performance improvements and no worries on the failing tests. Took me awhile to turn on tests for your PRs.
I re-named the attribute that you used for holding the last config time. The fact that it wasn't throwing an AttributeError
tells me that mkdocs
was already using it. This new attribute throws an AttributeError
if you don't use the hasattr
guard, which is what we'd hope.
Thanks for all these performance improvements. Next minor version bump will include them.
My pleasure. Thank you for the plugin!
This PR is a continuation to #238.
on_startup()
to avoid unloading the plugin when usingmkdocs serve
.on_config()
by storing thetime()
of the first run, then checking the timestamps of the bibtex files passed by the user. If any file is newer all refs are read again.The speedup is only noticeable after merging #238, but with both PRs together, our re-build using
mkdocs serve
goes from ~41secs to ~25 secs, or a 40% total reduction in build time. This makes working on documentation much nicer :)