writethedocs / www

The main website for Write the Docs.
http://www.writethedocs.org
Other
1.3k stars 503 forks source link

Refactor talk video pages (again) #2160

Open plaindocs opened 4 weeks ago

plaindocs commented 4 weeks ago

We used to generate all the video pages on the fly. And the build took ages, so we only build videos specifically if you turn it on, or on deployment.

Now we generate page stubs outside of the usual build, and commit the result. Although the stubs still load data from the YAML files. :man_shrugging:

Running a clean build on my laptop without building videos:

real    1m42.046s
user    4m42.646s
sys 0m10.230s

Running a clean build on my laptop building videos:

real    2m43.086s
user    7m35.735s
sys 0m11.698s

It's slower, but is it slower enough for the extra logic? @mxsasha

plaindocs commented 4 weeks ago

If we want to keep the current method, we could also write the entire page instead of using

A Year in the Life of The Better Docs Project
=============================================

.. datatemplate-video::
   :source: /_data/2018.prague.speakers.yaml
   :template: videos/video-detail.html
   :key: 3

which would presumably be faster?