3
0
Fork 0
forked from mirrors/nixpkgs

Merge pull request #196776 from fabaff/runway-python-fix

python310Packages.runway-python: rename input
This commit is contained in:
Pavol Rusnak 2022-10-19 18:36:30 +02:00 committed by GitHub
commit b5c52831d3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -19,8 +19,8 @@
, urllib3 , urllib3
, wget , wget
, deepdiff , deepdiff
, pytestCheckHook
, pytest-cov , pytest-cov
, pytestCheckHook
, pythonOlder , pythonOlder
, websocket-client , websocket-client
}: }:
@ -28,13 +28,15 @@
buildPythonPackage rec { buildPythonPackage rec {
pname = "runway-python"; pname = "runway-python";
version = "0.6.1"; version = "0.6.1";
format = "setuptools";
disabled = pythonOlder "3.6"; disabled = pythonOlder "3.6";
src = fetchFromGitHub { src = fetchFromGitHub {
owner = "runwayml"; owner = "runwayml";
repo = "model-sdk"; repo = "model-sdk";
rev = version; rev = version;
sha256 = "1ww2wai1qnly8i7g42vhkkbs4yp7wi9x4fjdxsg9fl3izjra0zs2"; hash = "sha256-Qn+gsvxxUJee7k060lPk53qi15xwC/JORJ5aHKLigvM=";
}; };
propagatedBuildInputs = [ propagatedBuildInputs = [
@ -54,32 +56,39 @@ buildPythonPackage rec {
unidecode unidecode
urllib3 urllib3
wget wget
]; ] ++ urllib3.optional-dependencies.secure;
pythonImportsCheck = [
"runway"
];
checkInputs = [ checkInputs = [
deepdiff deepdiff
pytestCheckHook
pytest-cov pytest-cov
pytestCheckHook
websocket-client websocket-client
]; ];
postPatch = ''
# Build fails with:
# ERROR: No matching distribution found for urllib3-secure-extra; extra == "secure"
substituteInPlace requirements.txt \
--replace "urllib3[secure]>=1.25.7" "urllib3"
'';
disabledTests = [ disabledTests = [
# these tests require network # These tests require network
"test_file_deserialization_remote" "test_file_deserialization_remote"
"test_file_deserialization_absolute_directory" "test_file_deserialization_absolute_directory"
"test_file_deserialization_remote_directory" "test_file_deserialization_remote_directory"
# Fails with a decoding error at the moment # Fails with a decoding error at the moment
"test_inference_async" "test_inference_async"
] ++ lib.optionals (pythonAtLeast "3.9") [ ] ++ lib.optionals (pythonAtLeast "3.9") [
# AttributeError: module 'base64' has no attribute 'decodestring # AttributeError: module 'base64' has no attribute 'decodestring
# https://github.com/runwayml/model-sdk/issues/99 # https://github.com/runwayml/model-sdk/issues/99
"test_image_serialize_and_deserialize" "test_image_serialize_and_deserialize"
"test_segmentation_serialize_and_deserialize_colormap" "test_segmentation_serialize_and_deserialize_colormap"
"test_segmentation_serialize_and_deserialize_labelmap" "test_segmentation_serialize_and_deserialize_labelmap"
];
pythonImportsCheck = [
"runway"
]; ];
meta = { meta = {