-
Notifications
You must be signed in to change notification settings - Fork 404
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
build_runner failed after upgrading my flutter #1427
Comments
Same issue here with Flutter 3.24.0 (latest stable release) |
Sadly I'm facing the same issue. |
i have the same issue
|
have you tried running |
You need the latest frontend_server_client package (this is a transitive dependency). Running |
I will write our error, so after search indexing some devs finds this page faster
|
Very thoughtful, @robot-den !! 🙏 |
We couldn't run `dart run build_runner build` anymore. After executing this command, you received: ``` [SEVERE] Failed to spawn build script after retry. This is likely due to a misconfigured builder definition. See the generated script at .dart_tool/build/entrypoint/build.dart to find errors. ``` This issue was introduced with #1703. The reason for it was that we need a newer `frontend_server_client` version (see google/json_serializable.dart#1427 (comment)). After running `dart/flutter pub upgrade` in every package, I was able to execute `dart run build_runner build` again.
We couldn't run `dart run build_runner build` anymore. After executing this command, you received: ``` [SEVERE] Failed to spawn build script after retry. This is likely due to a misconfigured builder definition. See the generated script at .dart_tool/build/entrypoint/build.dart to find errors. ``` This issue was introduced with #1703. The reason for it was that we need a newer `frontend_server_client` version (see google/json_serializable.dart#1427 (comment)). After running `dart/flutter pub upgrade` in every package, I was able to execute `dart run build_runner build` again.
@robot-den God bless you |
Work for me, Thanks @kevmoo 👏 |
i am unable to generate my model file after upgrading my flutter and dart sdk
dart --version
Dart SDK version: 3.5.0-103.0.dev (dev) (Thu Apr 25 17:03:06 2024 -0700) on "macos_x64"
flutter --version
Flutter 3.22.0-18.0.pre.30 • channel master • https://github.com/flutter/flutter.git
Framework • revision 5f0628d335 (11 days ago) • 2024-04-26 02:23:26 -0400
Engine • revision d794580077
Tools • Dart 3.5.0 (build 3.5.0-103.0.dev) • DevTools 2.35.0-dev.8
pubspec.yaml
environment:
sdk: '>=3.3.0-273.0.dev <4.0.0'
dev_dependencies:
flutter_test:
sdk: flutter
bloc_test: ^9.1.3
build_runner: ^2.4.9
json_serializable: ^6.7.1
model object
import 'package:json_annotation/json_annotation.dart';
part 'p_user.g.dart';
@JsonSerializable()
class User {
String name;
String phone;
String state;
String country;
String address;
User({
this.name = '',
this.phone = '',
this.country = '',
this.address = ''
});
factory User.fromJson(Map<String, dynamic> json) => _$UserFromJson(json);
Map<String, dynamic> toJson() => _$UserToJson(this);
}
Build Error
[INFO] Precompiling build script... completed, took 147ms
[SEVERE] Failed to precompile build script .dart_tool/build/entrypoint/build.dart.
This is likely caused by a misconfigured builder definition.
The text was updated successfully, but these errors were encountered: