Skip to content

v0.5.0 — Type Hints, Async Support & Regression Tests

Choose a tag to compare

@abduznik abduznik released this 12 Jul 17:44

What's Changed

Type Hints (Closes #108)

  • Added return type annotations and parameter type hints to all 14 driver modules (900+ methods)
  • Covers InstrumentDriver, Multimeter, PowerSupply, SpectrumAnalyzer, NetworkAnalyzer, Oscilloscope, SignalGenerator, FunctionGenerator, ElectronicLoad, FrequencyCounter and all concrete implementations

Async / Await Support (Closes #107)

  • New AsyncInstrumentDriver + type-specific wrappers (AsyncMultimeter, AsyncPowerSupply, AsyncSpectrumAnalyzer, AsyncNetworkAnalyzer, AsyncOscilloscope, AsyncSignalGenerator, AsyncFunctionGenerator, AsyncElectronicLoad, AsyncFrequencyCounter)
  • wrap_async(driver) factory — automatically picks the most specific async wrapper
  • async with context manager support
  • Parallel measurements via asyncio.gather()
  • Backward compatible with existing driver.async_*() dynamic wrapper

Regression Test Suite

  • 43 new regression tests covering driver basics, MeasurementResult contract, safety guardrails, simulated physics, type hint completeness, async wrapper, factory, and registry
  • 242 tests total (up from 199)

Good First Issue Skeletons

  • 5 new skeleton functions in transport.py and scanner.py for contributor onboarding:
    • detect_line_termination (#113)
    • find_minimum_timeout (#114)
    • poll_for_mav (#115)
    • poll_opc_with_backoff (#116)
    • find_duplicate_addresses (#117)

Other

  • Version bumped to 0.5.0
  • Release notes updated

Full Changelog: v0.4.2...v0.5.0