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

On-error type conformance in the Master_API #1472

Merged
merged 1 commit into from
Nov 20, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions tools/rosmaster/src/rosmaster/master_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -623,7 +623,7 @@ def registerService(self, caller_id, service, service_api, caller_api):
self.ps_lock.release()
return 1, "Registered [%s] as provider of [%s]"%(caller_id, service), 1

@apivalidate(0, (is_service('service'),))
@apivalidate('', (is_service('service'),))
def lookupService(self, caller_id, service):
"""
Lookup all provider of a particular service.
Expand Down Expand Up @@ -672,7 +672,7 @@ def unregisterService(self, caller_id, service, service_api):
##################################################################################
# PUBLISH/SUBSCRIBE

@apivalidate(0, ( is_topic('topic'), valid_type_name('topic_type'), is_api('caller_api')))
@apivalidate([], ( is_topic('topic'), valid_type_name('topic_type'), is_api('caller_api')))
def registerSubscriber(self, caller_id, topic, topic_type, caller_api):
"""
Subscribe the caller to the specified topic. In addition to receiving
Expand Down Expand Up @@ -729,7 +729,7 @@ def unregisterSubscriber(self, caller_id, topic, caller_api):
finally:
self.ps_lock.release()

@apivalidate(0, ( is_topic('topic'), valid_type_name('topic_type'), is_api('caller_api')))
@apivalidate([], ( is_topic('topic'), valid_type_name('topic_type'), is_api('caller_api')))
def registerPublisher(self, caller_id, topic, topic_type, caller_api):
"""
Register the caller as a publisher the topic.
Expand Down