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

ROSTransportでSubscriber側のRTCが異常終了すると、Publisher側のRTCがエラー状態になる問題 #304

Merged
merged 2 commits into from
Dec 18, 2023

Conversation

Nobu19800
Copy link

Identify the Bug

ConsoleInとConsoleOutを起動して、ROSTransportで接続する。
ConsoleOutをkillコマンドで終了させた後、ConsoleInでデータを送信しようとすると、ConsoleInがエラー状態になる。

Traceback (most recent call last):
  File "/usr/local/lib/python3.8/dist-packages/OpenRTM_aist/DataFlowComponentBase.py", line 123, in on_execute
    ret = self.onExecute(ec_id)
  File "/usr/local/share/openrtm-2.0/components/python3/SimpleIO/ConsoleIn.py", line 101, in onExecute
    self._outport.write()
  File "/usr/local/lib/python3.8/dist-packages/OpenRTM_aist/OutPort.py", line 195, in write
    ret = con.write(value)
  File "/usr/local/lib/python3.8/dist-packages/OpenRTM_aist/OutPortPushConnector.py", line 283, in write
    return self._publisher.write(cdr_data, -1, 0)
  File "/usr/local/lib/python3.8/dist-packages/OpenRTM_aist/PublisherFlush.py", line 288, in write
    self._retcode = self._consumer.put(data)
  File "/home/n-miyamoto2/rtcrostest/./ext/ROSTransport/ROSOutPort.py", line 324, in put
    self._topicmgr.removeSubscriberLink(connector.getConnection())
  File "/home/n-miyamoto2/rtcrostest/./ext/ROSTransport/ROSTopicManager.py", line 835, in removeSubscriberLink
    con.exit()
  File "/home/n-miyamoto2/rtcrostest/./ext/ROSTransport/ROSTopicManager.py", line 1336, in exit
    self._conn.shutdown(socket.SHUT_RDWR)
OSError: [Errno 107] Transport endpoint is not connected

Description of the Change

ROSTransportで例外が発生する箇所について、ROSTransportの中で例外処理するように修正した。

Verification

  • Did you succeed the build?
  • No warnings for the build?
  • Have you passed the unit tests?

@Nobu19800 Nobu19800 added the bug Something isn't working label Oct 17, 2023
@Nobu19800 Nobu19800 requested a review from n-ando October 17, 2023 01:56
@Nobu19800 Nobu19800 self-assigned this Oct 17, 2023
@n-ando n-ando merged commit f2a6f7b into OpenRTM:master Dec 18, 2023
0 of 4 checks passed
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

Successfully merging this pull request may close these issues.

2 participants