Skip to content

Conversation

@andrei-21
Copy link
Contributor

@andrei-21 andrei-21 commented Jun 27, 2025

The log!() macro defaults to using the module path as the log target when no target is specified.
Explicitly setting the log target to the module path enables better integration with other logging crates,
such as env_logger, allowing them to filter logs by target (e.g., via env_logger::Builder::parse_filters()).

The `log!()` macro defaults to using the module path as the log target when no target is specified.
Explicitly setting the log target to the module path enables better integration with other logging crates,
such as `env_logger`, allowing them to filter logs by target (e.g., via `env_logger::Builder::parse_filters()`).
@ldk-reviews-bot
Copy link

ldk-reviews-bot commented Jun 27, 2025

👋 Thanks for assigning @tnull as a reviewer!
I'll wait for their review and will help manage the review process.
Once they submit their review, I'll check if a second reviewer would be helpful.

@tnull tnull requested review from tnull and removed request for joostjager June 27, 2025 11:16
Copy link
Collaborator

@tnull tnull left a comment

Choose a reason for hiding this comment

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

I'm not sure I understand your commit message. Are you saying it's defaulting to the local module path rather than record.module_path? Could you provide a proper rationale for the change, i.e., why it is required and what the effect on the log output is exactly?

Also, note that this doesn't build currently.

@andrei-21 andrei-21 force-pushed the feature/set-log-target branch from b4065ee to 1199f7d Compare June 27, 2025 11:48
@andrei-21
Copy link
Contributor Author

I updated the description and fixed the compilation problem.

Copy link
Collaborator

@tnull tnull left a comment

Choose a reason for hiding this comment

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

Makes sense, thanks!

@tnull tnull merged commit 243c874 into lightningdevkit:main Jun 27, 2025
19 of 33 checks passed
@andrei-21 andrei-21 deleted the feature/set-log-target branch June 27, 2025 13:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants