Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

dart-run-static-analysis: plugin guidance describes the legacy plugin system, and the example includes a file that doesn't exist

未关闭 适合新手
#244 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
90/100
Issue 类型
文档
描述清晰度
描述清楚
活跃度
活跃
技术栈
dart
领域
documentation

调研方向

从 skills/dart-run-static-analysis/SKILL.md 开始,将其中的插件指南与 issue 中链接的现代 analysis server plugin 文档进行比较。更新现代和 legacy 插件、lint 启用、服务器重启、有效的 flutter_lints include 以及移除 missing_return 相关的示例和说明。在 dart-lang/skills 中应用 upstream fix,然后验证此 repository 中已同步的指南。

由索引模型根据 Issue 内容生成。

描述

Skill: skills/dart-run-static-analysis/SKILL.md, unchanged on main since fbb6bbc.

Found these while setting up a new-style analyzer plugin.

1. Plugin setup uses the legacy config

The skill says to put plugins under analyzer: plugins: and add them as dev dependencies. That's the legacy setup, not the setup for the modern plugin system introduced in Dart 3.10 / Flutter 3.38.

For modern plugins, use a top-level plugins: section. The analysis server resolves plugin dependencies separately, so adding the plugin to the project's pubspec.yaml isn't needed just to enable it.

The skill also leaves out that plugin warnings are on by default, but lint rules are off unless enabled under the plugin's diagnostics: key, directly or through an included options file.

Example, with placeholder package and rule names:

plugins:
  my_plugin:
    version: ^1.0.0
    diagnostics:
      rule_1: true
      rule_2: false

Please update the guidance to distinguish modern and legacy plugins, include lint activation, and mention restarting the analysis server after changing plugins:. The current instructions don't enable a modern-only plugin through the modern loader.

2. The example's include path doesn't exist

include: package:flutter_lints/recommended.yaml

flutter_lints 6.0.0 ships lib/flutter.yaml, not lib/recommended.yaml. Use the documented include:

include: package:flutter_lints/flutter.yaml

For pure Dart, use package:lints/recommended.yaml. This also matches the skill's own Base Configuration bullet.

3. missing_return is obsolete

The example sets missing_return: error. The analyzer lists MISSING_RETURN among its removed diagnostic codes. It's still accepted for compatibility, but the override no longer does anything. Please remove it from the example.

Environment

  • Model: Claude Opus 5.5.
  • Harness: Claude Code, with a plugin that vendors these skills.
  • Dart/Flutter SDK: Dart 3.13.4, Flutter 3.47.5.

The same file exists in dart-lang/skills, which syncs into this repository, so the fix needs to happen upstream.

主要语言
Dart
星标
3k
派生
181
平均合并
2 天 19 小时
30 天内合并 PR
6

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

flutter/agent-plugins 的其他 Issue

查看 flutter/agent-plugins 的全部 Issue

相似的 Issue

更多 Dart Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。