mabuchilab / Instrumental

Python-based instrumentation library from the Mabuchi Lab.
http://instrumental-lib.readthedocs.org/
GNU General Public License v3.0
117 stars 77 forks source link

Improve PyVisa Import Compatability #162

Closed sdshlanta closed 7 months ago

sdshlanta commented 1 year ago

Modern versions of PyVisa no longer import as visa and import as pyvisa.

This PR adds support for the new import style while maintaining comparability with the old version by detecting if import visa throws an ImportError and then attempting import pyvisa as visa.

sdshlanta commented 1 year ago

The commit history of this PR got slightly messy as I pulled the state of origin master after #159 was merged.

natezb commented 1 year ago

It looks like the pyvisa interface has been around for a very long time, so instead of all of these try/except blocks, let's just make a clean break and migrate to using pyvisa directly.

natezb commented 7 months ago

Dealt with in b577632b85015bc830283f3b315c4013260e8f91