-
Notifications
You must be signed in to change notification settings - Fork 0
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
Vec3D
transition shortcomings hidden by mypy
failures
#211
Comments
For runtime checks you can already do Nevermind - Just inheriting from |
@supersergiy: Regarding 2) Is there an advantage of this over |
So 1) is (at least checking for typing bit, not the other things that need to be implemented) fixed by the PR linked - are the other mixin functions actually needed? For 2), I think For 3), I will write docs for VecND. For 4), I've looked into this a little and it looks like |
Problem with 4 is more serious than just At the same time,
but |
This used to work. I wonder if something broke our mypy plugin |
@nkemnitz discovered several breaking issues introduced by the
Vec3D
change.The most notable one is the breakage of the
interpolate
flow, addressed by #210, #209.Several questions remain:
Sequence
protocol. This requires annotations likeUnion[Sequence[float], VecND]
even in places that rely only on__len__
and__getitem__
. Is there a good solution to this? fix: _VecND inherits from abc.Sequence #213vec.list()
/vec.as_list()
/vec.to_list()
? Same for tupleVec3D
in the [Docs]? It's challenging for the new users to know how to operate it.tensor_ops.interpolate
expected sequence but got Vec3D was not caught bymypy
? The error is fixed by fix:VecND
support fortensor_ops.interpolate
#210 , but I expectmypy
to be able to catch this.The text was updated successfully, but these errors were encountered: