Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

flutter-setup-localization: sets `synthetic-package: true`, which gen-l10n now rejects

Abierto Apto para principiantes
#239 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
88/100
Tipo de issue
Documentación
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
dart, flutter

Línea de trabajo

Actualiza skills/flutter-setup-localization/SKILL.md, empezando por el fragmento de l10n.yaml, la sección “Configure the App Entry Point” y ambos ejemplos prácticos. Ejecuta flutter gen-l10n en Flutter 3.47.2 para verificar la configuración y, después, confirma que los ejemplos usan la ruta real del archivo generado y ya no habilitan synthetic-package.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

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.

Lenguaje dominante
Dart
Estrellas
3k
Forks
182
Merge medio
2 d 19 h
PR fusionados (30 d)
6

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de flutter/agent-plugins

Todos los issues de flutter/agent-plugins

Issues similares

Más issues de Dart

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.