Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

How to get the file and name of the log line #40

Copy link
Copy link
@river-walras

Description

@river-walras
Issue body actions

I want a custome output to get the line and the file of the output log. I tried

logger.set_pattern("[%Y-%m-%d %H:%M:%S.%e] [%n] [%^%l%$] [%@] %v")

However, the [%@] seems not working, I know I can using inspect, but it is not a performant way

I expected to get

[2024-12-30 16:03:42.268] [test] [critical] [your_script.py:123] This is a critical message

But the line and file braket is always empty.

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      Morty Proxy This is a proxified and sanitized view of the page, visit original site.