Skip to content
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

loop task #1317

Merged
merged 1 commit into from
Dec 4, 2024
Merged

loop task #1317

merged 1 commit into from
Dec 4, 2024

Conversation

wintonzheng
Copy link
Contributor

@wintonzheng wintonzheng commented Dec 4, 2024

No description provided.

<!-- ELLIPSIS_HIDDEN -->

> [!IMPORTANT]
> Adds support for 'loop' task type with no-op handling, new models, and prompt templates in `run_observer.py` and `block.py`.
>
>   - **Behavior**:
>     - Adds no-op handling for `loop` task type in `run_observer()` in `run_observer.py`.
>     - Logs unsupported task types and marks workflow as failed if encountered.
>   - **Prompts**:
>     - Adds `generate_loop_task.j2` and `loop_task_extraction_goal.j2` for loop task handling.
>     - Updates `observer.j2` to include `loop` task type.
>   - **Models**:
>     - Adds `ForLoopBlock` and `LoopExtractionOutput` classes in `block.py`.
>     - Updates `Block` class to handle loop-specific context and execution.
>   - **Functions**:
>     - Implements `_generate_loop_task()` in `run_observer.py` to create loop tasks.
>     - Modifies `execute()` in `ForLoopBlock` to handle loop execution logic.
>
> <sup>This description was created by </sup>[<img alt="Ellipsis" src="https://img.shields.io/badge/Ellipsis-blue?color=175173">](https://www.ellipsis.dev?ref=Skyvern-AI%2Fskyvern-cloud&utm_source=github&utm_medium=referral)<sup> for a645a32d99681bab465b2f98c75dab4f4754cba2. It will automatically update as commits are pushed.</sup>

<!-- ELLIPSIS_HIDDEN -->
Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

❌ Changes requested. Reviewed everything up to d1858f5 in 36 seconds

More details
  • Looked at 39 lines of code in 2 files
  • Skipped 0 files when reviewing.
  • Skipped posting 0 drafted comments based on config settings.

Workflow ID: wflow_a5FGPTDDMNhttUYC


Want Ellipsis to fix these issues? Tag @ellipsis-dev in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@@ -598,9 +598,6 @@ def get_all_parameters(
return list(parameters)

def get_loop_block_context_parameters(self, workflow_run_id: str, loop_data: Any) -> list[ContextParameter]:
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider re-adding the type check for loop_data to ensure it is either a dict or a list. This prevents potential runtime errors if loop_data is of an unexpected type.

Copy link
Contributor

@ellipsis-dev ellipsis-dev bot left a comment

Choose a reason for hiding this comment

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

❌ Changes requested. Incremental review on d1858f5 in 46 seconds

More details
  • Looked at 39 lines of code in 2 files
  • Skipped 0 files when reviewing.
  • Skipped posting 0 drafted comments based on config settings.

Workflow ID: wflow_JTfyiLUwqJUHCRmX


Want Ellipsis to fix these issues? Tag @ellipsis-dev in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@@ -598,9 +598,6 @@ def get_all_parameters(
return list(parameters)

def get_loop_block_context_parameters(self, workflow_run_id: str, loop_data: Any) -> list[ContextParameter]:
Copy link
Contributor

Choose a reason for hiding this comment

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

Consider re-adding the validation for loop_data to ensure it is either a dict or a list. This prevents unexpected errors if the input data type is incorrect.

@wintonzheng wintonzheng merged commit 521e355 into main Dec 4, 2024
2 checks passed
@wintonzheng wintonzheng deleted the shu/loop_task branch December 4, 2024 07:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant