Hi Community,
I’m encountering an issue with my Vercel deployment, and I hope someone here can help me troubleshoot this.
Problem Description:
I’ve made updates to my GitHub repository (marketec/review-manager
) and pushed the changes to the branch linked to my Vercel project. However, when I click Redeploy on Vercel, it seems to be pulling an older commit instead of using the latest changes from the repository. This results in a failed deployment with the following error:
lua
Copy code
Failed to compile.
./comparison/src_profile.ts:3:29
Type error: Cannot find module '../auth/[...nextauth]' or its corresponding type declarations.
What I’ve Tried So Far:
- Checked GitHub Repository Updates:
- Verified that my repository is up-to-date with the correct changes by running:
bash
Copy code
git log --oneline
- Confirmed that the latest commit is pushed to the main branch.
- Confirmed Vercel Git Settings:
- Checked the connected repository in Vercel under Settings > Git. It is correctly linked to
marketec/review-manager
on GitHub.
- Cleared Build Cache:
- Enabled Clear Build Cache in Settings > Build & Development Settings before triggering a redeploy.
- Manually Triggered Deployment:
- Pushed an empty commit to force a redeploy:
bash
Copy code
git commit --allow-empty -m "Trigger redeploy"
git push
- Reverted/Reset Commits:
- Tried reverting the problematic commit and resetting the branch to a known good state. Then, I pushed the changes:
bash
Copy code
git reset --hard <correct-commit-hash>
git push origin main --force
Main Issue:
Despite all these steps, the redeployment on Vercel still pulls an older commit instead of the latest commit from the linked branch. I suspect something is cached or misconfigured on Vercel’s side, but I’m not sure how to fix it.