Skip to content

Creation of files via creating a script to create a file. #20067

@vsukhoml

Description

@vsukhoml

What happened?

I noticed behavior when gemini-cli with 3.1 and 3.0 Gemini Pro models instead of directly creating a file, creates a Python script which creates the file and writes the context. Specific files created - ".c" and ".h" file for C language. While it works, why not to use WriteFile tool directly to create a file? Often, it keeps those temporary "tools" in the working directory, and this require manual clean-up.

I'll try to find if this is captured somewhere in the logs.

I suppose that WriteFile tool should probably be updated with instruction to remove intermediate files it created to perform required action and to use WriteFile directly to create / update file instead.

What did you expect to happen?

I'd expect WriteFile to be used directly and no left-over files (Python scripts to create files) in the working directory.

Client information

Client Information

Run gemini to enter the interactive CLI, then run the /about command.

> /about
# paste output here

Login information

No response

Anything else we need to know?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    status/need-triageIssues that need to be triaged by the triage automation.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions