[Python] How to log boto3.dynamodb.conditions meaningfully

Discussão em 'Python' iniciado por Stack, Agosto 7, 2025.

  1. Stack

    Stack Membro Participativo

    I spend a lot of time looking at my service's logs, and seeing messages like this:

    2017-07-26T07:33:00.182089Z PID:(18030) boto3.resources.action [INFO] Calling dynamodb:query with {'Limit': 200, 'KeyConditionExpression': <boto3.dynamodb.conditions.Equals object at 0x7ffe0a29fa20>, 'TableName': ...


    It'd be really nice to see something meaningful in that log message, like Key("foo").eq("bar") -- i.e., the name of the key, and the value, instead of <boto3.dynamodb.conditions.Equals object at 0x7ffe0a29fa20>, which tells me almost nothing. Is there any easy way to get this?

    Continue reading...

Compartilhe esta Página