Skip to content

Discussion: Type handling for OpenAI finish_reasons (Ref PR #8028) #8263

Open

Description

@manojmulammagari

Hi, following up on closed PR #8028 regarding the OpenAI integration. @alexander-alderman-webb mentioned that using hasattr() isn't the right approach here.

Could you provide guidance on the correct way to handle these types within the integration?

Also, to clarify an unresolved point from @chrikrah on issue #7873: should gen_ai.response.finish_reasons be formatted as a list[str] or a JSON string?

Happy to submit a new PR once we agree on the approach!

Activity

  1. linear-code commented on Nov 12, 2026

    @linear-code
  2. moved this to Waiting for: Product Owner in GitHub Issues with 👀 3on Nov 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions