On Tue, 12 Jan 2021 at 14:31, Matti Picus <matti...@gmail.com
> Why do code blocks get their own unique "anchor_ref = 'rest_code_' + uuid.uuid4().hex" ref? I would like to have a reproducable build. Could we use a random.randint(0, 0xffff) instead and then random.seed(n) could be set at the beginning of the build.
Lines in a code block must have unique anchors on all pages they
appear on. A UUID guarantees no collisions and requires no special
state tracking. An alternate and more deterministic solution would
need to take the full input file name into account, and keep track of
the number of code blocks already rendered — perhaps doable, but
requires more work, and might be ugly/expose internal details.
Why do you want a reproducible build?
Chris Warrick <https://chriswarrick.com/