Skip to content

Netlify deploy error due to unresolved JSON import in Vite build#2

Open
netlify-coding[bot] wants to merge 1 commit into
mainfrom
agent-import-in-vite-build-1ddd
Open

Netlify deploy error due to unresolved JSON import in Vite build#2
netlify-coding[bot] wants to merge 1 commit into
mainfrom
agent-import-in-vite-build-1ddd

Conversation

@netlify-coding

Copy link
Copy Markdown

🔗 View agent run: https://app.netlify.com/projects/myrecoveryspokane/agent-runs/6a0a5de2fbbca0e8cf1a1ddd

🤖 Agent: Claude

💬 Prompt: The Netlify deploy errored, with the following guidance provided:

Diagnosis

  • Relevant error lines: the build command that ran is shown at #L51 and the failure is "Could not resolve '../../firebase-applet-config.json' from 'src/lib/firebase....

Result: The Netlify build was failing because src/lib/firebase.ts imported Firebase configuration from a local JSON file (../../firebase-applet-config.json) that was never committed to the repository. Rollup (used by Vite) could not resolve this import at build time, causing the build to exit with a non-zero status.

The file already read Firebase credentials from VITE_FIREBASE_* environment variables as its primary source, with the missing JSON file as a fallback. The fix removes the JSON import entirely and uses only the environment variables, which is the correct approach for keeping secrets out of source control. The following variables must be set in the Netlify environment for the app to function:

  • VITE_FIREBASE_API_KEY
  • VITE_FIREBASE_AUTH_DOMAIN
  • VITE_FIREBASE_PROJECT_ID
  • VITE_FIREBASE_STORAGE_BUCKET
  • VITE_FIREBASE_MESSAGING_SENDER_ID
  • VITE_FIREBASE_APP_ID
  • VITE_FIREBASE_MEASUREMENT_ID
  • VITE_FIREBASE_FIRESTORE_DATABASE_ID

No other files were changed.

@netlify

netlify Bot commented May 18, 2026

Copy link
Copy Markdown

Deploy Preview for myrecoveryspokane ready!

Name Link
🔨 Latest commit d6c2e00
🔍 Latest deploy log https://app.netlify.com/projects/myrecoveryspokane/deploys/6a0a5eb66aec6f00082cd201
😎 Deploy Preview https://deploy-preview-2--myrecoveryspokane.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

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

Successfully merging this pull request may close these issues.

2 participants