skills/flutter-setup-localization/SKILL.md tells the agent to write an l10n.yaml with synthetic-package: true and to import the result from package:flutter_gen/gen_l10n/app_localizations.dart. Both the config snippet and both worked examples do this:
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L60
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L68
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L179
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L186
Synthetic packages have been removed. On Flutter 3.47.2 stable, following the skill as written fails at the first step:
$ flutter gen-l10n
l10n.yaml: Cannot enable "synthetic-package", this feature has been removed. See http://flutter.dev/to/flutter-gen-deprecation.
and flutter gen-l10n --help lists the flag only as:
--[no-]synthetic-package DEPRECATED. This flag cannot be enabled and should be removed.
An agent following the skill therefore produces a project whose localization step errors out and whose imports point at a package that will never exist.
Suggested fix: drop synthetic-package from the config, set output-dir (for example lib/l10n), and change the imports to the generated file's real path (import 'l10n/app_localizations.dart'; or the package-relative equivalent). The "Configure the App Entry Point" section and both examples need the same change.
Found while reviewing the skills vendored into a project via npx skills add flutter/agent-plugins --skill '*' --agent universal.
skills/flutter-setup-localization/SKILL.mdtells the agent to write anl10n.yamlwithsynthetic-package: trueand to import the result frompackage:flutter_gen/gen_l10n/app_localizations.dart. Both the config snippet and both worked examples do this:https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L60
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L68
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L179
https://github.com/flutter/agent-plugins/blob/e89522a/skills/flutter-setup-localization/SKILL.md#L186
Synthetic packages have been removed. On Flutter 3.47.2 stable, following the skill as written fails at the first step:
and
flutter gen-l10n --helplists the flag only as:An agent following the skill therefore produces a project whose localization step errors out and whose imports point at a package that will never exist.
Suggested fix: drop
synthetic-packagefrom the config, setoutput-dir(for examplelib/l10n), and change the imports to the generated file's real path (import 'l10n/app_localizations.dart';or the package-relative equivalent). The "Configure the App Entry Point" section and both examples need the same change.Found while reviewing the skills vendored into a project via
npx skills add flutter/agent-plugins --skill '*' --agent universal.