Skip to content

Commit

Permalink
Merge pull request #336797 from SuperSandro2000/paperless-ngx
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperSandro2000 authored Aug 26, 2024
2 parents 1e4a2e9 + 7986bdf commit 6b4d280
Show file tree
Hide file tree
Showing 6 changed files with 30 additions and 26 deletions.
2 changes: 1 addition & 1 deletion nixos/modules/services/misc/paperless.nix
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ let
};
in
{
meta.maintainers = with maintainers; [ erikarvstedt Flakebi leona ];
meta.maintainers = with maintainers; [ leona SuperSandro2000 erikarvstedt ];

imports = [
(mkRenamedOptionModule [ "services" "paperless-ng" ] [ "services" "paperless" ])
Expand Down
2 changes: 1 addition & 1 deletion nixos/tests/paperless.nix
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import ./make-test-python.nix ({ lib, ... }: {
name = "paperless";
meta.maintainers = with lib.maintainers; [ erikarvstedt Flakebi ];
meta.maintainers = with lib.maintainers; [ leona SuperSandro2000 erikarvstedt ];

nodes = let self = {
simple = { pkgs, ... }: {
Expand Down
10 changes: 5 additions & 5 deletions pkgs/applications/office/paperless-ngx/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@
}:

let
version = "2.11.4";
version = "2.11.6";

src = fetchFromGitHub {
owner = "paperless-ngx";
repo = "paperless-ngx";
rev = "refs/tags/v${version}";
hash = "sha256-qqOTW7qgaZfNFYgVIDdwVh9KlT3Z6g8EALMOv39aRVc=";
hash = "sha256-RNX+KS2h9zrOK8QzeQWH55pkNPTDW4gic2HLG+XXLRg=";
};

# subpath installation is broken with uvicorn >= 0.26
Expand Down Expand Up @@ -76,7 +76,7 @@ let
cd src-ui
'';

npmDepsHash = "sha256-dze03mkWMA2o3v3aoPTrDtUndTdP7Tk4gvFp4nq80po=";
npmDepsHash = "sha256-ML1Yp3JIMbRF6kVu190ReoY7oDUtUfNkHE7dHF6YUAE=";

nativeBuildInputs = [
pkg-config
Expand Down Expand Up @@ -261,7 +261,7 @@ python.pkgs.buildPythonApplication rec {

passthru = {
inherit python path frontend tesseract5;
nltkData = with nltk-data; [ punkt snowball_data stopwords ];
nltkData = with nltk-data; [ punkt_tab snowball_data stopwords ];
tests = { inherit (nixosTests) paperless; };
};

Expand All @@ -271,6 +271,6 @@ python.pkgs.buildPythonApplication rec {
changelog = "https://github.com/paperless-ngx/paperless-ngx/releases/tag/v${version}";
license = licenses.gpl3Only;
platforms = platforms.unix;
maintainers = with maintainers; [ lukegb gador erikarvstedt leona ];
maintainers = with maintainers; [ leona SuperSandro2000 erikarvstedt ];
};
}
5 changes: 2 additions & 3 deletions pkgs/development/python-modules/nltk/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,14 @@

buildPythonPackage rec {
pname = "nltk";
version = "3.8.1";
version = "3.9.1";
format = "setuptools";

disabled = pythonOlder "3.7";

src = fetchPypi {
inherit pname version;
extension = "zip";
hash = "sha256-GDTaPQaCy6Tyzt4vmq1rD6+2RhukUdsO+2+cOXmNZNM=";
hash = "sha256-h9EnvT3kvYmk+BJl5fpZyxsZmydEAXU3D3QX0rx66Gg=";
};

propagatedBuildInputs = [
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{ lib, newScope, fetchFromGitHub, unzip, stdenvNoCC }:
let
base = {
version = "unstable-2023-02-02";
version = "0-unstable-2024-07-29";
nativeBuildInputs = [ unzip ];
dontBuild = true;
meta = with lib; {
Expand All @@ -17,14 +17,14 @@ let
src = fetchFromGitHub {
owner = "nltk";
repo = "nltk_data";
rev = "5db857e6f7df11eabb5e5665836db9ec8df07e28";
rev = "cfe82914f3c2d24363687f1db3b05e8b9f687e2b";
inherit hash;
sparseCheckout = [ "packages/${location}/${pname}.zip" ];
};
in
stdenvNoCC.mkDerivation (base // {
inherit pname src;
version = base.version;
inherit (base) version;
installPhase = ''
runHook preInstall
Expand All @@ -38,24 +38,29 @@ let
});
in
lib.makeScope newScope (self: {
punkt = makeNltkDataPackage ({
punkt = makeNltkDataPackage {
pname = "punkt";
location = "tokenizers";
hash = "sha256-rMkgn3xzmSJNv8//kqbPF2Xq3Gf16lgA1Wx8FPYbaQo=";
});
averaged_perceptron_tagger = makeNltkDataPackage ({
hash = "sha256-OzMkruoYbFKqzuimOXIpE5lhHz8tmSqOFoLT+fjdTVg=";
};
punkt_tab = makeNltkDataPackage {
pname = "punkt_tab";
location = "tokenizers";
hash = "sha256-OzMkruoYbFKqzuimOXIpE5lhHz8tmSqOFoLT+fjdTVg=";
};
averaged_perceptron_tagger = makeNltkDataPackage {
pname = "averaged_perceptron_tagger";
location = "taggers";
hash = "sha256-ilTs4HWPUoHxQb4kWEy3wJ6QsE/98+EQya44gtV2inw=";
});
snowball_data = makeNltkDataPackage ({
hash = "sha256-tl3Cn2okhBkUtTXvAmFRx72Brez6iTGRdmFTwFmpk3M=";
};
snowball_data = makeNltkDataPackage {
pname = "snowball_data";
location = "stemmers";
hash = "sha256-Y6LERPtaRbCtWmJCvMAd2xH02xdrevZBFNYvP9N4+3s=";
});
stopwords = makeNltkDataPackage ({
hash = "sha256-mNefwOPVJGz9kXV3LV4DuV7FJpNir/Nwg4ujd0CogEk=";
};
stopwords = makeNltkDataPackage {
pname = "stopwords";
location = "corpora";
hash = "sha256-Rj1jnt6IDEmBbSIHHueyEvPmdE4EZ6/bJ3qehniebbk=";
});
hash = "sha256-8lMjW5YI8h6dHJ/83HVY2OYGDyKPpgkUAKPISiAKqqk=";
};
})
2 changes: 1 addition & 1 deletion pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5783,7 +5783,7 @@ with pkgs;
inherit (darwin.apple_sdk.frameworks) Security;
};

nltk-data = callPackage ../tools/text/nltk_data { };
nltk-data = callPackage ../tools/text/nltk-data { };

seaborn-data = callPackage ../tools/misc/seaborn-data { };

Expand Down

0 comments on commit 6b4d280

Please sign in to comment.