fake-bpy-module icon indicating copy to clipboard operation
fake-bpy-module copied to clipboard

Syntax error when using Mypy and python 3.11

Open n4nn31355 opened this issue 5 months ago • 0 comments
trafficstars

System Information

  • OS: Windows
  • Blender version: 4.4

Description about the bug

Mypy exits with syntax error when using python 3.11 starting from fake-bpy-module-4.2.

> mypy .
***\blender_ext\Lib\site-packages\bpy\types\__init__.pyi:111576: error: invalid syntax  [syntax]
    class bpy_prop_collection[_GenericType1]:

***\blender_ext\Lib\site-packages\bpy\stub_internal\rna_enums\__init__.pyi:6: error: invalid syntax  [syntax]
    type AssetLibraryTypeItems = typing.Literal[

According to the Discord discussion, this repo uses 3.12 syntax, and while it should work fine with Pyright, mypy has an issue.

Additional comments [Optional]

n4nn31355 avatar Jun 16 '25 17:06 n4nn31355