-
Notifications
You must be signed in to change notification settings - Fork 386
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
async Service handler fails due to bad result type #547
Comments
I have really no clue what will happen to non async service callbacks. So a good way to check whether this works, add a test with an async and non-async service callback. That non-async test should succeed and the the async test should fail. Then add your changes and both tests should succeed. |
@MatthijsBurgh Why was fixing this issue not planned? Why doesn't it make sense to use an async callback? The person that opened this issue suggested a fix that would work and you said "Then add your changes and both tests should succeed" - so why not implement those changes? If these changes were implemented and a synchronous callback function was provided, wouldn't it still work correctly exactly the same way if the |
@f-o-w-l Your help would be really appreciated. So please implement a test, which fails for the async callback before the fix. Apply the fix and show the test now succeeds. |
I would love to contribute! Let me give that a shot some time soon 😁 |
Description
Steps To Reproduce
Expected Behavior
rosservice call /foo/testing "data: false"
should output
success: False
message: "passed false"
Actual Behavior
rosservice call hangs
rosbridge reports:
service_response: Expected
\ field result to be one of (<class 'bool'>,). Invalid value: {}"
file: "protocol.py"
in
Service.js
,changing _service
response to start like this seems to resolve the issue in my small use case:The text was updated successfully, but these errors were encountered: