Skip to content

Commit

Permalink
Merge pull request NixOS#302035 from fabaff/appthreat-vulnerability-d…
Browse files Browse the repository at this point in the history
…b-bump

python312Packages.apsw: 3.45.1.0 -> 3.45.2.0, python312Packages.appthreat-vulnerability-db: 5.6.6 -> 5.6.7,  dep-scan: 5.2.14 -> 5.3.2
  • Loading branch information
fabaff authored Apr 10, 2024
2 parents def4bb0 + ee3702b commit 9207dab
Show file tree
Hide file tree
Showing 6 changed files with 46 additions and 112 deletions.
22 changes: 8 additions & 14 deletions pkgs/by-name/de/dep-scan/package.nix
Original file line number Diff line number Diff line change
@@ -1,31 +1,27 @@
{ lib
, python3
, fetchFromGitHub
{
lib,
fetchFromGitHub,
python3,
}:

python3.pkgs.buildPythonApplication rec {
pname = "dep-scan";
version = "5.2.14";
version = "5.3.2";
pyproject = true;

src = fetchFromGitHub {
owner = "owasp-dep-scan";
repo = "dep-scan";
rev = "refs/tags/v${version}";
hash = "sha256-G8i/tGEDgjPnIP04nrbx4HseiaU6N1GJGSg78yhaqII=";
hash = "sha256-2WV4f9vHdfnzoQWvwK/+lT9IS0v0sGBqnwDFHWG48G4=";
};

postPatch = ''
substituteInPlace pytest.ini \
--replace-fail " --cov-append --cov-report term --cov depscan" ""
# Already fixed by upstream
substituteInPlace pyproject.toml \
--replace-fail "==5.6.4" ">=5.6.4"
'';

build-system = with python3.pkgs; [
setuptools
];
build-system = with python3.pkgs; [ setuptools ];

dependencies = with python3.pkgs; [
appthreat-vulnerability-db
Expand All @@ -47,9 +43,7 @@ python3.pkgs.buildPythonApplication rec {
pytestCheckHook
];

pythonImportsCheck = [
"depscan"
];
pythonImportsCheck = [ "depscan" ];

preCheck = ''
export HOME=$(mktemp -d)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
{ lib
, appdirs
, buildPythonPackage
, cvss
, fetchFromGitHub
, httpx
, msgpack
, orjson
, packageurl-python
, pytestCheckHook
, pythonOlder
, pythonRelaxDepsHook
, semver
, setuptools
, tabulate
{
lib,
appdirs,
buildPythonPackage,
cvss,
fetchFromGitHub,
httpx,
msgpack,
orjson,
packageurl-python,
pytestCheckHook,
pythonOlder,
pythonRelaxDepsHook,
semver,
setuptools,
tabulate,
}:

buildPythonPackage rec {
pname = "appthreat-vulnerability-db";
version = "5.6.6";
version = "5.6.7";
pyproject = true;

disabled = pythonOlder "3.10";
Expand All @@ -26,7 +27,7 @@ buildPythonPackage rec {
owner = "AppThreat";
repo = "vulnerability-db";
rev = "refs/tags/v${version}";
hash = "sha256-wVl2C1AG9LbSh/p95fstJyJr6JnhZFIhNvq8mhpg13Q=";
hash = "sha256-/QzK+su+g2ESZ81C0coxKf13WOUVz1GyfJbOrO7fS98=";
};

postPatch = ''
Expand All @@ -39,13 +40,9 @@ buildPythonPackage rec {
"semver"
];

build-system = [
setuptools
];
build-system = [ setuptools ];

nativeBuildInputs = [
pythonRelaxDepsHook
];
nativeBuildInputs = [ pythonRelaxDepsHook ];

dependencies = [
appdirs
Expand All @@ -58,9 +55,7 @@ buildPythonPackage rec {
tabulate
] ++ httpx.optional-dependencies.http2;

nativeCheckInputs = [
pytestCheckHook
];
nativeCheckInputs = [ pytestCheckHook ];

preCheck = ''
export HOME=$(mktemp -d);
Expand All @@ -72,9 +67,7 @@ buildPythonPackage rec {
"test_download_recent"
];

pythonImportsCheck = [
"vdb"
];
pythonImportsCheck = [ "vdb" ];

meta = with lib; {
description = "Vulnerability database and package search for sources such as OSV, NVD, GitHub and npm";
Expand Down
29 changes: 15 additions & 14 deletions pkgs/development/python-modules/apsw/default.nix
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
{ lib
, buildPythonPackage
, fetchFromGitHub
, sqlite
, isPyPy
, python
{
lib,
buildPythonPackage,
fetchFromGitHub,
python,
pythonOlder,
setuptools,
sqlite,
}:

buildPythonPackage rec {
pname = "apsw";
version = "3.45.2.0";
format = "setuptools";
pyproject = true;

disabled = isPyPy;
disabled = pythonOlder "3.8";

src = fetchFromGitHub {
owner = "rogerbinns";
Expand All @@ -20,9 +22,9 @@ buildPythonPackage rec {
hash = "sha256-tTi3/10W4OoGH6PQVhvPWc5o09on5BZrWoAvrfh4C/E=";
};

buildInputs = [
sqlite
];
build-system = [ setuptools ];

buildInputs = [ sqlite ];

# Project uses custom test setup to exclude some tests by default, so using pytest
# requires more maintenance
Expand All @@ -31,13 +33,12 @@ buildPythonPackage rec {
${python.interpreter} setup.py test
'';

pythonImportsCheck = [
"apsw"
];
pythonImportsCheck = [ "apsw" ];

meta = with lib; {
description = "A Python wrapper for the SQLite embedded relational database engine";
homepage = "https://github.com/rogerbinns/apsw";
changelog = "https://github.com/rogerbinns/apsw/releases/tag/${version}";
license = licenses.zlib;
maintainers = with maintainers; [ gador ];
};
Expand Down
53 changes: 0 additions & 53 deletions pkgs/development/tools/appthreat-depscan/default.nix

This file was deleted.

1 change: 1 addition & 0 deletions pkgs/top-level/aliases.nix
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ mapAliases ({
ansible_2_13 = throw "Ansible 2.13 goes end of life in 2023/11"; # Added 2023-12-30
apacheAnt_1_9 = throw "Ant 1.9 has been removed since it's not used in nixpkgs anymore"; # Added 2023-11-12
antimicroX = antimicrox; # Added 2021-10-31
appthreat-depscan = dep-scan; # Added 2024-04-10
arcanPackages = throw "arcanPackages was removed and its sub-attributes were promoted to top-level"; # Added 2023-11-26
archiveopteryx = throw "archiveopteryx depended on an unsupported version of OpenSSL and was unmaintained"; # Added 2024-01-03
ardour_6 = throw "ardour_6 has been removed in favor of newer versions"; # Added 2023-10-13
Expand Down
2 changes: 0 additions & 2 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -299,8 +299,6 @@ with pkgs;

melange = callPackage ../development/tools/melange { };

appthreat-depscan = callPackage ../development/tools/appthreat-depscan { };

activate-linux = callPackage ../applications/misc/activate-linux { };

ansi = callPackage ../development/tools/ansi { };
Expand Down

0 comments on commit 9207dab

Please sign in to comment.