Skip to content

Freeze cache keys include the absolute code-root path #12

Open

Description

@apiad

ExecEnv.run keys the freeze cache on " ".join(cmd) + "|".join(self.pythonpath) plus the program (scriptorium/execute.py), and pythonpath is the code root resolved to an absolute path (render.prepare). The same book in another checkout (a git worktree, the main checkout after a merge, another machine) misses every cache entry and re-runs all code. For How to Train your Chatbot ch01 that is a 25-minute training run, and marginalia's frozen reader shows no outputs until it happens.

Wanted: key on the code root relative to the document's cwd, so .scriptorium/freeze.json is portable and can even be committed.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions