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

Add Task v2 Block #1683

Merged
merged 3 commits into from
Jan 30, 2025
Merged

Add Task v2 Block #1683

merged 3 commits into from
Jan 30, 2025

Conversation

wintonzheng
Copy link
Contributor

@wintonzheng wintonzheng commented Jan 30, 2025

Important

Add Task v2 Block to Skyvern workflow editor with new node type, UI components, and YAML support.

  • Behavior:
    • Introduces Taskv2Node in Taskv2Node.tsx to handle Task v2 blocks with properties like prompt, url, maxIterations, totpVerificationUrl, and totpIdentifier.
    • Adds taskv2 to helpContent.ts with specific tooltips and placeholders.
  • Types and Models:
    • Defines Taskv2NodeData and Taskv2Node types in types.ts.
    • Updates WorkflowBlockTypes and WorkflowBlock in workflowTypes.ts to include task_v2.
    • Adds Taskv2BlockYAML type in workflowYamlTypes.ts.
  • UI Components:
    • Updates WorkflowBlockIcon.tsx to include icon for task_v2.
    • Adds Taskv2Node to index.ts and WorkflowNodeLibraryPanel.tsx for node library integration.
  • Utilities:
    • Modifies workflowEditorUtils.ts to handle conversion and creation of task_v2 nodes and YAML blocks.

This description was created by Ellipsis for 5beb30c. It will automatically update as commits are pushed.

<!-- ELLIPSIS_HIDDEN -->

> [!IMPORTANT]
> Add Task v2 Block to Skyvern workflow editor with new node type, UI components, and YAML conversion logic.
>
>   - **Behavior**:
>     - Introduces `Taskv2Node` in `Taskv2Node.tsx` with properties like `prompt`, `url`, `maxIterations`, `totpVerificationUrl`, and `totpIdentifier`.
>     - Adds `taskv2` to `helpTooltips` and `placeholders` in `helpContent.ts` with specific content for `maxIterations` and `prompt`.
>     - Updates `WorkflowNodeLibraryPanel.tsx` to include `Task v2 Block` in the node library.
>   - **Models**:
>     - Defines `Taskv2NodeData` and `Taskv2Node` types in `types.ts` with default values.
>     - Adds `Taskv2Block` type to `workflowTypes.ts` and `Taskv2BlockYAML` to `workflowYamlTypes.ts`.
>   - **UI Components**:
>     - Updates `WorkflowBlockIcon.tsx` to use `ListBulletIcon` for `task_v2`.
>     - Adds `Taskv2NodeComponent` to `index.ts` for node registration.
>   - **YAML Conversion**:
>     - Updates `workflowEditorUtils.ts` to handle `task_v2` in `convertToNode`, `createNode`, `getWorkflowBlock`, and `convertBlocksToBlockYAML`.
>
> <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 c84b962e0c7b079036cc5ea9d84ae1744f3ff1fe. It will automatically update as commits are pushed.</sup>

<!-- ELLIPSIS_HIDDEN -->
…src/'

<!-- ELLIPSIS_HIDDEN -->

> [!IMPORTANT]
> Add Task v2 Block to Skyvern workflow editor with new node type, UI components, and YAML conversion logic.
>
>   - **Behavior**:
>     - Introduces `Taskv2Node` in `Taskv2Node.tsx` with properties like `prompt`, `url`, `maxIterations`, `totpVerificationUrl`, and `totpIdentifier`.
>     - Adds `taskv2` to `helpTooltips` and `placeholders` in `helpContent.ts` with specific content for `maxIterations` and `prompt`.
>     - Updates `WorkflowNodeLibraryPanel.tsx` to include `Task v2 Block` in the node library.
>   - **Models**:
>     - Defines `Taskv2NodeData` and `Taskv2Node` types in `types.ts` with default values.
>     - Adds `Taskv2Block` type to `workflowTypes.ts` and `Taskv2BlockYAML` to `workflowYamlTypes.ts`.
>   - **UI Components**:
>     - Updates `WorkflowBlockIcon.tsx` to use `ListBulletIcon` for `task_v2`.
>     - Adds `Taskv2NodeComponent` to `index.ts` for node registration.
>   - **YAML Conversion**:
>     - Updates `workflowEditorUtils.ts` to handle `task_v2` in `convertToNode`, `createNode`, `getWorkflowBlock`, and `convertBlocksToBlockYAML`.
>
> <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 c84b962e0c7b079036cc5ea9d84ae1744f3ff1fe. 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.

👍 Looks good to me! Incremental review on 2650f61 in 1 minute and 37 seconds

More details
  • Looked at 513 lines of code in 12 files
  • Skipped 0 files when reviewing.
  • Skipped posting 7 drafted comments based on config settings.
1. skyvern-frontend/src/routes/workflows/editor/nodes/WorkflowBlockIcon.tsx:57
  • Draft comment:
    Inconsistent naming: 'task_v2' is used here, but 'taskv2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Decided after close inspection that this draft comment was likely wrong and/or not actionable:
    The comment points to a potential cross-file issue, claiming there's inconsistent naming in other parts of the codebase. However, we can only see this file, and one of our rules is to ignore cross-file issues. We can't verify if there's actually an inconsistency without seeing the other files where 'taskv2' is supposedly used.
    What if this inconsistency actually exists and could cause real problems? What if this is a legitimate concern that should be addressed?
    While the inconsistency might exist, we're explicitly told to ignore cross-file issues and only focus on the file being reviewed. We don't have strong evidence within this file to support keeping this comment.
    Delete the comment because it refers to a potential cross-file issue that we can't verify within the scope of this file review.
2. skyvern-frontend/src/routes/workflows/editor/nodes/index.ts:60
  • Draft comment:
    Inconsistent naming: 'taskv2' is used here, but 'task_v2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Marked as duplicate.
3. skyvern-frontend/src/routes/workflows/editor/nodes/types.ts:49
  • Draft comment:
    Inconsistent naming: 'task_v2' is used here, but 'taskv2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Marked as duplicate.
4. skyvern-frontend/src/routes/workflows/editor/panels/WorkflowNodeLibraryPanel.tsx:71
  • Draft comment:
    Inconsistent naming: 'taskv2' is used here, but 'task_v2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Marked as duplicate.
5. skyvern-frontend/src/routes/workflows/editor/workflowEditorUtils.ts:208
  • Draft comment:
    Inconsistent naming: 'taskv2' is used here, but 'task_v2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Marked as duplicate.
6. skyvern-frontend/src/routes/workflows/editor/workflowEditorUtils.ts:674
  • Draft comment:
    Inconsistent naming: 'taskv2' is used here, but 'task_v2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Marked as duplicate.
7. skyvern-frontend/src/routes/workflows/editor/workflowEditorUtils.ts:893
  • Draft comment:
    Inconsistent naming: 'task_v2' is used here, but 'taskv2' is used elsewhere. Ensure consistent naming across the codebase to avoid confusion and potential bugs.
  • Reason this comment was not posted:
    Marked as duplicate.

Workflow ID: wflow_Nc7QnOgCby4oye3g


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

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 2650f61 in 1 minute and 37 seconds

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

Workflow ID: wflow_f28w7Fc93PrxDsVH


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.

@@ -64,14 +63,11 @@ def get_tzinfo_from_proxy(proxy_location: ProxyLocation) -> ZoneInfo | None:
return ZoneInfo("Asia/Kolkata")

if proxy_location == ProxyLocation.RESIDENTIAL_JP:
return ZoneInfo("Asia/Tokyo")
return ZoneInfo("Asia/Kolkata")
Copy link
Contributor

Choose a reason for hiding this comment

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

The timezone for ProxyLocation.RESIDENTIAL_JP should be Asia/Tokyo instead of Asia/Kolkata.

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.

👍 Looks good to me! Incremental review on 5beb30c in 18 seconds

More details
  • Looked at 54 lines of code in 3 files
  • Skipped 0 files when reviewing.
  • Skipped posting 1 drafted comments based on config settings.
1. skyvern/forge/sdk/schemas/tasks.py:66
  • Draft comment:
    Corrected timezone for RESIDENTIAL_JP from Asia/Kolkata to Asia/Tokyo. Ensure this change is intentional and consistent with the application's requirements.
  • Reason this comment was not posted:
    Confidence changes required: 50%
    The PR adds a new proxy location 'ResidentialDE' to the ProxyLocation enum and updates the ProxySelector component to include this new location. The changes are consistent across the files, ensuring that the new proxy location is available in both the frontend and backend. However, there is a minor issue with the timezone mapping for 'RESIDENTIAL_JP' in the get_tzinfo_from_proxy function, which was corrected in this PR. The rest of the changes are straightforward and align with the intent of adding a new proxy location.

Workflow ID: wflow_OQ0pl9KbZsTbdIo7


You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet mode, and more.

@msalihaltun msalihaltun merged commit d218391 into main Jan 30, 2025
7 checks passed
@msalihaltun msalihaltun deleted the salih/add-task-v2-block-frontend branch January 30, 2025 18:13
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.

2 participants