Skip to content

Codex requires imagegen deplyment when changing code #31775

Closed

Description

@JanekRzodki

What version of Codex CLI is running?

codex-cli 0.131.0

What subscription do you have?

pay-as-you-go

Which model were you using?

gpt-5.3-codex

What platform is your computer?

No response

What terminal emulator and version are you using (if applicable)?

No response

Codex doctor report

What issue are you seeing?

i ve been using codex as a vs codex extension for a long time with a Azure Ai Fundry endpoint. Everything worked fine untill today. When I want to change code i get the error: imagegen deployment must be provided through header: x-ms-oai-image-generation-deployment.

Why all of a sudden codex is asking for imagegen deployment?

What steps can reproduce the bug?

azure endpoint
vs code codex extension
gpt-5..3-codex
asking to change the code

What is the expected behavior?

error: imagegen deployment must be provided through header: x-ms-oai-image-generation-deployment.

Additional information

No response

Activity

  1. added
    bug
    on Jul 9, 2026
  2. added
    extension
    azure
    on Jul 9, 2026
  3. ahlner commented on Jul 9, 2026

    @ahlner

    Same Problem with the Codex App: Version 26.623.141536 • Released Jul 7, 2026. It's completely unusable with Azure AI Foundry.

    The switch

    [features]
    image_generation = false

    works on the cli, but not in the app.

  4. github-actions commented on Jul 9, 2026

    @github-actions
    Contributor

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

  5. JanekRzodki commented on Jul 9, 2026

    @JanekRzodki
    Author

    in terminal I logged out of the codex: codex logout and then i logged in again and the problem disapeared afer few minutes.
    I don't know if it was re-logging that helped or it was just a temporary bug.

    Anyone else having the issue?

  6. JanekRzodki commented on Jul 9, 2026

    @JanekRzodki
    Author

    The problem came back again. even codex app and CLI is not working properly.
    Logs from the vs code extension when prompting "hi" in a new chat:
    Codex_logs.log

  7. joaquinsc999 commented on Jul 9, 2026

    @joaquinsc999

    Same problem here

  8. JanekRzodki commented on Jul 9, 2026

    @JanekRzodki
    Author

    reinstalling codex CLI worked and CLI works but I can not figure out vs code extension - reinstall is not working

  9. Neel-Error404 commented on Jul 9, 2026

    @Neel-Error404

    facing same issue

  10. nookesh-ai commented on Jul 9, 2026

    @nookesh-ai

    facing same issue

  11. JanekRzodki commented on Jul 9, 2026

    @JanekRzodki
    Author

    codex maintanance team pls hear our prayers 🙏

  12. Hypernut commented on Jul 9, 2026

    @Hypernut

    same problem but with a GPT 5.5 and a 5.4 deployment. Seems to be not tied to a specific GPT version.

  13. mur-anc commented on Jul 9, 2026

    @mur-anc

    facing same issue

  14. KawaiiSh1zuku commented on Jul 10, 2026

    @KawaiiSh1zuku

    same problem here

  15. lianneli commented on Jul 10, 2026

    @lianneli

    facing same issue

  16. TreeOfLearning commented on Jul 10, 2026

    @TreeOfLearning

    As a workaround, you can deploy a gpt-image-2 instance, and then set this under your azure provider in config.toml:

    http_headers = { "x-ms-oai-image-generation-deployment" = "gpt-image-2" }

  17. Hundsmuhlen commented on Jul 10, 2026

    @Hundsmuhlen

    Just had to update mine to v0.144.1 and that resolved the problem

  18. JanekRzodki commented on Jul 10, 2026

    @JanekRzodki
    Author

    it turns out that you can even type an imagegen deployment name that you don't have like "abcd".
    After that vs code extension works after restarting.

    As a workaround, you can deploy a gpt-image-2 instance, and then set this under your azure provider in config.toml:

    http_headers = { "x-ms-oai-image-generation-deployment" = "gpt-image-2" }

  19. JanekRzodki commented on Jul 11, 2026

    @JanekRzodki
    Author

    Codex (5.3 at least) is being migrated into gpt-5.4, so it will no longer be usable.

    Just create gpt-5.4 deployment in AI Foundry and change config.toml in your .codex direcotry to use gpt-5.4 model.

  20. JanekRzodki commented on Jul 12, 2026

    @JanekRzodki
    Author

    If you want to still use gpt-5.3-codex change codex cli version to 0.142.5, uninstall vs code extension, clear vs code globalstorage cache, install a 1-2 week old version and it should work fine.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    azurebugextensionimagen

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions