Vercel Deployment Cloning Wrong Commit Hash

I’m experiencing a persistent issue with my Vercel project where deployments are consistently cloning an old commit hash instead of the actual latest commit from the connected GitHub repository’s main branch.

Project Details:

The Problem:

When a deployment is triggered (either automatically via a push to main or via a manual “Redeploy”), Vercel is cloning commit 8f49fee (message: “chore: force vercel deploy trigger”).

However, the actual latest commit on the main branch on GitHub is 1d9d51c (message: “fix: correct h1 tag on landing page”). This latest commit contains necessary code fixes.

Because Vercel is cloning the older commit (8f49fee), the builds are failing due to errors (specifically, a JSX syntax error in src/app/page.js) that were fixed in the subsequent commit.

Troubleshooting Steps Already Taken:

  1. Verified the latest commit ‘1d9d51c’ is visible and is the head of the main branch on GitHub.com.
  2. Experienced significant issues with the original Vercel project (stuck deployments, project duplication), leading me to delete the original project(s).
  3. Created a brand new Vercel project (ID: prj_yGENRJxYrpnvYuaf4tyTZBrkv0tH) linked to the same GitHub repository (littlenudge/littlenudge-app).
  4. Configured the new project settings (Environment Variables, Production Branch set to main).
  5. Pushed the necessary code fix (“fix: correct h1 tag…”) to the main branch after creating the new project.
  6. Attempted both automatic deployment triggers and manual “Redeploy” actions on the new project.
  7. Result: Despite all steps, the new Vercel project still clones the incorrect old commit (8f49fee) instead of the actual latest commit from main.

Could you please investigate why the Vercel Git integration for this project is not correctly identifying or fetching the latest commit hash from the main branch of the linked GitHub repository?

Link to Vercel Project: https://vercel.com/rowan-cliffords-projects/littlenudge

Thank you for your time and assistance.

Hey @littlenudge. From what I can see in the logs it looks like one initial deployment was started and then redeployed a few times (as you tried in step 6). In that case it makes sense that the same commit was used for all of the builds.

The repo is private, so I’m not able to see the new commits or whether any build errors are logged there. There could be a configuration error that prevents the build from starting at all.

Does the build run successfully if you install Vercel CLI and run vercel build on your local repo? If that succeeds you can deploy from Vercel CLI as a workaround until we figure out what’s causing the auto deployment problem for your project.

Hey @littlenudge. I haven’t heard back from you and just wanted to check if you got it working

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.