Skip to content

Commit cf1189a

Browse files
committed
Double JSON ecode prompt data
The python JSON module produces output with NaN values that javascript refuses to consider valid JSON. As a workaround, the prompt data, which has never been used, is now json encoded before being added as metadata Resolves #282
1 parent 85da948 commit cf1189a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

videohelpersuite/nodes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ def batched_encode(images, vae, frames_per_batch):
308308
video_metadata = {}
309309
if prompt is not None:
310310
metadata.add_text("prompt", json.dumps(prompt))
311-
video_metadata["prompt"] = prompt
311+
video_metadata["prompt"] = json.dumps(prompt)
312312
if extra_pnginfo is not None:
313313
for x in extra_pnginfo:
314314
metadata.add_text(x, json.dumps(extra_pnginfo[x]))

0 commit comments

Comments
 (0)