In VScode, the code will be masked as comments [QST]
yuemolin opened this issue · 4 comments
yuemolin commented
pwwang commented
It's actually marked as "Code is unreachable" by Pylance. Will dig into it.
pwwang commented
It's not an actual bug but because of the type annotations about the return value of the registered function.
Currently, we don't have the annotation for the return value of the function, and by default the function raises a NotImplementedError
, so Pylance
thinks the error is for sure to be raised, so the code after it will not be reached.
Will try to add return value annotations to those functions in the next patch version.
yuemolin commented
Thank you! I just updated and it works fine!