Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

[bug]: flutterfire configure fails on reusing firebase.json

オープン
#353 コメント 6 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@Lyokone がすでに取り組んでいます。

2026年9月29日 から。

  • #434 @Harshit-0413 による — マージされずにクローズ
  • #466 @Lyokone による — オープン

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
42/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
dart, firebase, flutter
領域
cli

調査の方向性

flutterfire configure のエントリーポイントから開始し、Android の google-services.json ファイルを書き込む際に firebase.json の値がどのように再利用されるかを確認してください。新しい Flutter プロジェクトでコマンドを 2 回実行し、再利用された設定を成功した 1 回目の実行結果と比較してください。2 回目の実行が null type error なしで完了し、保存された値を再利用できれば、issue は完了したものとします。

索引モデルが issue の本文から書いたものです。

説明

blocked: customer-response bug keep open
Is there an existing issue for this?
  • I have searched the existing issues.
CLI Version

1.0.0

Firebase Tools version

13.29.0

Flutter Doctor Output

[√] Flutter (Channel stable, 3.27.1, on Microsoft Windows [Version 10.0.22631.4602], locale en-US)
• Flutter version 3.27.1 on channel stable at C:\Users\thukt\scoop\apps\flutter\3.27.1
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 17025dd882 (4 weeks ago), 2024-12-17 03:23:09 +0900
• Engine revision cb4b5fff73
• Dart version 3.6.0
• DevTools version 2.40.2

[√] Windows Version (Installed version of Windows is version 10 or higher)

[√] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
• Android SDK at C:\Users\thukt\AppData\Local\Android\sdk
• Platform android-35, build-tools 35.0.0
• Java binary at: C:\Users\thukt\AppData\Local\Programs\Android Studio\jbr\bin\java
• Java version OpenJDK Runtime Environment (build 21.0.3+-12282718-b509.11)
• All Android licenses accepted.

[√] Chrome - develop for the web
• Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.12.3)
• Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Community
• Visual Studio Community 2022 version 17.12.35527.113
• Windows 10 SDK version 10.0.26100.0

[√] Android Studio (version 2024.2)
• Android Studio at C:\Users\thukt\AppData\Local\Programs\Android Studio
• Flutter plugin can be installed from:
https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 21.0.3+-12282718-b509.11)

[√] VS Code (version 1.96.2)
• VS Code at C:\Users\thukt\AppData\Local\Programs\Microsoft VS Code
• Flutter extension version 3.102.0

[√] Connected device (4 available)
• sdk gphone64 x86 64 (mobile) • emulator-5554 • android-x64 • Android 14 (API 34) (emulator)
• Windows (desktop) • windows • windows-x64 • Microsoft Windows [Version
10.0.22631.4602]
• Chrome (web) • chrome • web-javascript • Google Chrome 131.0.6778.206
• Edge (web) • edge • web-javascript • Microsoft Edge 131.0.2903.112

[√] Network resources
• All expected network resources are available.

• No issues found!

Description

Each time I try to run flutterfire configure on this project to refresh configuration, I have to start from scratch. What I try to reuse the values in firebase.json, I get the following error:

$ flutterfire configure
? You have an existing `firebase.json` file and possibly already configured your project for Firebas
e. Would you prefer to reuse the values in your existing `firebase.json` file to configure your proj
✔ You have an existing `firebase.json` file and possibly already configured your project for Firebas
e. Would you prefer to reuse the values in your existing `firebase.json` file to configure your project? · yes
Failed to write android google-services.json file write for default service file. Please report this
 issue at:https://github.com/invertase/flutterfire_cli. Exception: type 'Null' is not a subtype of type 'Map<String, dynamic>' in type cast
type 'Null' is not a subtype of type 'Map<String, dynamic>' in type cast

If I say no and yes to overwrite, then follow the prompts and re-enter what I've previously entered, things work correctly.

Steps to reproduce

I can recreate this with a fresh project and doing flutterfire configure twice in a row.

$ flutter create flutterfire_minimal
[...]

$ cd flutterfire_minimal
[...]

$ flutterfire config
i Found 1 Firebase projects.
✔ Select a Firebase project to configure your Flutter application with · <create a new project>     
✔ Enter a project id for your new Firebase project (e.g. my-cool-project) · flutterfire-minimal     
i New Firebase project flutterfire-minimal created successfully.
✔ Which platforms should your configuration support (use arrow keys & space to select)? · android, ios, web
? Which Android application id (or package name) do you want to use for this configuration, e.g. 'co
✔ Which Android application id (or package name) do you want to use for this configuration, e.g. 'com.example.app'? · com.example.flutterfire.example 
i Firebase android app com.example.flutterfire.example is not registered on Firebase project flutterfire-minimal.
i Registered a new Firebase android app on Firebase project flutterfire-minimal.
i Firebase ios app com.example.flutterfireMinimal is not registered on Firebase project flutterfire-minimal.
i Registered a new Firebase ios app on Firebase project flutterfire-minimal.
i Firebase web app flutterfire_minimal (web) is not registered on Firebase project flutterfire-minimal.
i Registered a new Firebase web app on Firebase project flutterfire-minimal.
[...]

$ flutterfire config
? You have an existing `firebase.json` file and possibly already configured your project for Firebas
e. Would you prefer to reuse the values in your existing `firebase.json` file to configure your proj
✔ You have an existing `firebase.json` file and possibly already configured your project for Firebas
e. Would you prefer to reuse the values in your existing `firebase.json` file to configure your project? · yes
Failed to write android google-services.json file write for default service file. Please report this
 issue at:https://github.com/invertase/flutterfire_cli. Exception: type 'Null' is not a subtype of type 'Map<String, dynamic>' in type cast
type 'Null' is not a subtype of type 'Map<String, dynamic>' in type cast

Results of this pushed to https://github.com/AlanKrueger/flutterfire_minimal with individual commits for each step.

Expected behavior

Not to receive a type error and for the configure command to reuse the previously-entered information.

Screenshots

No response

Additional context and comments

No response

主要言語
Dart
スター
194
フォーク
76
平均マージ
2日 9時間
マージ済み PR(30日)
7

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

invertase/flutterfire_cli のほかの issue

invertase/flutterfire_cli の issue をすべて見る

似ている issue

Dart の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。