Skip to content

Service auth is not available #8506

Open
@jdgamble555

Description

Operating System

Windows 11

Environment (if applicable)

Vercel Edge with Qwik

Firebase SDK Version

10.13.1-canary.16d62d4fa (or lower)

Firebase SDK Product(s)

Auth

Project Tooling

Qwik (1.8.0)

Detailed Problem Description

When I use getAuth() on the server inside a Qwik app, I get the Service Auth is not available error. The local testing environment has no problems and works as expected.

It is literally something that gets errored out in Qwik with getAuth().

Possibly related to #8355

While I'm not sure why the error is thrown, it is coming from here:

throw Error(`Service ${this.name} is not available`);

J

Steps and code to reproduce issue

I made a Repo:

  1. Add your Firebase environment variables to .env and to Vercel Edge environment variables.
PUBLIC_FIREBASE_CONFIG={"apiKey":....,"authDomain"...}
  1. Deploy to Vercel Edge.

  2. Sign in with Google.

  3. Click the about link in navigation.

  4. See error thrown.

See Deployed Demo with error.

If have isolated the error to getAuth(). This app doesn't use initializeApp or initializeServerApp, but the error is the same in either case.

Here is failing code.

J

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions