CCC
Convex Community12mo ago
12 replies
CC

SOLVED: User error (Was: Strange PROD behavior with validation)

I am seeing some strange behavior in my prod environment:
Jan 18, 22:46:30
failure

A

messages:send_user_message_on_server
ArgumentValidationError: Value does not match validator.
Path: .persona_id
Value: null
Validator: v.id("nodes")

But the schema is this:
    args: {
        chat_id: v.id('chats'),
        content: v.object({
            message: v.string()
        }),
        persona_id: v.optional(v.id('nodes')),
        source_node_id: v.optional(v.id('nodes'))
    },


How can this be?

The screenshots are attached to show that the server environment has indeed picked up that the persona_id is optional.
Also, the error message in chrome looks different than usual when there is a validation error. And the same code works in dev. The error usually includes the validation error in the Chrome-log. Also, this same code works in the dev-environment.

The request: f82d394c049b7717
Screenshot_2025-01-18_at_22.49.27.png
Screenshot_2025-01-18_at_22.53.14.png
Was this page helpful?