Skip to content

AI provider specific headers aren't correctly redacted #6525

Description

@pawelblaszczyk5

What version of Effect is running?

4.0.0-beta.100

What steps can reproduce the bug?

  1. Use any AI provider that has custom headers that are set as redacted, e.g. OpenAI
  2. Observe headers not being redacted correctly because the service Headers.CurrentRedactedNames is updated only for the construction (if I understand correctly)

Reproduction: https://github.com/pawelblaszczyk5/effect-smoll-reproductions/blob/d2d8f44a1c3f667fda2e024e15a4febd0507912d/headers-not-redacted.ts

Image

What is the expected behavior?

Headers are correctly redacted

What do you see instead?

Headers aren't redacted

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions