fix: update task tracker storage location in system prompt#24034
fix: update task tracker storage location in system prompt#24034
Conversation
🧠 Model Steering GuidanceThis PR modifies files that affect the model's behavior (prompts, tools, or instructions).
This is an automated guidance message triggered by steering logic signatures. |
|
Size Change: +158 B (0%) Total Size: 34.6 MB
ℹ️ View Unchanged
|
34e95a2 to
fce7087
Compare
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request addresses an issue where the system prompt provided an incorrect storage location for the task tracker. The changes ensure that the agent is accurately informed of the task tracker's dynamic file-based storage path, improving the reliability and correctness of task management operations by the agent. This involves updating prompt generation logic and associated tests to reflect the correct path. Highlights
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request updates the task management protocol to use a dynamic file-based task tracking path instead of a hardcoded one. Changes include updating the prompt rendering logic to accept a directory string, modifying the configuration interfaces, and adding tests to verify the correct path is included in the system prompt. A review comment suggests refactoring the promptProvider.ts file to extract the repeated logic for retrieving the tracker directory into a single variable for better maintainability.
There was a problem hiding this comment.
Code Review
This pull request transitions the task tracker from using a hardcoded storage path to a dynamic one retrieved from the configuration. The system prompt now correctly reflects the actual tracker directory. Feedback focuses on refactoring redundant path retrieval logic in promptProvider.ts into a local variable for better maintainability and removing the unused taskTracker property from the PlanningWorkflowOptions interface in both the modern and legacy snippet files.
Note: Security Review did not run due to the size of the PR.
77c90e9 to
df1df74
Compare
There was a problem hiding this comment.
Code Review
This pull request replaces the hardcoded task tracker storage path in the system prompt with a dynamic path retrieved from the environment configuration. Changes include updates to the PromptProvider to pass the directory string to prompt snippets, corresponding type changes in the snippet options, and new evaluation tests to verify the path's presence in the prompt. A security concern was raised regarding the lack of sanitization for the trackerDir variable before its interpolation into the system prompt, which could potentially allow for prompt injection if the path contains control characters.
Fixes #22995.
This PR updates the system prompt to accurately inform the agent of the task tracker's true storage location.
Key changes:
~/.gemini/tmp/...) into the system prompt.BasePromptOptionsandrenderTaskTrackerto handle the dynamic path.PromptProviderpasses the correct directory.