Repository navigation
Description
I ran the check_plugin command (PyMoDAQ 5.3.x / dev, check_plugin . -v) on 5.0.x (commit 6d1e9bb, after #34 and #35), and again with #36 applied (it makes the Pll plugins importable when no camera or spectrometer is found; it is merged now): the findings are the same with and without it. It reports no failure but several warnings, listed below with what to do. The command is described in the instrument plugin documentation (section "The check_plugin command"), where every PMQ code is explained. The old names and their replacements are also listed in Legacy to current. Nothing was tested with Andor hardware. The run was on Linux without pylablib nor pymodaq-plugins-utils installed, so the "cannot be imported" messages for the Pll plugins are only about my environment and are not listed here.
Platforms
Parts of the package only work on Windows: ctypes.windll in hardware/andor_sdk2/sdk2.py and hardware/shamrock_sdk.py, and the path C:\Program Files\Andor SDK3 in hardware/andor_sdk3/sdk3.py and in daq_2Dviewer_AndorSCMOS.py (PMQ317). Either import the SDK lazily, in the method that needs it, or declare it on the instrument plugin class (supported_platforms = ('win32',)): see the section "Plugins working on some systems only" of the documentation. daq_1Dviewer_ShamrockSCMOS and ShamrockSCMOSLegacy already declare it; daq_2Dviewer_AndorSCMOS does not.
Deprecated names
daq_move_ShamrockPll: PMQ302_epsilonis deprecated, use_epsilons; PMQ313current_positionis deprecated (3 times), usecurrent_value.daq_2Dviewer_AndorSCMOS: PMQ318ini_detector_init()is deprecated, writeif self.is_master: self.controller = AWrapper() else: self.controller = controller.
Smaller points
- PMQ315: invalid escape sequence
'\P'inhardware/andor_sdk3/sdk3.py:32, use a raw string. - PMQ308 (
ShamrockSCMOSLegacy, optional): addif __name__ == "__main__": main(__file__)to run and debug the plugin on its own. - PMQ201: three
todolines of the template left inpyproject.toml(dependencies, authors, maintainers) and onetodoindaq_1Dviewer_ShamrockCCDPll.py:204. README.rststill lists the plugins before feature/pylablib_andor_CCD #32 (for instanceShamrock,AndorCCD), which now are insrc/pymodaq_plugins_andor/legacy(not loaded by PyMoDAQ).
Packaging
Done in #38: the classifiers are computed when the package is built (pyproject.toml still has static classifiers and "pymodaq_utils>=0.0.6" in the build requirements.dynamic = [..., "classifiers"], a [tool.pymodaq] table and pymodaq_utils>=5.3.6), as in the plugin template. The Operating System classifier follows the supported_platforms of the plugins: once daq_2Dviewer_AndorSCMOS and the other Windows-only plugins declare it (see "Platforms"), and provided no plugin of the package declares another system, the Windows classifier is added automatically; until then the package stays OS Independent.
To check again after the changes: check_plugin . -v, or run the acceptance test of tests/ (pytest).
Activity