Skip to content

Conversation

@m-y-mo
Copy link
Contributor

@m-y-mo m-y-mo commented Oct 22, 2025

Fix reusable prompt example after #16 switched to use filekeys.

Drive by: Add error message that includes available taskflows when the taskflow is not found.

Copilot AI review requested due to automatic review settings October 22, 2025 11:40
Copy link
Contributor

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 fixes a reusable prompt example that broke after PR #16 switched to using filekeys, and adds an improved error message when a taskflow is not found.

Key Changes:

  • Updated prompt reference syntax to use the new filekey format (PROMPTS_ prefix without .yaml extension)
  • Enhanced error handling to display available taskflows when an invalid taskflow is requested

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
taskflows/examples/example_reusable_prompt.yaml Updated prompt reference from old path format to new filekey format with PROMPTS_ prefix
main.py Added user-friendly error message listing available taskflows before raising ValueError

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Tell me more about apples.
{{ GitHubSecurityLab/seclab-taskflow-agent/prompts/examples/example_prompt.yaml }}
{{ PROMPTS_GitHubSecurityLab/seclab-taskflow-agent/prompts/examples/example_prompt }}
Copy link
Collaborator

Choose a reason for hiding this comment

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

This was actually a deliberate change because the "PROMPTS" thing wasn't working. Do you know where that mechanism is implemented?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It's probably because you didn't change the prompt path to match the filekey. It's implemented here: https://github.com/GitHubSecurityLab/seclab-taskflow-agent/blob/main/main.py#L466 Maybe the error message there should also list the available prompts

@m-y-mo m-y-mo merged commit 213b161 into main Oct 22, 2025
5 checks passed
@m-y-mo m-y-mo deleted the fix_reusable_prompt branch October 22, 2025 13:59
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.

3 participants