Skip to content

Conversation

@CatsDeservePets
Copy link
Collaborator

This experimental PR aims to improve lf's logging.

  • Add log level and control over them
  • Improve existing log messages
  • Add more debugging logs in some places

I decided against using slog as it does way more things than we need, doesn't support printf function calls and formats the output in weird way (key=value).
I also decided against introducing another third party library so I just wrote a really simple implementation loosely based on slog.

Screenshot 2025-10-20 at 12 57 41 AM

@CatsDeservePets CatsDeservePets added new Pull requests that add new behavior breaking Pull requests that introduce breaking changes labels Oct 19, 2025
@CatsDeservePets
Copy link
Collaborator Author

Hey @joelim-work.
I would also like to know, if this is the right direction here.
This is more of a dirty quick hack to look what is possible.

Copy link
Collaborator

@joelim-work joelim-work left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @CatsDeservePets,

The current log package only provides basic functionality, but I agree that slog is too much if the use case is just to add log levels. I think the decision to include different log levels depends on user needs - I have never needed it myself, but I am fine with the current implementation if you wish to include it so that it makes your life easier when troubleshooting issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking Pull requests that introduce breaking changes new Pull requests that add new behavior

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants