python / python/mypy

code-blockwise configuration settings

オープン
#15,547 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

feature
主要言語
Python
スター
20.6k
フォーク
3.3k
PR マージ指標
PR 指標を取得中

説明

Feature

In mypy, we can do something like # type: ignore [error-code]

For some developer tools, we can use some blockwise settings, ex:

# fmt: off
blabla
# fmt: on

Momentarily configuring some mypy settings in a similar fashion would be useful

Pitch

A specific reason why I'd like to see this is that I have a codebase where allow-redefinition is False (and this is good). But I have a small region where I have a lot of type narrowing to do and in this case allowing a block of redefinitions is far more convenient. Plus, the control comments would signal to the reader that this is happening.

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

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

調査の方向性

この issue では、ファイル、テスト、エントリーポイントが指定されていません。まず、mypy がインラインの制御コメントや allow-redefinition などの設定をどのように扱うかを確認してください。完了とするには、ブロック単位のスコープを持つ設定の構文と動作について合意する必要があり、その設定をブロックの内側と外側でどのように適用するかも含まれます。

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

評価

技術スタック
python
領域
tooling
issue の種類
機能追加
難易度
5/5
見積もり時間
1週間以上
活発さ
停滞
明瞭さ
おおむね明確
初心者へのやさしさ
30/100

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

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