Log to console with logfire only in development
This commit is contained in:
parent
5edae13cc0
commit
7ccabf4fb9
1 changed files with 5 additions and 1 deletions
|
|
@ -88,7 +88,11 @@ def main(
|
||||||
try:
|
try:
|
||||||
import logfire
|
import logfire
|
||||||
|
|
||||||
logfire.configure(send_to_logfire="if-token-present")
|
is_production = get_config().environment != "development"
|
||||||
|
logfire.configure(
|
||||||
|
send_to_logfire="if-token-present",
|
||||||
|
console=False if is_production else None,
|
||||||
|
)
|
||||||
logfire.instrument_pydantic_ai()
|
logfire.instrument_pydantic_ai()
|
||||||
except Exception:
|
except Exception:
|
||||||
pass
|
pass
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue