Open CarlosRDomin opened 1 year ago
Pushed an initial implementation, happy to take feedback on how to add a test for it. Alternatively, I'd be happy to just expose a way to pass extra_plugins
to build
if that's preferred given that not all options in the Mypy config file will be taken into account by stubgen
@AlexWaygood any feedback?
I'm afraid I've never touched stubgen, so I'm probably not the best reviewer, sorry! (I'm also not a maintainer, only a triager, so I wouldn't have the power to merge your PR either.)
The idea sounds reasonable, though!
Thanks for the feedback @AlexWaygood, apologies for tagging you then. Do you happen to know who'd be a maintainer/reviewer to get this merged eventually? Thanks!
Possibly @hauntsaninja or @sobolevn if either of them has the time — but mypy is maintained by volunteers, so I can't make any promises :)
Feature
Similar to #9193, I'd like to run
stubgen
with a custom plugin, and more generally, letstubgen
take a config filePitch
stubgen
is a really powerful tool (thanks devs for all the hard work!), but could become even more powerful by extending type support through custom plugins. Currently, there's no way (that I have found) to pass a configuration file (or at the very leastextra_plugins
tobuild
) tostubgen
, while !9203 exposed this option forstubtest
.The idea would be to implement a similar approach inside
stubgen
so we aren't forced to use the (much slower) interpreted version of mypy