DAX: re-enable testing and build only on artiq-full #58

Merged
sb10q merged 4 commits from :feature/dax into master 2021-07-06 08:17:30 +08:00
1 changed files with 9 additions and 26 deletions

View File

@ -3,8 +3,8 @@ let
condaBuild = import ./fast/conda/build.nix { inherit pkgs; }; condaBuild = import ./fast/conda/build.nix { inherit pkgs; };
condaFakeSource = import ./fast/conda/fake-source.nix { inherit pkgs; }; condaFakeSource = import ./fast/conda/fake-source.nix { inherit pkgs; };
dualPackage = ( dualPackage = (
{ name, version, src, pythonOptions ? {}, condaOptions ? {}, withManual ? true}: { name, version, src, pythonOptions ? {}, condaOptions ? {}, enabled ? true, withManual ? true}:
{ pkgs.lib.optionalAttrs enabled ({
"${name}" = pkgs.python3Packages.buildPythonPackage ({ "${name}" = pkgs.python3Packages.buildPythonPackage ({
inherit version; inherit version;
name = "${name}-${version}"; name = "${name}-${version}";
@ -38,7 +38,7 @@ let
echo doc manual ${dest}/html index.html >> $out/nix-support/hydra-build-products echo doc manual ${dest}/html index.html >> $out/nix-support/hydra-build-products
''; '';
}; };
}) }))
); );
# https://github.com/m-labs/artiq/issues/23 # https://github.com/m-labs/artiq/issues/23
hidapi = pkgs.hidapi.overrideAttrs (oa: { hidapi = pkgs.hidapi.overrideAttrs (oa: {
@ -236,37 +236,25 @@ in
}; };
pythonOptions = { pythonOptions = {
propagatedBuildInputs = [ pkgs.python3Packages.flake8 ]; propagatedBuildInputs = [ pkgs.python3Packages.flake8 ];
checkInputs = [ pkgs.python3Packages.pytest pkgs.python3Packages.mypy pkgs.python3Packages.flake8 ]; checkInputs = [ pkgs.python3Packages.pytestCheckHook ];
checkPhase =
''
pytest
mypy
flake8
'';
}; };
condaOptions = { dependencies = [ "flake8" ]; }; condaOptions = { dependencies = [ "flake8" ]; };
}) // (dualPackage rec { }) // (dualPackage rec {
name = "dax"; name = "dax";
version = "6.3"; version = "6.4";
enabled = builtins.head (builtins.splitVersion version) == builtins.head (builtins.splitVersion artiq.version);
withManual = false; withManual = false;
src = pkgs.fetchgit { src = pkgs.fetchgit {
url = "https://gitlab.com/duke-artiq/dax.git"; url = "https://gitlab.com/duke-artiq/dax.git";
rev = "v${version}"; rev = "v${version}";
sha256 = "17bgqal8iyajnmp11wd59k4i8gpa3zf3cm7v8mjail5c8bnwyl4c"; sha256 = "08w0fpyyhk78i1qmych9kq3va02sm5k1z14yhzrfk9hhf5r7ypf8";
}; };
pythonOptions = { pythonOptions = {
VERSIONEER_OVERRIDE = version; VERSIONEER_OVERRIDE = version;
inherit (pkgs.python3Packages.pygit2) SSL_CERT_FILE; inherit (pkgs.python3Packages.pygit2) SSL_CERT_FILE;
propagatedBuildInputs = [ artiq sipyco ] propagatedBuildInputs = [ artiq sipyco ]
++ (with pkgs.python3Packages; [ numpy scipy pyvcd natsort pygit2 matplotlib graphviz h5py networkx ]); ++ (with pkgs.python3Packages; [ numpy scipy pyvcd natsort pygit2 matplotlib graphviz h5py networkx ]);
doCheck = false; checkInputs = [ pkgs.python3Packages.pytestCheckHook ];
checkInputs = [ pkgs.python3Packages.pytest pkgs.python3Packages.mypy pkgs.python3Packages.flake8 ];
checkPhase =
''
pytest
mypy
flake8
'';
}; };
condaOptions = { dependencies = [ "python>=3.7" "artiq" "sipyco" "numpy" "scipy" "pyvcd" "natsort" "pygit2" "matplotlib" "python-graphviz" "h5py" "networkx" ]; }; condaOptions = { dependencies = [ "python>=3.7" "artiq" "sipyco" "numpy" "scipy" "pyvcd" "natsort" "pygit2" "matplotlib" "python-graphviz" "h5py" "networkx" ]; };
}) // (dualPackage { }) // (dualPackage {
@ -281,12 +269,7 @@ in
pythonOptions = { pythonOptions = {
propagatedBuildInputs = [ artiq pyqtgraph-qt5 ] propagatedBuildInputs = [ artiq pyqtgraph-qt5 ]
++ (with pkgs.python3Packages; [ numpy pyqt5 ]); ++ (with pkgs.python3Packages; [ numpy pyqt5 ]);
checkInputs = [ pkgs.python3Packages.mypy pkgs.python3Packages.flake8 ]; doCheck = false;
checkPhase =
''
mypy
flake8
'';
}; };
condaOptions = { dependencies = [ "python>=3.5" "artiq" "numpy" "pyqt" "pyqtgraph" ]; }; condaOptions = { dependencies = [ "python>=3.5" "artiq" "numpy" "pyqt" "pyqtgraph" ]; };
}) })