Skip to content
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

Unable to add docstrings for callback functions #65

Open
benknight135 opened this issue Sep 8, 2022 · 0 comments
Open

Unable to add docstrings for callback functions #65

benknight135 opened this issue Sep 8, 2022 · 0 comments
Labels
bug Something isn't working

Comments

@benknight135
Copy link
Contributor

Unable to add docstrings for callback functions.
Functions using std::function parameters fail to generate stubs.

[2022-09-08 11:27:11,223] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,224] {__init__.py:135} WARNING - def setReadThreadCallback(self: phase.pyphase.stereocamera.AbstractStereoCamera, callback: std::function<void __cdecl(I3DR::Phase::CameraReadResult)>) -> None: ...       
[2022-09-08 11:27:11,225] {__init__.py:136} WARNING -
                                    ^-- Invalid syntax
[2022-09-08 11:27:11,244] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,244] {__init__.py:135} WARNING - def setReadThreadCallback(self: phase.pyphase.stereocamera.DeimosStereoCamera, callback: std::function<void __cdecl(I3DR::Phase::CameraReadResult)>) -> None: ...
[2022-09-08 11:27:11,244] {__init__.py:136} WARNING -
                                  ^-- Invalid syntax
[2022-09-08 11:27:11,252] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,252] {__init__.py:135} WARNING - def setReadThreadCallback(self: phase.pyphase.stereocamera.PhobosStereoCamera, callback: std::function<void __cdecl(I3DR::Phase::CameraReadResult)>) -> None: ...
[2022-09-08 11:27:11,253] {__init__.py:136} WARNING -
                                  ^-- Invalid syntax
[2022-09-08 11:27:11,258] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,258] {__init__.py:135} WARNING - def setReadThreadCallback(self: phase.pyphase.stereocamera.PylonStereoCamera, callback: std::function<void __cdecl(I3DR::Phase::CameraReadResult)>) -> None: ...
[2022-09-08 11:27:11,259] {__init__.py:136} WARNING -
                                 ^-- Invalid syntax
[2022-09-08 11:27:11,268] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,269] {__init__.py:135} WARNING - def setReadThreadCallback(self: phase.pyphase.stereocamera.TitaniaStereoCamera, callback: std::function<void __cdecl(I3DR::Phase::CameraReadResult)>) -> None: ...        
[2022-09-08 11:27:11,269] {__init__.py:136} WARNING -
                                   ^-- Invalid syntax
[2022-09-08 11:27:11,276] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,277] {__init__.py:135} WARNING - def setReadThreadCallback(self: phase.pyphase.stereocamera.UVCStereoCamera, callback: std::function<void __cdecl(I3DR::Phase::CameraReadResult)>) -> None: ...
[2022-09-08 11:27:11,278] {__init__.py:136} WARNING -
                               ^-- Invalid syntax
[2022-09-08 11:27:11,283] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,284] {__init__.py:135} WARNING - def setComputeThreadCallback(self: phase.pyphase.stereomatcher.AbstractStereoMatcher, callback: std::function<void __cdecl(void)>) -> None: ...
[2022-09-08 11:27:11,284] {__init__.py:136} WARNING -
                                         ^-- Invalid syntax
[2022-09-08 11:27:11,287] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,288] {__init__.py:135} WARNING - def setComputeThreadCallback(self: phase.pyphase.stereomatcher.StereoBM, callback: std::function<void __cdecl(void)>) -> None: ...
[2022-09-08 11:27:11,288] {__init__.py:136} WARNING -
                            ^-- Invalid syntax
[2022-09-08 11:27:11,297] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,298] {__init__.py:135} WARNING - def setComputeThreadCallback(self: phase.pyphase.stereomatcher.StereoI3DRSGM, callback: std::function<void __cdecl(void)>) -> None: ...
[2022-09-08 11:27:11,298] {__init__.py:136} WARNING -
                                 ^-- Invalid syntax
[2022-09-08 11:27:11,303] {__init__.py:131} WARNING - Generated stubs signature is degraded to `(*args, **kwargs) -> typing.Any` for
[2022-09-08 11:27:11,304] {__init__.py:135} WARNING - def setComputeThreadCallback(self: phase.pyphase.stereomatcher.StereoSGBM, callback: std::function<void __cdecl(void)>) -> None: ...
[2022-09-08 11:27:11,305] {__init__.py:136} WARNING -
                              ^-- Invalid syntax
[2022-09-08 11:27:11,353] {__init__.py:957} INFO - Useful link: Avoiding C++ types in docstrings:
[2022-09-08 11:27:11,354] {__init__.py:958} INFO -       https://pybind11.readthedocs.io/en/latest/advanced/misc.html#avoiding-cpp-types-in-docstrings
@benknight135 benknight135 added the bug Something isn't working label Sep 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant