You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by GitBox <gi...@apache.org> on 2022/07/15 00:37:09 UTC

[GitHub] [tvm] guberti commented on a diff in pull request #12074: [microTVM] Make Arduino API server obey timeout

guberti commented on code in PR #12074:
URL: https://github.com/apache/tvm/pull/12074#discussion_r921714313


##########
apps/microtvm/arduino/template_project/microtvm_api_server.py:
##########
@@ -522,13 +522,13 @@ def close_transport(self):
         self._serial = None
 
     def read_transport(self, n, timeout_sec):
-        # It's hard to set timeout_sec, so we just throw it away
-        # TODO fix this
+        self._serial.timeout = timeout_sec
         if self._serial is None:
             raise server.TransportClosedError()
         return self._serial.read(n)
 
     def write_transport(self, data, timeout_sec):
+        self._serial.timeout = timeout_sec

Review Comment:
   Nice catch!



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tvm.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org