CATEGORY

エラー・警告

  • 2023年1月16日
  • 2023年1月16日

Warning: A tag was used that wasn’t specified in dart_test.yaml. を消した

警告内容 FlutterでGolden Testを実施すると、「Warning: A tag was used that wasn’t specified in dart_test.yaml. 」と警告が表示される。 解決策 プロジェクトの直下に「dart_test.yaml」を作成したら、表示されなくなりました。 内容は人によりけりですが、アトミックデザインを意識したディレクトリ構成 […]

  • 2022年12月21日
  • 2022年12月21日

[Flutterエラー] Androidビルド時に Version code not found in manifest.

「Flutter Advent Calendar 2022」に参加させて頂きます!21日目です。 Androidのビルドで以下のようなエラーが発生したので、その解決方法を書きます。 エラー内容 FAILURE: Build failed with an exception. What went wrong: Execution failed for task ':app:packageReleas […]

  • 2022年12月12日
  • 2022年12月14日

【Flutter の例外】Tried to modify a provider while the widget tree was building. 【解決】

「Flutter Advent Calendar 2022」に参加させて頂きます!一応作成日にマッチさせてるし、開いている、クレームは言われないよね?。12日目です。 状況 RiverpodのConsumerStatefulWidgetを使用して状態管理をしている。initSateの中でStateProviderの値を書き換えようとすると、以下のエラーが発生した。 Unhandled Except […]

  • 2022年12月10日
  • 2022年12月14日

[Flutter] The argument type ‘ClassName/1/’ can’t be assigned to the parameter type ‘ClassName/2/’.【解決済】

「Flutter Advent Calendar 2022」に参加させて頂きます!一応作成日にマッチさせてるし、開いている、クレームは言われないよね?。10日目です。 エラーの現象 Flutter のテスト実施時に以下の現象が発生した。クラス内でjsonへ変換するメソッドを実装している。 > flutter test 00:01 +3: D:\project\github_api\test\ […]

  • 2022年9月16日
  • 2022年9月16日

【Flutter】「Tickers used by AnimationControllers should be disposed by calling dispose() on the AnimationController itself. Otherwise, the ticker will leak.」 というエラーが発生

エラーの内容 Flutterで他の方が作ったソースを実行していると、以下のエラーが発生した。 Tickers used by AnimationControllers should be disposed by calling dispose() on the AnimationController itself. Otherwise, the ticker will leak. 問題点と解決方法 […]

  • 2022年5月26日
  • 2024年2月8日

【Flutter】「Do not use BuildContexts across async gaps」という警告を消す方法

目的 Flutter 3.0 になってからかどうかは定かではありませんが、とりあえず「Do not use BuildContexts across async gaps」という警告が出るようになりました。この記事では、その理由と解決方法を記載します。 問題 以下のようなソースをStatefulWidgetのStateに書くと、「Do not use BuildContexts across as […]