QCoDeS / Qcodes_contrib_drivers

A collection of community-contributed QCoDeS drivers for instruments
https://qcodes.github.io/Qcodes_contrib_drivers/
MIT License
46 stars 84 forks source link

Add a bunch of new drivers #261

Closed thangleiter closed 1 year ago

thangleiter commented 1 year ago

I am finally tackling our driver backlog. Some of these are likely to be of limited broad appeal, so let me know if adding them is out of scope for the main repo.

If desired I can split up the PR into one for each new driver.

astafan8 commented 1 year ago

also a few typing errors to fix, see here https://github.com/QCoDeS/Qcodes_contrib_drivers/actions/runs/6561129954/job/17820255378?pr=261

astafan8 commented 1 year ago

thanks for the contribution!

thangleiter commented 1 year ago

also a few typing errors to fix, see here https://github.com/QCoDeS/Qcodes_contrib_drivers/actions/runs/6561129954/job/17820255378?pr=261

I'd appreciate if you could help me out with some of those since I don't have a lot of experience with mypy.

astafan8 commented 1 year ago
astafan8 commented 1 year ago

qcodes_contrib_drivers/drivers/M2/M2_Solstis_3.py:142:37: error: X | Y syntax for unions requires Python 3.10 [syntax]

to sovle this you could add from __future__ import annotations at the top of the module

qcodes_contrib_drivers/drivers/Thermotek/Thermotek_T255p.py:5:1: error: Module "typing" has no attribute "ParamSpec"; maybe "_ParamSpec"? [attr-defined]

to solve this, i don't remember, but perhaps the minimum version of typing_extensions needs to be bumped or so.

astafan8 commented 1 year ago

@thangleiter instead of https://github.com/QCoDeS/Qcodes_contrib_drivers/commit/83b844be743afbf2b410cf9d63df400be9168ee4 you could add this module to autodoc mock imports like here https://github.com/QCoDeS/Qcodes/blob/main/docs/conf.py#L439

thangleiter commented 1 year ago

Mypy finally runs without errors locally on 3.9.

codecov-commenter commented 1 year ago

Codecov Report

Merging #261 (d601bc2) into main (3c10e07) will decrease coverage by 0.54%. The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main     #261      +/-   ##
==========================================
- Coverage   20.17%   19.64%   -0.54%     
==========================================
  Files         146      153       +7     
  Lines       18260    18756     +496     
==========================================
  Hits         3684     3684              
- Misses      14576    15072     +496     
Files Coverage Δ
qcodes_contrib_drivers/drivers/Horiba/__init__.py 0.00% <0.00%> (ø)
...ntrib_drivers/drivers/Horiba/private/fhr_client.py 0.00% <0.00%> (ø)
...ntrib_drivers/drivers/Horiba/private/fhr_server.py 0.00% <0.00%> (ø)
...ghthousePhotonics/Lighthouse_Photonics_Sprout_G.py 0.00% <0.00%> (ø)
qcodes_contrib_drivers/drivers/M2/M2_Solstis_3.py 0.00% <0.00%> (ø)
...ntrib_drivers/drivers/Thermotek/Thermotek_T255p.py 0.00% <0.00%> (ø)
...codes_contrib_drivers/drivers/Horiba/Horiba_FHR.py 0.00% <0.00%> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

thangleiter commented 1 year ago

... Docs should also be fixed now!