DEV Community

forkcount
forkcount

Posted on

I Spent 3 Days Debugging a Deploy That Was Never Deploying. Here's the Checklist That Fixed It.

Three days. That's how long I spent pushing fixes to a GitHub Pages site that never changed.

Every push succeeded. Every workflow showed green. Every fix worked in my dev environment. And every single time I opened the live URL, the same console error stared back at me:

Failed to load module script: Expected a JavaScript-or-Wasm module script but the server responded with a MIME type of "application/octet-stream"

I'm 13. I built a calorie tracker called ForkCount using AI Studio. The app worked. The deploy didn't. And the worst part wasn't the error — it was that I couldn't tell whether my fixes were failing or whether they were never reaching the browser at all.

Day one, I blamed the build. I rebuilt locally, checked the output, saw that the script tag pointed to a real .js file. The build was fine.

Day two, I blamed GitHub Actions. The workflow looked correct. Green checkmarks everywhere. But the live site was still serving source files instead of the built ones. I didn't understand how both could be true at once.

Day three, I opened my own repo and looked at the docs/ folder. It had assets, it had a .nojekyll file, it had a manifest. It did not have an index.html. The folder I was deploying from was empty of the one file that mattered. GitHub Pages was serving a 404, which fell back to the repo root, which contained my raw source files with /src/main.tsx — a file no browser can execute.

That was the bug. Not the code. Not the workflow. A missing file in a folder I'd looked at ten times without seeing what was absent.

The fix took four commands. Build, copy, add the missing file, push. Three days of debugging ended with a solution so simple I felt stupid for not finding it sooner.

But here's what I actually learned, and it has nothing to do with GitHub Pages:

When something breaks and the fix doesn't work, the first question isn't "what's wrong with the fix?" It's "did the fix actually arrive?" I spent two days debugging code that was never running. Every prompt I sent to my AI assistant went to the source. The source was fine. The source was never the problem.

If you're building something and it keeps failing after every fix, check the layer between your code and your user. Look at what's actually being served, not what you think you deployed. View source. Check the hash. Open the folder. Count the files.

The AI can write the code. It can't see your screen. When something breaks, you have to be the one who notices where the break is.

ForkCount is live now at forkcount.github.io. Free, no card, no trial. I built it because every calorie app I tried hid the math behind a paywall. It still has bugs. But the deploy works, and I know how to check it.

Top comments (0)