Skip to content

Failed to read prompt from stdin: stream did not contain valid UTF-8 #8733

@ftufkc

Description

@ftufkc

What version of Codex is running?

v0.77.0

What subscription do you have?

plus

Which model were you using?

gpt-5.2-codex

What platform is your computer?

Linux 5.10.0

What issue are you seeing?

When I use codex to execute codex exec -s danger-full-access --json - < "${WORKSPACE}/prompt.txt" > "${WORKSPACE}/result_temp.log". It reported an error Failed to read prompt from stdin: stream did not contain valid UTF-8.Is this because of the codex's own limitations that I can only input UTF-8 text? If so, what can I do to bypass it? For example, should I first convert prompt.txt to UTF-8 format?

What steps can reproduce the bug?

execute codex exec -s danger-full-access --json - < "${WORKSPACE}/prompt.txt" > "${WORKSPACE}/result_temp.log". When prompt.txt is not a text that is entirely composed of utf8.

What is the expected behavior?

No response

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingexecIssues related to the `codex exec` subcommand

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions