|
| 1 | +{ |
| 2 | + lib, |
| 3 | + python3Packages, |
| 4 | + fetchFromGitHub, |
| 5 | + procps, |
| 6 | + stdenv, |
| 7 | + versionCheckHook, |
| 8 | +}: |
| 9 | + |
| 10 | +python3Packages.buildPythonApplication rec { |
| 11 | + pname = "multiqc"; |
| 12 | + version = "1.26"; |
| 13 | + |
| 14 | + # Two data sources. One for the code, another for the test data |
| 15 | + srcs = [ |
| 16 | + (fetchFromGitHub { |
| 17 | + name = "multiqc"; |
| 18 | + owner = "MultiQC"; |
| 19 | + repo = "MultiQC"; |
| 20 | + tag = "v${version}"; |
| 21 | + hash = "sha256-MPAw6gG/3LzdskkDXOTDEM1NpG0sH9GvklYFQ1ZXWIs="; |
| 22 | + }) |
| 23 | + (fetchFromGitHub { |
| 24 | + owner = "MultiQC"; |
| 25 | + repo = "test-data"; |
| 26 | + rev = "67435083a8bfa228dca3dda7d835facef15fc2c7"; |
| 27 | + hash = "sha256-oYmPIJSy6dOKPcMr3B4foGoWcerA29x0XeGoU4dSYsA="; |
| 28 | + name = "test-data"; |
| 29 | + }) |
| 30 | + ]; |
| 31 | + |
| 32 | + sourceRoot = "multiqc"; |
| 33 | + |
| 34 | + dependencies = with python3Packages; [ |
| 35 | + click |
| 36 | + humanize |
| 37 | + importlib-metadata |
| 38 | + jinja2 |
| 39 | + kaleido |
| 40 | + markdown |
| 41 | + natsort |
| 42 | + numpy |
| 43 | + packaging |
| 44 | + requests |
| 45 | + pillow |
| 46 | + plotly |
| 47 | + pyyaml |
| 48 | + rich |
| 49 | + rich-click |
| 50 | + coloredlogs |
| 51 | + spectra |
| 52 | + pydantic |
| 53 | + typeguard |
| 54 | + tqdm |
| 55 | + ]; |
| 56 | + |
| 57 | + optional-dependencies = { |
| 58 | + dev = with python3Packages; [ |
| 59 | + pre-commit-hooks |
| 60 | + pdoc3 |
| 61 | + pytest |
| 62 | + pytest-cov-stub |
| 63 | + pytest-xdist |
| 64 | + syrupy |
| 65 | + pygithub |
| 66 | + mypy |
| 67 | + types-pyyaml |
| 68 | + types-tqdm |
| 69 | + types-requests |
| 70 | + types-markdown |
| 71 | + types-beautifulsoup4 |
| 72 | + types-pillow |
| 73 | + ]; |
| 74 | + }; |
| 75 | + |
| 76 | + # Some tests run subprocess.run() with "multiqc" |
| 77 | + preCheck = '' |
| 78 | + chmod -R u+w ../test-data |
| 79 | + ln -s ../test-data . |
| 80 | + export PATH=$out/bin:$PATH |
| 81 | + ''; |
| 82 | + |
| 83 | + # Some tests run subprocess.run() with "ps" |
| 84 | + nativeCheckInputs = with python3Packages; [ |
| 85 | + procps |
| 86 | + pytest-cov |
| 87 | + pytest-xdist |
| 88 | + pytestCheckHook |
| 89 | + syrupy |
| 90 | + pygithub |
| 91 | + versionCheckHook |
| 92 | + ]; |
| 93 | + |
| 94 | + versionCheckProgramArg = [ "--version" ]; |
| 95 | + |
| 96 | + disabledTests = |
| 97 | + # On darwin, kaleido fails to starts |
| 98 | + lib.optionals (stdenv.hostPlatform.isDarwin) [ |
| 99 | + "test_flat_plot" |
| 100 | + ]; |
| 101 | + |
| 102 | + meta = { |
| 103 | + description = "Aggregates bioinformatics results from multiple samples into a unified report"; |
| 104 | + longDescription = '' |
| 105 | + MultiQC is a tool to create a single report with interactive plots for multiple bioinformatics analyses across many samples. |
| 106 | +
|
| 107 | + Reports are generated by scanning given directories for recognised log files. These are parsed and a single HTML report is generated summarising the statistics for all logs found. MultiQC reports can describe multiple analysis steps and large numbers of samples within a single plot, and multiple analysis tools making it ideal for routine fast quality control. |
| 108 | + ''; |
| 109 | + homepage = "https://multiqc.info"; |
| 110 | + changelog = "https://github.com/MultiQC/MultiQC/releases/tag/v${version}/"; |
| 111 | + license = [ lib.licenses.gpl3Plus ]; |
| 112 | + maintainers = [ lib.maintainers.apraga ]; |
| 113 | + mainProgram = "multiqc"; |
| 114 | + platforms = lib.platforms.unix; |
| 115 | + }; |
| 116 | + |
| 117 | +} |
0 commit comments