Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support enabling tracing #291

Merged
merged 1 commit into from
Nov 17, 2023
Merged

Conversation

hyf0
Copy link
Member

@hyf0 hyf0 commented Nov 16, 2023

.with_default_directive(LevelFilter::TRACE.into())
.from_env_lossy(),
)
.with(fmt::layer().pretty().without_time())
Copy link
Contributor

Choose a reason for hiding this comment

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

looks like both of these functions are basically the same except this line. can they be shared somehow?

Copy link
Member Author

@hyf0 hyf0 Nov 17, 2023

Choose a reason for hiding this comment

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

Yeah. I tried before. It's a little difficult due to generics. Every call of .with return a new type, I have to use macros to shared the logic. I don't prefer(unless I have to) to write the macros now and it may have better solutions, so I just leave it what it is now :).

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah yeah that makes sense. kind of hate the builder pattern sometimes because of this.

@hyf0 hyf0 force-pushed the 11-16-feat_support_to_enable_tracing branch from 009fd01 to 05b89f0 Compare November 17, 2023 05:19
@hyf0
Copy link
Member Author

hyf0 commented Nov 17, 2023

Merge activity

  • Nov 17, 12:38 AM: @hyf0 started a stack merge that includes this pull request via Graphite.
  • Nov 17, 12:38 AM: @hyf0 merged this pull request with Graphite.

@hyf0 hyf0 merged commit 8310a17 into main Nov 17, 2023
4 of 5 checks passed
@hyf0 hyf0 deleted the 11-16-feat_support_to_enable_tracing branch November 17, 2023 05:38
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.

None yet

3 participants