Skip to content

fix: resolve input data shows as undefined in simulateTask problem #333

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Jun 18, 2025

Conversation

chrisli30
Copy link
Member

@chrisli30 chrisli30 requested a review from Copilot June 17, 2025 22:55
Copilot

This comment was marked as outdated.

chrisli30 and others added 3 commits June 17, 2025 15:59
* Fix operator failed to notify aggregator on task trigger problem - Fixed critical bug in MustStart() where tasks were loaded using storage key instead of task ID, added database fallback, enhanced variable resolution with dual-access mapping, improved preprocessing in node runners, added comprehensive logging

* Fix unnecessary stack trace in event trigger query optimization warning - Changed Warn to Info level since this is informational, not an error requiring debugging

* Fixed runTask returns undefined for eventTrigger problem

* Update core/taskengine/engine.go

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* clean up and addressed copilot’s comments

* Fixed the format of test file

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Updated avs.proto and generated protobuf files

* Apply node.input to the Step of Execution

* Extract trigger input data using the proper extraction function

* Fixed the input of mannual trigger
Copilot

This comment was marked as outdated.

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds user-provided input support to triggers and nodes, enhances execution steps to include these inputs, and fixes undefined input data in SimulateTask and RunTask workflows.

  • Introduce input fields in protobuf definitions for triggers and nodes, and update gRPC service signatures.
  • Propagate input data through execution steps in VM runners and task executor/simulator.
  • Implement dual-access mapping (camelCase and snake_case) for variable input and output resolution.

Reviewed Changes

Copilot reviewed 23 out of 23 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
protobuf/avs.proto Added input fields and documentation for triggers/nodes
operator/operator.go Updated alias lookup to use timeout context and improved logging
core/taskengine/run_node_immediately.go Apply dual-access mapping before adding VM variables
core/taskengine/vm_runner_*.go Refactored to use GetNodeDataForExecution helper
core/taskengine/executor.go Extract and inject trigger input into VM on RunTask
core/taskengine/engine.go Recover stale tasks from DB and enrich event triggers
core/taskengine/*.test.go Updated tests to reflect camelCase naming and new APIs
Comments suppressed due to low confidence (1)

core/taskengine/trigger/event.go:771

  • [nitpick] This warning might indicate potential duplicates and deserves a higher log level; consider using Warn instead of Info.
				t.logger.Info("⚠️ Task has multiple unique queries - may receive duplicate events",

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