Proposal: Add Feature To Ignore Specific Checks Using Comments
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
調査の方向性
リポジトリのファイル、テスト、エントリポイントは指定されていません。まず Plugin Check がエラーと警告を報告する仕組みを追跡し、次に提案されている PHP コメントアノテーションを既存の結果表示と比較してください。選択したチェックを非表示にしつつ、他の検出結果は表示したままにできれば完了です。
索引モデルが issue の本文から書いたものです。
説明
The plugin check plugin is a great tool. It has helped developers like me make their code compliant with the WordPress guidelines. However, some errors and warnings detected by this tool fall under the false positive category.
Similar toos like PHP Mess Detector and PHPStan have a way of supressing errors, using comments like
$test = new Test();
// @phpstan-ignore-next-line
$test->magic_property = 'magic value';
for PHPStan
or
/**
* @SuppressWarnings(PHPMD.UnusedFormalParameter)
*/
function test( $a , $b, $c ) {
...
}
for PHP Mess Detector
Proposal
I would be great if there is a way to supress the errors and warnings the developer thinks are false positives from showing as these could sometimes overcrowd the results page, making it difficult to spot other errors. Supressing this errors will enable the developer to focus on solving the most pertinent issues as these errors will be hidden from the results page.
I am proposing adding a feature to hide some errors and warnings.
For example
public function check_nonce() {
...
}
/**
* @PluginCheckSuppress(WordPress.Security.NonceVerification.Recommended)
*/
function some_function_here() {
// Already checked for the nonce in the check_nonce() function
// codes here ...
}
Please let me know what you think.
- 主要言語
- PHP
- スター
- 365
- フォーク
- 135
- 平均マージ
- 1日 8時間
- マージ済み PR(30日)
- 20
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
WordPress/plugin-check のほかの issue
-
False positive trademarked_term warning for "wc" inside the word "Flowchart"対応中かも @anandrajaram21 が 3 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
WordPress/plugin-check#1556 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Add opt-in .distignore exclusions for local and CI scans対応中かも @jakaria-istauk が 1 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 42/100
WordPress/plugin-check#1559 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 58/100
WordPress/plugin-check#1557 ·
メンテナーはふだん 1 日以内に返信
-
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
WordPress/plugin-check#1555 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
PHPErrorReportingSniff flags debug constants used as values in const declarations対応中かも @elphizu が 7 日前に担当しました。 オープン
難易度 3/5 半日 初心者へのやさしさ 35/100
WordPress/plugin-check#1553 ·
メンテナーはふだん 1 日以内に返信
WordPress/plugin-check の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
ExpressionEngine/ExpressionEngine#5493 ·
メンテナーはふだん 5 日以内に返信
-
"Attempt to read property 'username' on null" error after a user is deleted対応中かも @dicksonlaw583 が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
omeka/plugin-SimplePages#49 ·
-
not confirmed
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
メンテナーはふだん 1 日以内に返信
-
enhancement good first issue
難易度 2/5 1〜3時間 初心者へのやさしさ 86/100
メンテナーはふだん 1 日以内に返信