diff options
author | Sandro <sandro.jaeckel@gmail.com> | 2023-04-11 23:43:41 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-11 23:43:41 +0200 |
commit | 0754f14961f4f72ff2483589bfd808006fbfb768 (patch) | |
tree | 5522cd633d0a0e5f71effb31f333c2238aad98ee /pkgs/servers | |
parent | a318c249c03b17cfaa40ab54f1917da6abafacfd (diff) | |
parent | 9ce0e05e0905dc4f95aa6909b19ad0cd3461b053 (diff) |
Merge pull request #221229 from euank/anki-native
Diffstat (limited to 'pkgs/servers')
-rw-r--r-- | pkgs/servers/ankisyncd/default.nix | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/pkgs/servers/ankisyncd/default.nix b/pkgs/servers/ankisyncd/default.nix index 45a43669502bf..b5e91bc1bb638 100644 --- a/pkgs/servers/ankisyncd/default.nix +++ b/pkgs/servers/ankisyncd/default.nix @@ -1,7 +1,6 @@ { lib , fetchFromGitHub , python3 -, anki }: python3.pkgs.buildPythonApplication rec { @@ -11,7 +10,8 @@ python3.pkgs.buildPythonApplication rec { owner = "ankicommunity"; repo = "anki-sync-server"; rev = version; - sha256 = "196xhd6vzp1ncr3ahz0bv0gp1ap2s37j8v48dwmvaywzayakqdab"; + hash = "sha256-RXrdJGJ+HMSpDGQBuVPPqsh3+uwAgE6f7ZJ0yFRMI8I="; + fetchSubmodules = true; }; format = "other"; @@ -21,6 +21,7 @@ python3.pkgs.buildPythonApplication rec { mkdir -p $out/${python3.sitePackages} cp -r ankisyncd utils ankisyncd.conf $out/${python3.sitePackages} + cp -r anki-bundled/anki $out/${python3.sitePackages} mkdir $out/share cp ankisyncctl.py $out/share/ @@ -28,7 +29,7 @@ python3.pkgs.buildPythonApplication rec { ''; fixupPhase = '' - PYTHONPATH="$PYTHONPATH:$out/${python3.sitePackages}:${anki}" + PYTHONPATH="$PYTHONPATH:$out/${python3.sitePackages}" makeWrapper "${python3.interpreter}" "$out/bin/ankisyncd" \ --set PYTHONPATH $PYTHONPATH \ @@ -46,14 +47,14 @@ python3.pkgs.buildPythonApplication rec { buildInputs = [ ]; - propagatedBuildInputs = [ anki ]; + propagatedBuildInputs = with python3.pkgs; [ + decorator + requests + ]; checkPhase = '' - # Exclude tests that require sqlite's sqldiff command, since - # it isn't yet packaged for NixOS, although 2 PRs exist: - # - https://github.com/NixOS/nixpkgs/pull/69112 - # - https://github.com/NixOS/nixpkgs/pull/75784 - # Once this is merged, these tests can be run as well. + # skip these tests, our files are too young: + # tests/test_web_media.py::SyncAppFunctionalMediaTest::test_sync_mediaChanges ValueError: ZIP does not support timestamps before 1980 pytest --ignore tests/test_web_media.py tests/ ''; |