dbt-labs / dbt-labs/docs.getdbt.com
[Core] Configurability of the timestamps in logs
- Dominant language
- JavaScript
- Stars
- 215
- Forks
- 1.2k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 130
Description
### Link to the page(s) on docs.getdbt.com requiring updates
https://docs.getdbt.com/reference/global-configs/logs#log-formatting
### Tell us more about this update
Consider adding [this](https://github.com/dbt-labs/dbt-core/issues/5267#issuecomment-2152550358) information more explicitly (rather than just showing via the examples).
There is _some_ of amount of configurability of the time zone and precision of timestamps via the [`LOG_FORMAT`](https://docs.getdbt.com/reference/global-configs/logs#log-formatting) and [`LOG_FORMAT_FILE`](https://docs.getdbt.com/reference/global-configs/logs#log-formatting) configs. Here's a brief summary:
| Log format | Time zone | Aware vs. naive | Precision |
|------------|------------------------|-----------------|-------------|
| `text` | UTC | [naive](https://docs.python.org/3/library/datetime.html#aware-and-naive-objects) timestamp | second |
| `debug` | system local time zone | [naive](https://docs.python.org/3/library/datetime.html#aware-and-naive-objects) timestamp | microsecond |
| `json` | UTC | [aware](https://docs.python.org/3/library/datetime.html#aware-and-naive-objects) timestamp | microsecond |
There's some more nitty-gritty code details discussed [here](https://github.com/dbt-labs/docs.getdbt.com/pull/5578).
### Reviewers/Stakeholders/SMEs
📆 Timestamps Doug
### Related GitHub issues
- https://github.com/dbt-labs/dbt-core/issues/5267
- https://github.com/dbt-labs/docs.getdbt.com/issues/5577
- https://github.com/dbt-labs/docs.getdbt.com/pull/5578
### Additional information
_No response_
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.