2018-10-27 22:44:08 +01:00
|
|
|
{ stdenv
|
|
|
|
, buildPythonPackage
|
|
|
|
, pytest
|
|
|
|
, Wand
|
|
|
|
, webob
|
|
|
|
, sqlalchemy
|
|
|
|
, isPyPy
|
|
|
|
, pkgs
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "SQLAlchemy-ImageAttach";
|
|
|
|
version = "1.0.0";
|
|
|
|
|
|
|
|
src = pkgs.fetchFromGitHub {
|
|
|
|
repo = "sqlalchemy-imageattach";
|
|
|
|
owner = "dahlia";
|
2019-09-09 00:38:31 +01:00
|
|
|
rev = version;
|
2018-10-27 22:44:08 +01:00
|
|
|
sha256 = "0ba97pn5dh00qvxyjbr0mr3pilxqw5kb3a6jd4wwbsfcv6nngqig";
|
|
|
|
};
|
|
|
|
|
|
|
|
checkInputs = [ pytest Wand.imagemagick webob ];
|
|
|
|
propagatedBuildInputs = [ sqlalchemy Wand ];
|
|
|
|
|
|
|
|
checkPhase = ''
|
|
|
|
cd tests
|
|
|
|
export MAGICK_HOME="${pkgs.imagemagick.dev}"
|
|
|
|
export PYTHONPATH=$PYTHONPATH:../
|
|
|
|
py.test
|
|
|
|
cd ..
|
|
|
|
'';
|
|
|
|
|
|
|
|
doCheck = !isPyPy; # failures due to sqla version mismatch
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/dahlia/sqlalchemy-imageattach";
|
2018-10-27 22:44:08 +01:00
|
|
|
description = "SQLAlchemy extension for attaching images to entity objects";
|
|
|
|
license = licenses.mit;
|
|
|
|
};
|
|
|
|
|
|
|
|
}
|