1{ lib
2, fetchPypi
3, pythonOlder
4, buildPythonPackage
5, pyvisa
6, pyyaml
7, stringparser
8, typing-extensions
9, pytestCheckHook
10, setuptools
11, setuptools-scm
12, wheel
13}:
14
15buildPythonPackage rec {
16 pname = "pyvisa-sim";
17 version = "0.5.1";
18 format = "pyproject";
19
20 disabled = pythonOlder "3.8";
21
22 src = fetchPypi {
23 pname = "PyVISA-sim";
24 inherit version;
25 hash = "sha256-vWxW941/1e58pqL/Rzq+eoZJpwsvLphgIe48SuJtohY=";
26 };
27
28 nativeBuildInputs = [
29 setuptools
30 setuptools-scm
31 wheel
32 ];
33
34 propagatedBuildInputs = [
35 pyvisa
36 pyyaml
37 stringparser
38 typing-extensions
39 ];
40
41 nativeCheckInputs = [
42 pytestCheckHook
43 ];
44
45 pythonImportsCheck = [ "pyvisa_sim" ];
46
47 # should be fixed after 0.5.1, remove at next release
48 disabledTestPaths = [
49 "pyvisa_sim/testsuite/test_all.py"
50 ];
51
52 meta = with lib; {
53 description = "Simulated backend for PyVISA implementing TCPIP, GPIB, RS232, and USB resources";
54 homepage = "https://pyvisa.readthedocs.io/projects/pyvisa-sim/en/latest/";
55 license = licenses.mit;
56 maintainers = with maintainers; [ evilmav ];
57 };
58}