Skip to content

maintenance: cache-local-objects task fails when loose object exists in cache #940

Description

A user got this error:

c:\off1\src\officemobile\android>git maintenance run --task=cache-local-objects
fatal: failed to copy '.git/objects/07/<hash>' to 'C:\.scalarCache/id_{guid}/07/<hash>': File exists

This must be hitting a lot more folks, especially those who have multiple enlistments sharing a scalar cache.

I suspect that this could be blocking some background maintenance tasks if this happens before the loose-objects or incremental-repack tasks.

It's possible that running git maintenance run --task=loose-objects (twice!) could remove the loose object from being in the way before running the cache-local-objects task again.

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