Skip to content

Default message discriminator #1

Closed

Description

@furkan-guvenc

Hi, haven't tried the package but it seems well thought.

It seems we can change the discriminator_field from action to anything but BaseMessage defines it as action and it check subclasses that it used as it. How does it work?

Activity

  1. huynguyengl99 commented on Oct 22, 2025

    @huynguyengl99
    Collaborator

    Hi @furkan-guvenc, previously, I made the BaseMessage’s action field somewhat dynamic when chanx only supported Django, allowing users to configure it via Django settings. However, after the major migration to support FastAPI and other ASGI-based frameworks, the approach was adjusted a bit.

    Currently, it’s not supported to use a discriminator_field other than action. I might reintroduce support for a dynamic discriminator_field in the future, but I’ll need to find a solid approach that works well for both Django and FastAPI — so it may take a few days to implement.

  2. added
    enhancement
    on Oct 22, 2025
  3. locked and limited conversation to collaborators on Dec 27, 2025
  4. converted this issue into a discussion #4 on Dec 27, 2025
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

    enhancementfuture

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions