2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
|
|
|
|
# Test dependencies
|
|
|
|
, pytest, pytest-mock
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "RestrictedPython";
|
2020-12-07 07:45:13 +00:00
|
|
|
version = "5.1";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2020-12-07 07:45:13 +00:00
|
|
|
sha256 = "9ae16e500782b41bd1abefd8554ccb26330817bba9ce090d385aa226f1ca83e8";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#propagatedBuildInputs = [ xmltodict requests ifaddr ];
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
pytest pytest-mock
|
|
|
|
];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
pytest
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
homepage = "https://github.com/zopefoundation/RestrictedPython";
|
|
|
|
description = "A restricted execution environment for Python to run untrusted code";
|
|
|
|
license = lib.licenses.zpl21;
|
|
|
|
maintainers = with lib.maintainers; [ juaningan ];
|
|
|
|
};
|
|
|
|
}
|