Skip to content

potential bug: commits intermittently marked as detached #1402

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
kshiftw opened this issue May 1, 2025 · 2 comments
Open

potential bug: commits intermittently marked as detached #1402

kshiftw opened this issue May 1, 2025 · 2 comments

Comments

@kshiftw
Copy link

kshiftw commented May 1, 2025

TL;DR
We are running a shipit instance wrapped around the shipit-engine gem v0.38.0. Starting on April 7, 2025, we have seen that commits are intermittently being marked as detached and as a result, not display on Shipit UI as an undeployed commit. I was wondering if the shipit-engine team has seen anything like this as well?

Details

  • I still haven't been able to figure out why these are being marked as detached. From what I've seen in shipit-engine code, there are a few ways that a commit will be marked as detached:
    • During GithubSyncJob, if there is a shared parent commit identified, then the children are marked as detached
      • I've used the Github REST API for commits to query the parent.sha on the detached commits' parents and children and haven't found any commits that share a parent.
    • If it is a Pull Request, then the head and base sha are marked as detached
      • The commits being marked as detached are commits merged to the master branch and not a pull request. All of our commits have NULL entries for pull_request_number merge_request_id
  • Our shipit instance wraps around shipit-engine gem v0.38.0
  • Only single commits (not 2+ in a row) are being marked as detached
  • No obvious pattern in timing for when they are marked as detached
  • Nothing has changed with our Github merge strategy - we use Squash and Merge
  • Not seeing any force pushes on the commit or on commits before it or after
  • Didn't find anything in Github change log that would cause this issue: https://github.blog/changelog/
  • This problem is not limited to a single stack - it is happening on multiple stacks that point to different repositories
  • In one example, different commits are being marked as detached for 2 stacks (staging and production) that point to the same repository and branch

Any help or insight would be appreciated! I can provide more details too, if needed.

@kshiftw
Copy link
Author

kshiftw commented May 7, 2025

@casperisfine Have you come across this before? I'm seeing different commits marked as detached for two different stacks of the same repo and branch, which makes me believe that perhaps there has been a change on the return from Github REST API that conflicts with how shipit-engine processes it.

@casperisfine
Copy link
Contributor

@casperisfine Have you come across this before?

No sorry, doesn't ring any bell. Happy to merge a fix if you figure out what the bug is though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants