<#19574 python type checks fails because of compla...
# github-notifications
c
#19574 python type checks fails because of complaining about protobuf stubs even when mypy_plugin = true New discussion created by Adityav2410 I am using protobufs in my code. As per official documentations I have configured
Copy code
[python-protobuf]
mypy_plugin = true
I ran
pants export-codegen ::
, and it rightly generated
.py
and
.pyi
files. My
lint/test/fmt
are all running fine. However when I run
pants check ::
, it fails complaining that
Copy code
yi:6:1: error: Library stubs not installed for "google.protobuf"  [import]
    import google.protobuf.descriptor
    ^
 <xx>ra_pb2.pyi:7:1: error: Library stubs not installed for "google.protobuf.message"
As per the logs, mypy is running checks on
pyi
files. Is there any additional dependency? I have also added
mypy-protobuf
as a requirements for my
mypy
resolve. Can someone help me figure out what I am missing ? pantsbuild/pants