Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Document how to test plugins

オープン
#705 コメント 3 件 リアクション 1 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

  • #2023 @tanviranindo による — マージされずにクローズ

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
52/100
issue の種類
ドキュメント
明瞭さ
おおむね明確
活発さ
静か
技術スタック
python
領域
documentation

調査の方向性

既存の plugin-development/formatters ドキュメントと、issue に記載されている flake8 2.x から 3.x への移行コンテキストから始めます。有効な関数またはクラスのエントリポイント、1つのチェックに対して文字列をテストする方法、サブプロセスを使わずに標準チェックを実行する方法を網羅した実例をドキュメント化します。完了の条件は、その例が3つすべての質問に答えており、ドキュメント PR に適していることです。

索引モデルが issue の本文から書いたものです。

説明

component:docs component:legacy-api

In GitLab by @stephenfin on May 23, 2019, 03:07

I'm trying to migrate hacking from flake8 2.x to 3.x and finding it extremely difficult to do so because the internals of the flake8 have changed so drastically between these versions (plus hacking does some stuff that's too smart for its own good, IMO). The flake8 documentation provides some introductory text on plugins, including a guide on writing a "formatting type" plugin (though it doesn't explain what a formatting plugin actually is...) but there's nothing about testing this or even what type of class or function the entrypoints should point to. The biggest issue I have is that I want to run flake8 in it entirety (i.e. with both the standard checks and my plugin enabled) on a test string, but there doesn't appear to be anyway to do this.

Would it be possible to get a small worked example that demonstrates:

  • What the entrypoint should look like (i.e. if it can be a Python function, a class, or both)
  • How you can test a string against only a single check
  • How you can test a string against flake8's standard checks (without having to resort to a subprocess call)

I'll happily submit a documentation PR based on this example, if it would be helpful.

主要言語
Python
スター
3.8k
フォーク
363
平均マージ
3時間 59分
マージ済み PR(30日)
11

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

PyCQA/flake8 のほかの issue

PyCQA/flake8 の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。