Skip to content

Troubleshooting Guide

Solutions for common issues with Skigk Søkeapp.

Authentication Issues

Problem: OAuth Popup Closes Without Login

Symptoms: - Click "Logg inn med Google" - OAuth popup opens and closes - Not logged in

Solutions: 1. Check .env.local has correct VITE_GOOGLE_CLIENT_ID 2. Verify Client ID format: xxx.apps.googleusercontent.com 3. Check authorized redirect URIs in Google Cloud Console: - Must include: http://localhost:4200 (dev) or https://skigk-soekeapp.web.app (prod) 4. Clear browser cookies and try again 5. Try in incognito window to rule out cache issues

Problem: "Access Denied" Error After Login

Symptoms: - User logs in successfully - Error message appears - Cannot use the app

Solutions: 1. Verify your Google Account is added to Shared Drives (if applicable) 2. Check Google Cloud Console scopes include: - drive.readonly - openid - userinfo.profile 3. Try logout and login again 4. Check your Google Workspace admin hasn't restricted Drive API

Search Issues

Problem: Search Returns No Results

Symptoms: - Type keywords - No files appear - Blank result list

Solutions: 1. Check file exists in My Drive: - Go to https://drive.google.com - Search for the same filename - If it's not there, it won't appear in Skigk either

  1. For Shared Drives:
  2. Verify you are a member of the Shared Drive
  3. Ask a Shared Drive manager to add you
  4. May take 24 hours for new memberships to reflect

  5. Try broader search:

  6. Instead of "quarterly_report_2026_Q1_final_v3.xlsx"
  7. Try just "quarterly" or "report"

  8. Check file sharing:

  9. File owner must have shared the file with you or your group
  10. Files in Shared Drives you're a member of should be searchable

Problem: Search is Very Slow

Symptoms: - Typing takes a while - Results take 10+ seconds - Search hangs

Solutions: 1. Check network connection: - Slow internet will slow search - Try on a different network

  1. Reduce search scope:
  2. Search fewer Shared Drives
  3. Use specific keywords instead of broad terms

  4. Try another browser:

  5. Rules out browser-specific issues

  6. Check Google Drive quota:

  7. If you have thousands of files, search naturally takes longer
  8. Archive old files to speed up search

Problem: AI Summary Not Working

Symptoms: - Click "Get Summary" - Loading spinner - Error message or timeout

Solutions: 1. Check Gemini API key: - Verify VITE_GEMINI_API_KEY is set in .env.local - Key format should be alphanumeric string

  1. Check file type:
  2. Summaries work best with: Docs, Sheets, PDFs
  3. Images, videos, archives may not work

  4. Check file size:

  5. Very large files (>10MB) may timeout
  6. Try with a smaller file first

  7. Check API quota:

  8. Go to Google Cloud Console → APIs → Gemini API
  9. Verify quota hasn't been exceeded
  10. If using free tier, may have rate limits

Deployment Issues

Problem: Firebase Deployment Fails

Symptoms: - npm run build succeeds - firebase deploy fails - Error message about authentication

Solutions: 1. Verify Firebase login:

firebase login --reauth

  1. Check correct Firebase project:

    firebase projects:list
    firebase use skigk-soekeapp
    

  2. Verify .firebaserc exists:

    {
      "projects": {
        "default": "skigk-soekeapp"
      }
    }
    

  3. Check build output:

  4. Verify dist/ folder was created
  5. Should contain index.html and JS files

Problem: App Loads But Shows Blank Page

Symptoms: - Navigate to https://skigk-soekeapp.web.app - White/blank page - No errors in console

Solutions: 1. Check browser console (F12): - Look for JavaScript errors - Report them for debugging

  1. Verify Firebase Hosting is enabled:

    firebase hosting:sites:list
    

  2. Clear browser cache:

  3. Firefox: Ctrl+Shift+Del
  4. Chrome: Ctrl+Shift+Delete

  5. Check if build was successful:

  6. Run npm run build again
  7. Look for errors in output

Google Cloud Issues

Problem: "Invalid Client" OAuth Error

Symptoms: - OAuth redirect shows "invalid_client" - Error page in browser

Solutions: 1. Verify OAuth client ID format: - Should be: numbers.apps.googleusercontent.com - Not: appname or incomplete string

  1. Check Client ID matches Google Cloud Console:

    # In .env.local
    VITE_GOOGLE_CLIENT_ID=<copy exact ID from Console>
    

  2. Verify authorized origins:

  3. Go to Google Cloud Console → Credentials
  4. Click your OAuth 2.0 Client
  5. Check "Authorized JavaScript origins" includes:
    • http://localhost:4200 (for development)
    • https://skigk-soekeapp.web.app (for production)

Problem: "Insufficient Scopes" Error

Symptoms: - OAuth login shows error about permissions - Cannot access Google Drive data

Solutions: 1. Check scopes in Google Cloud Console: - Go to APIs & Services → OAuth Consent Screen - Verify "Scopes" includes: - drive.readonly - openid - userinfo.profile

  1. Update scopes in code (if needed):
  2. Check src/services/auth.service.ts
  3. Verify OAuth initialization includes correct scopes

  4. Logout and login again:

  5. Sometimes scope changes require re-authentication

Getting Help

If none of these solutions work:

  1. Check Firebase Logs:

    firebase functions:log --lines 50
    

  2. Check Google Cloud Logs:

  3. Go to Console → Logging → Logs
  4. Search for skigk-soekeapp

  5. Enable Debug Mode:

  6. Set DEBUG=* environment variable
  7. Provides more detailed error messages

  8. Contact Support:

  9. Email: admin-2025@skigk.no
  10. Include error message and steps to reproduce

Last Updated: January 2026 | Version: 1.0