Skip to content

sl fails on shallow checkouts #998

Open
@stepancheg

Description

@stepancheg

Repro

$ git clone https://github.com/protocolbuffers/protobuf --depth 1
...
$ sl
reposetup failed in extension dirsync: When constructing alloc::boxed::Box<dyn commits_trait::DagCommits + core::marker::Send> from dyn storemodel::StoreInfo, "10-git-commits" reported error

Caused by:
    0: resolving 0fba21ab2187d1f9cb64041ec7c19c5286821049 to git commit
    1: object not found - no match for id (0fba21ab2187d1f9cb64041ec7c19c5286821049); class=Odb (9); code=NotFound (-3)
abort: When constructing alloc::boxed::Box<dyn commits_trait::DagCommits + core::marker::Send> from dyn storemodel::StoreInfo, "10-git-commits" reported error

Caused by:
    0: resolving 0fba21ab2187d1f9cb64041ec7c19c5286821049 to git commit
    1: object not found - no match for id (0fba21ab2187d1f9cb64041ec7c19c5286821049); class=Odb (9); code=NotFound (-3)
$ git fetch --unshallow
...
$ sl
@  21e9aa6cac  Yesterday at 22:04  tonyliaoss  origin/main
│  Add back UPB test coverage that was undone from test migration.
~

sl does not necessary have to support shallow clones, but it could provide a nice message with suggestion to git fetch --unshallow.

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