-
Notifications
You must be signed in to change notification settings - Fork 820
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: MyPy compatibility #3119
Comments
We made a conscious decision to use pyright instead of mypy. https://github.com/bentoml/BentoML/blob/main/DEVELOPMENT.md#style-check-auto-formatting-type-checking We don't currently have intention on supporting two different types of type checker. |
@aarnphm I don't think you're understanding. This isn't about the development of BentoML... It's about using it elsewhere. Any project which uses BentoML can't currently use |
I have BentoML installed in a |
This is not necessarily a bug. When we decide to use pyright, we have heard about this issue with mypy. For what its worth, you can always disable mypy rules for bentoml for now: [mypy-bentoml]
ignore = true |
While I think this is a mypy bug that should be resolved, since the resolution is just to change the comment style on our type ignores and it would be a relatively easy change I don't see why we shouldn't do this. |
Describe the bug
BentoML doesn't play nice with
mypy
due to this issue: python/mypy#12299The issue is that a lot of
# type: ignore
comments in the codebase have additional comments after them (ie.# type: ignore (reason for ignore)
). This results in packages that use BentoML andmypy
throwingerror: Invalid "type: ignore" comment [syntax]
formypy
.To reproduce
No response
Expected behavior
BentoML should work with
mypy
Environment
Doesn't really matter.
The text was updated successfully, but these errors were encountered: