Qcodes icon indicating copy to clipboard operation
Qcodes copied to clipboard

make qcodes.__version__ lazy

Open jenshnielsen opened this issue 1 year ago • 1 comments

This speeds up importing qcodes from an editable install with ~ 0.6-0.7 s assuming that you do not actually make use of the __version__ attribute. The downside is that we do lose some of the static typing of this attribute. See inline comments

Edit. Adding a type to __version__ partially resolves this but its probably better to make version an lazily evaluated property and reference that

jenshnielsen avatar Apr 05 '24 09:04 jenshnielsen

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 67.09%. Comparing base (07351c1) to head (27fce61). Report is 2501 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #5931   +/-   ##
=======================================
  Coverage   67.09%   67.09%           
=======================================
  Files         352      352           
  Lines       32035    32035           
=======================================
  Hits        21494    21494           
  Misses      10541    10541           

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

:rocket: New features to boost your workflow:
  • :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

codecov[bot] avatar Apr 05 '24 09:04 codecov[bot]