Skip to content

Error while configuring firebase cli in flutter project ?  #180

@harryandroiddev

Description

@harryandroiddev

Is there an existing issue for this?

  • I have searched the existing issues.

CLI Version

0.2.7

Firebase Tools version

12.0.1

Flutter Doctor Output

[✓] Flutter (Channel stable, 3.10.0, on macOS 13.0 22A8380 darwin-arm64
(Rosetta), locale en-IN)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.2)
[✓] Xcode - develop for iOS and macOS (Xcode 14.2)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2022.1)
[✓] VS Code (version 1.78.2)
[✓] Connected device (3 available)
[✓] Network resources

Description

After running the command flutterfire configure it throws the following error .

Unhandled exception:
FormatException: Unexpected character (at line 96, character 1)
{
^

#0 _ChunkedJsonParser.fail (dart:convert-patch/convert_patch.dart:1383:5)
firebase/flutterfire#1 _ChunkedJsonParser.parse (dart:convert-patch/convert_patch.dart:848:48)
firebase/flutterfire#2 _parseJson (dart:convert-patch/convert_patch.dart:35:10)
firebase/flutterfire#3 JsonDecoder.convert (dart:convert/json.dart:610:36)
firebase/flutterfire#4 runFirebaseCommand (package:flutterfire_cli/src/firebase.dart:95:25)

firebase/flutterfire#5 getProjects (package:flutterfire_cli/src/firebase.dart:114:20)

firebase/flutterfire#6 ConfigCommand._selectFirebaseProject (package:flutterfire_cli/src/commands/config.dart:300:24)

firebase/flutterfire#7 ConfigCommand.run (package:flutterfire_cli/src/commands/config.dart:390:37)

firebase/flutterfire#8 CommandRunner.runCommand (package:args/command_runner.dart:212:13)

firebase/flutterfire#9 main (file:///Users/harwinder/.pub-cache/hosted/pub.dev/flutterfire_cli-0.2.7/bin/flutterfire.dart:57:5)

Steps to reproduce

  1. firebase login (success)
  2. flutterfire configure

Expected behavior

It should add the firebase project and configuration to the project but not works as expected and throws the above error.
On running firebase login after login succesffully it also show the below error in screen shot .

Screenshots

Screenshot 2023-05-24 at 10 10 59 AM

No response

Additional context and comments

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions