Missing branch inside codespace

I am running into the weird issue that I am missing a branch in a codespace. When I clone the repo locally and do a git branch -a, I see this:

* master
  remotes/origin/454de6e/issue78
  remotes/origin/HEAD -> origin/master
  remotes/origin/master

When I start a codespace from master (with HEAD being at the identical commit), I see this:

* master
  remotes/origin/HEAD -> origin/master
  remotes/origin/master

The feature branch 454de6e/issue78 is missing. Even more weird, I can launch a new codespace from branch 454de6e/issue78, but this codespace does not have a master branch.

@454de6e, we enabled shallow clone on creation yesterday to speed up creations (with a background git fetch --unshallow which should fetch all of the other history/refs), which might be related. I just disabled shallow clone while we investigate if this is related.

Thanks again for reporting the issue. I’ve identified the problem with the fetch refspec not being setup correctly in the shallow clone case and have a fix in flight. We won’t re-enable shallow clone until that fix is rolled out.

@jkeech Thanks and much appreciated. I tested it and cloning a repo now works fine.

@454de6e, I’ve deployed the fix and re-enabled shallow clone for faster creations. Can you try creating a new Codespace and let us know if you hit any unexpected issues?

I created one Codespace and so far no issues.

Not quite. See this issue: Missing GitHub Pull Requests and Issues extension. But not sure if it is related or triggered by something else.

Thanks for confirming! The extension install/visibility would not be related to shallow clone. Let’s continue the discussion for that issue on the new thread.