LoginSignup
4
1

More than 1 year has passed since last update.

VSCodeでPylanceのreportPrivateImportUsageを無視する

Posted at

Pylanceのtype-checkingモードはとても便利なのですが、意図しないreportPrivateImportUsageの警告を出してきます。たとえば、

from dask import array as da

da.from_array(...)  # <- 警告!

とかです。この場合dask__all__を定義していないためです。

解決策

ファイルのどこかに

# pyright: reportPrivateImportUsage=false

を書けばOK。

4
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
4
1