Skip to content

Failed Molot font download can leave a corrupt file that Make reuses forever #79

Description

@gemshrine

Problem

The molot-regular.ttf target downloads directly with wget -O. If the network connection fails after creating the file, wget can leave a partial font at the target path while returning a non-zero status.

Why this is a bug

On the next make invocation, the target file exists and Make skips the download, so latexmk repeatedly consumes the truncated font and fails (or embeds a broken font) even when the network is healthy again. Recovery requires manually deleting the file or running the destructive clean target.

Expected behavior

Download to a temporary file and atomically rename it only after wget succeeds (or remove a failed target in a trap), then add a failure/retry test.

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions