pyvisa / pyvisa-py

A pure python PyVISA backend
https://pyvisa-py.readthedocs.io
MIT License
288 stars 124 forks source link

TCPIP handler read shall not block #107

Closed skrchnavy closed 7 years ago

skrchnavy commented 7 years ago

tcpip handler was blocking in select.

this implementation waits for data for timeout seconds when in loop for first time, then polls in 0.01 sec interval. (sleep removed).

This shall solve #61

MatthieuDartiailh commented 7 years ago

Looks good to me. Is this ready to merge ?

skrchnavy commented 7 years ago

Need to test on linux and I am not sure if KeyboardInterrupt is handled properly (if it shall not rethrow the exception.

skrchnavy commented 7 years ago

KeyboardInterrupt is reraised. Also timeout is calculated as float to catch miliseconds properly (1900 ms was handled as 1 sec not 1.9 sec).

ready for final review / merge

MatthieuDartiailh commented 7 years ago

Minor things I would like to see fixed before merging. Please note that I will be away next week.

MatthieuDartiailh commented 7 years ago

Looks good ! Triggering bors

bors r+

bors[bot] commented 7 years ago

Build succeeded