From 9dd5e10ebaed66f173c4c849c4d20399413080c2 Mon Sep 17 00:00:00 2001 From: Koushik Dutta Date: Mon, 25 Sep 2023 07:12:05 -0700 Subject: [PATCH] python-codecs: fix float being passed to pil resize args --- plugins/python-codecs/package-lock.json | 4 ++-- plugins/python-codecs/package.json | 2 +- plugins/python-codecs/src/pilimage.py | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/plugins/python-codecs/package-lock.json b/plugins/python-codecs/package-lock.json index 2dfabcdd7..aa5529057 100644 --- a/plugins/python-codecs/package-lock.json +++ b/plugins/python-codecs/package-lock.json @@ -1,12 +1,12 @@ { "name": "@scrypted/python-codecs", - "version": "0.1.85", + "version": "0.1.86", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@scrypted/python-codecs", - "version": "0.1.85", + "version": "0.1.86", "devDependencies": { "@scrypted/sdk": "file:../../sdk" } diff --git a/plugins/python-codecs/package.json b/plugins/python-codecs/package.json index a6417bcc1..78edf57d5 100644 --- a/plugins/python-codecs/package.json +++ b/plugins/python-codecs/package.json @@ -1,6 +1,6 @@ { "name": "@scrypted/python-codecs", - "version": "0.1.85", + "version": "0.1.86", "description": "Python Codecs for Scrypted", "keywords": [ "scrypted", diff --git a/plugins/python-codecs/src/pilimage.py b/plugins/python-codecs/src/pilimage.py index 8e5f85b24..870cd58f5 100644 --- a/plugins/python-codecs/src/pilimage.py +++ b/plugins/python-codecs/src/pilimage.py @@ -98,7 +98,7 @@ def toPILImage(pilImageWrapper: PILImage, options: scrypted_sdk.ImageOptions = N if not width: width = pilImage.width * yscale - pilImage = pilImage.resize((width, height), resample=Image.BILINEAR) + pilImage = pilImage.resize((int(width), int(height)), resample=Image.BILINEAR) return PILImage(pilImage)