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

Don't configure automatically #194

Closed
alexmojaki opened this issue May 19, 2024 · 1 comment · Fixed by #219
Closed

Don't configure automatically #194

alexmojaki opened this issue May 19, 2024 · 1 comment · Fixed by #219

Comments

@alexmojaki
Copy link
Contributor

As announced in https://pydanticlogfire.slack.com/archives/C06EDRBSAH3/p1716143149301069, the log/span/instrument methods shouldn't implicitly initialize config. This requires a few steps:

  1. Make sure that all docs explicitly call logfire.configure() before anything else.
  2. logfire.instrument_*() methods #193 so that instument_* methods can emit a warning if called before configuring. Currently the problem is that users may call e.g. SQLAlchemyInstrumentor().instrument() and forget to configure and we can't do anything about that.
  3. Emit warnings when calling methods before configure.
  4. Stop emitting spans (but keep the warning) when calling methods before configure.
@bllchmbrs
Copy link
Contributor

Please!

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 a pull request may close this issue.

2 participants