CircleCIのジョブが下記のエラーで失敗していた。

Either git or ssh (required by git to clone through SSH) is not installed in the image. Falling back to CircleCI's native git client but the behavior may be different from official git. If this is an issue, please use an image that has official git and ssh installed.

Enumerating objects: 208, done.
Counting objects: 100% (208/208), done.
Compressing objects: 100% (135/135), done.
Total 1015 (delta 130), reused 134 (delta 61), pack-reused 807

reference not found

git cloneで「reference not found」になっている。イメージにGitクライアントがインストールされておらず、CircleCIネイティブのGitクライアントにフォールバックしたものの、おそらくその実装に問題があるためエラーになったのだろう。

エラーメッセージにあるとおり、公式のGitが入ったイメージを使えば解決しそうだ。

これまでは下記のように「docker」イメージを指定していた。

    docker:
      - image: docker

これを、Git入りのイメージに変えたところ、ジョブが成功した。

    docker:
      - image: docker:git

今まで失敗しなかったのは、たまたま運がよかったのだろう。