run method
Inspect project and return findings. May return an empty list.
Should NOT throw — turn unexpected conditions into Issues so the
report surfaces them rather than crashing.
Implementation
@override
List<Issue> run(DialectProject project) {
final banned = project.glossary.banned;
if (banned.isEmpty) return const [];
final issues = <Issue>[];
// Which `except:` keys actually earned their place this run, per pattern.
final excusedInPractice = <String, Set<String>>{};
_scan(
issues: issues,
excusedInPractice: excusedInPractice,
banned: banned,
arb: project.source,
locale: project.config.sourceLocale,
// A source-side issue carries no target locale, which is what puts
// `source` in its ack id (see ackId()).
reportedLocale: null,
);
for (final entry in project.translations.entries) {
if (entry.key == project.config.sourceLocale) continue;
_scan(
issues: issues,
excusedInPractice: excusedInPractice,
banned: banned,
arb: entry.value,
locale: entry.key,
reportedLocale: entry.key,
);
}
issues.addAll(_auditExcept(banned, excusedInPractice, project));
return issues;
}