diff --git a/nixos/modules/services/misc/tandoor-recipes.nix b/nixos/modules/services/misc/tandoor-recipes.nix index a349bcac9321..63d3e3d2a857 100644 --- a/nixos/modules/services/misc/tandoor-recipes.nix +++ b/nixos/modules/services/misc/tandoor-recipes.nix @@ -9,6 +9,7 @@ let env = { GUNICORN_CMD_ARGS = "--bind=${cfg.address}:${toString cfg.port}"; DEBUG = "0"; + DEBUG_TOOLBAR = "0"; MEDIA_ROOT = "/var/lib/tandoor-recipes"; } // optionalAttrs (config.time.timeZone != null) { TIMEZONE = config.time.timeZone; diff --git a/pkgs/applications/misc/tandoor-recipes/common.nix b/pkgs/applications/misc/tandoor-recipes/common.nix index 49b38bec655a..1a3e4d261144 100644 --- a/pkgs/applications/misc/tandoor-recipes/common.nix +++ b/pkgs/applications/misc/tandoor-recipes/common.nix @@ -1,15 +1,15 @@ { lib, fetchFromGitHub }: rec { - version = "1.4.4"; + version = "1.4.9"; src = fetchFromGitHub { owner = "TandoorRecipes"; repo = "recipes"; rev = version; - sha256 = "sha256-1wqZoOT2Aafbs2P0mL33jw5HkrLIitUcRt6bQQcHx40="; + sha256 = "sha256-h424lUm/wmCHXkMW2XejogvH3wL/+J67cG4m8rIWM1U="; }; - yarnSha256 = "sha256-gH0q3pJ2BC5pAU9KSo3C9DDRUnpypoyLOEqKSrkxYrk="; + yarnSha256 = "sha256-LJ0uL66tcK6zL8Mkd2UB8dHsslMTtf8wQmgbZdvOT6s="; meta = with lib; { homepage = "https://tandoor.dev/"; diff --git a/pkgs/applications/misc/tandoor-recipes/default.nix b/pkgs/applications/misc/tandoor-recipes/default.nix index 89d1740a802c..1f5dee51c599 100644 --- a/pkgs/applications/misc/tandoor-recipes/default.nix +++ b/pkgs/applications/misc/tandoor-recipes/default.nix @@ -2,6 +2,7 @@ , nixosTests , python3 , fetchFromGitHub +, fetchpatch }: let python = python3.override { @@ -41,6 +42,12 @@ python.pkgs.pythonPackages.buildPythonPackage rec { patches = [ # Allow setting MEDIA_ROOT through environment variable ./media-root.patch + # Address CVE-2023-31047 on Django 4.2.1+ + (fetchpatch { + name = "fix-multiple-file-field"; + url = "https://github.com/TandoorRecipes/recipes/pull/2458/commits/6b04c922977317354a367487427b15a8ed619be9.patch"; + hash = "sha256-KmfjJSrB/4tOWtU7zrDJ/AOG4XlmWy/halw8IEEXdZ0="; + }) ]; propagatedBuildInputs = with python.pkgs; [ @@ -101,8 +108,10 @@ python.pkgs.pythonPackages.buildPythonPackage rec { buildPhase = '' runHook preBuild - # Avoid dependency on django debug toolbar + # Disable debug logging export DEBUG=0 + # Avoid dependency on django debug toolbar + export DEBUG_TOOLBAR=0 # See https://github.com/TandoorRecipes/recipes/issues/2043 mkdir cookbook/static/themes/maps/ diff --git a/pkgs/applications/misc/tandoor-recipes/frontend.nix b/pkgs/applications/misc/tandoor-recipes/frontend.nix index 2050d062d6a6..98da59a1d299 100644 --- a/pkgs/applications/misc/tandoor-recipes/frontend.nix +++ b/pkgs/applications/misc/tandoor-recipes/frontend.nix @@ -1,4 +1,4 @@ -{ stdenv, fetchYarnDeps, fixup_yarn_lock, callPackage, nodejs_16 }: +{ stdenv, fetchYarnDeps, fixup_yarn_lock, callPackage, nodejs }: let common = callPackage ./common.nix { }; in @@ -15,9 +15,8 @@ stdenv.mkDerivation { nativeBuildInputs = [ fixup_yarn_lock - # Use Node JS 16 because of @achrinza/node-ipc@9.2.2 - nodejs_16 - nodejs_16.pkgs.yarn + nodejs + nodejs.pkgs.yarn ]; configurePhase = '' diff --git a/pkgs/development/python-modules/django-js-reverse/default.nix b/pkgs/development/python-modules/django-js-reverse/default.nix index b06f8c89e358..a6f31a05c8f3 100644 --- a/pkgs/development/python-modules/django-js-reverse/default.nix +++ b/pkgs/development/python-modules/django-js-reverse/default.nix @@ -1,9 +1,11 @@ { lib , buildPythonPackage +, pythonAtLeast , fetchpatch , fetchFromGitHub , python , django +, packaging , nodejs , js2py , six @@ -11,26 +13,19 @@ buildPythonPackage rec { pname = "django-js-reverse"; - # Support for Django 4.0 not yet released - version = "unstable-2022-09-16"; + version = "0.10.1-b1"; src = fetchFromGitHub { - owner = "ierror"; + owner = "BITSOLVER"; repo = "django-js-reverse"; - rev = "7cab78c4531780ab4b32033d5104ccd5be1a246a"; - hash = "sha256-oA4R5MciDMcSsb+GAgWB5jhj+nl7E8t69u0qlx2G93E="; + rev = version; + hash = "sha256-i78UsxVwxyDAc8LrOVEXLG0tdidoQhvUx7GvPDaH0KY="; }; - patches = [ - (fetchpatch { - name = "fix-requires_system_checks-list-or-tuple"; - url = "https://github.com/ierror/django-js-reverse/commit/1477ba44b62c419d12ebec86e56973f1ae56f712.patch"; - hash = "sha256-xUtCziewVhnCOaNWddJBH4/Vvhwjjq/wcQDvh2YzWMQ="; - }) - ]; - propagatedBuildInputs = [ django + ] ++ lib.optionals (pythonAtLeast "3.7") [ + packaging ]; nativeCheckInputs = [ diff --git a/pkgs/development/python-modules/recipe-scrapers/default.nix b/pkgs/development/python-modules/recipe-scrapers/default.nix index c3fd8eb73560..10e5a4ff34e3 100644 --- a/pkgs/development/python-modules/recipe-scrapers/default.nix +++ b/pkgs/development/python-modules/recipe-scrapers/default.nix @@ -13,14 +13,14 @@ buildPythonPackage rec { pname = "recipe-scrapers"; - version = "14.32.1"; + version = "14.36.1"; format = "pyproject"; src = fetchFromGitHub { owner = "hhursev"; repo = "recipe-scrapers"; rev = "refs/tags/${version}"; - hash = "sha256-6iUagD1PTTAraBHOWLjHiLFFsImO30w84p+6IcIv52c="; + hash = "sha256-JadtlJMxRib8FpNC4QGYXfUEJGyB1aniDbsbsBYU3no="; }; nativeBuildInputs = [