Skip to content

fix(executor): name the exact field when a Function block reference holds a large value - #8474

Open
waleedlatif1 wants to merge 3 commits into
stagingfrom
fix/function-large-value-errors
Open

waleedlatif1 wants to merge 3 commits into
stagingfrom
fix/function-large-value-errors

Conversation

@waleedlatif1

Copy link
Copy Markdown
Collaborator

Summary

  • When a Function block reference holds a large value below its root (e.g. contents: [<large value>]), the error now names the exact field to reference instead of the generic "This execution value contains nested large values": <file.contents> contains a 10.5 MB value at <file.contents[0]>. Reference that field directly.
  • Runtimes that cannot load a large value on demand (Python, shell, JavaScript with imports) get Select a smaller field, or read it in JavaScript without imports. instead of being pointed at a reference that would fail the same way
  • A reference pointing straight at a large value in those runtimes now names the reference and its size, and a large array no longer gets the misleading "nested" message
  • Keys that can't be written as a reference (dots, spaces, operators) omit the field path rather than suggesting an invalid one; array manifests are named as the field rather than their internal chunks
  • Throw behavior is unchanged — only the message. The walk stops at the first large value like containsLargeValueRef, reads the size already stored on the ref, loads nothing, and only runs when we're about to throw

Type of Change

  • Bug fix

Testing

  • executor/variables suite (129 tests); 7 new/changed assertions, all red against the previous resolver
  • Removed each new guard (key escaping, runtime remedy, stop at manifests) and watched its test go red
  • bun run type-check, bun run lint, bun run check:audits (52/52), docs-manifest:check

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing (new tests pass the test-audit authoring gate)
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel

vercel Bot commented Sep 30, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated
docs Skipped Skipped Sep 30, 2026 7:20pm UTC

Request Review

@greptile-apps

greptile-apps Bot commented Sep 30, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[Medium risk] Refactors large-value error handling in the variable resolver.

The PR appears safe to merge; no outstanding findings or new actionable issues remain.

Summary

The PR makes Function block large-value errors identify the nested field and its size, and gives runtime-appropriate guidance. The change since the previous review prevents the error from suggesting an unusable path for numeric object keys.

Reviews (3) · Last reviewed commit: "fix(executor): never suggest a digit-onl..."

Comment thread apps/sim/executor/variables/resolver.ts
@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed

Reply with feedback, questions, or to request a fix.

Fix all with cubic | Re-trigger cubic

Comment thread apps/sim/executor/variables/resolver.ts

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 2 files

Requires human review: Auto-approval blocked because this review re-detected 1 unresolved issue already reported by Cubic.

Re-trigger cubic

Comment thread apps/sim/executor/variables/resolver.ts Outdated
@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@greptile

@waleedlatif1

Copy link
Copy Markdown
Collaborator Author

@cubic-dev-ai review this PR

@cubic-dev-ai

cubic-dev-ai Bot commented Sep 30, 2026

Copy link
Copy Markdown
Contributor

@cubic-dev-ai review this PR

@waleedlatif1 I have started the AI code review. It will take a few minutes to complete.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 2 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Re-trigger cubic

This branch was previously deployed

1 inactive deployment
Preview — 97c4917e Deployed Sep 30, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant