Skip to content

Conversation

@sahusiddharth
Copy link
Contributor

Description

Currently, the evaluate function raises an UnboundLocalError when neither image_paths nor image_urls are passed, since image_nodes is only defined inside conditional blocks.

This PR ensures image_nodes is always initialized to an empty list, preventing crashes and allowing evaluation to proceed with text-only input.

Changes:

  • Initialize image_nodes as an empty list at the start.
  • Use .extend() instead of reassigning inside conditionals.

@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Aug 16, 2025
@dosubot dosubot bot added the lgtm This PR has been approved by a maintainer label Aug 16, 2025
@logan-markewich logan-markewich merged commit 8a4dcef into run-llama:main Aug 16, 2025
10 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

lgtm This PR has been approved by a maintainer size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants