Troubleshooting center
Something broke?
Start here.
Problems organised by where they happen — from installation to networking. Each entry explains the cause, the fix, and the exact commands to run.
Installation
'node' or 'npm' is not recognized
Node.js is not installed, or your terminal was opened before installation finished so PATH was not refreshed.
Install Node.js LTS, then close every terminal (and your editor) and open a new one.
node -vnpm -vInstaller fails with "not enough space"
The SDK, system images and emulator need 15 GB or more.
Free space or install the SDK to another drive via Android Studio → Settings → Android SDK Location.
Tool Problems
SDK location not found. Define ANDROID_HOME
The ANDROID_HOME environment variable is missing.
Set ANDROID_HOME to your SDK folder and add platform-tools to PATH. See the SDK setup guide.
echo $ANDROID_HOMEadb --versionOn Windows the SDK is usually at C:\Users\<you>\AppData\Local\Android\Sdk
Build Errors
"Missing script: reset-project"
You are not inside the project folder, or your template has no reset script.
cd into the project folder, then list the available scripts.
cd my-team-appnpm run'npxexpo' is not recognized
A missing space.
It is two words — npx expo start.
npx expo startPort 8081 is already in use
Another Metro server is still running (often in a forgotten terminal tab).
Stop the other server with Ctrl + C, or free the port.
npx kill-port 8081Unable to resolve module …
A package is not installed, or an import path is misspelled (paths are case-sensitive).
Check the import path. If it is a package, install it and restart with a clean cache.
npx expo install <package>npx expo start -cRuntime Errors
Red error screen on launch
A JavaScript error was thrown while rendering.
Read the first line — it names the error and the file. Tap the stack trace to jump to the exact line.
TypeError: undefined is not an object
You accessed a property of a value that hasn't loaded yet — typically API data on first render.
Guard with optional chaining (data?.items) or render a loading state until data exists.
Emulator Problems
Emulator is very slow or refuses to start
Hardware virtualisation is disabled.
Enable VT-x / AMD-V in BIOS/UEFI. On Windows, enable "Windows Hypervisor Platform" in Windows Features.
adb shows the emulator as "offline"
The ADB server lost connection.
Restart the ADB server.
adb kill-serveradb start-serveradb devices"Project is incompatible with this version of Expo Go"
Expo Go only supports one Expo SDK version at a time.
Update Expo Go from the store. Check your project SDK version.
npx expo --versionnpx expo install --fixExpo Go can't connect to the dev server
Phone and laptop on different networks, or campus Wi-Fi blocks device-to-device traffic.
Use the same network, or tunnel mode. Or press a to use the Android emulator.
npx expo start --tunnelGit Problems
"Authentication failed" on git push
GitHub no longer accepts account passwords over HTTPS.
Sign in with the GitHub CLI or Git Credential Manager, or use a personal access token.
gh auth login"error: remote origin already exists"
Point origin at the correct URL instead of adding it again.
git remote -vgit remote set-url origin <repository-url>"error: src refspec main does not match any"
No commit yet, or the branch is not named main.
Commit first, then rename the branch and push.
git add .git commit -m "First commit"git branch -M maingit push -u origin main"Updates were rejected because the remote contains work that you do not have"
A teammate pushed first.
Pull their changes, then push again.
git pull --rebasegit push403 / "Permission denied" when pushing to the team repo
You are not a collaborator yet, or you have not accepted the invite.
The repo owner adds you in Settings → Collaborators. Accept the email invite, then push again.
I committed on main instead of my branch
Create your branch from here (it keeps the commit), push it, and ask the leader not to push main until you merge.
git switch -c <your-name>git push -u origin <your-name>CONFLICT (content) — merge conflict
The same lines changed on both sides.
Open the files marked as conflicted, choose which changes to keep, remove the <<<<<<< ======= >>>>>>> markers, then stage and commit.
git statusgit add <file>git commitNetworking / API Problems
"Network request failed" when calling a local API
On a phone or emulator, "localhost" points to the device itself, not your computer.
Use your computer's LAN IP (e.g. 192.168.1.20), or 10.0.2.2 from the Android emulator. Make sure the server listens on 0.0.0.0.
ipconfigHTTP request blocked on Android
Android blocks plain http:// traffic by default.
Use https:// endpoints. For local development only, allow cleartext in the app config.
No results found.
Nothing matches that error yet. Try fewer words, or ask on the course forum and we'll add it here.
