apex / apex/log

Add caller (file:line number) to non-tracing entries?

Đang mở
#44 8 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
Go
Star
1.4k
Fork
110
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Any opinions on this? It's available from `runtime.Caller`. Following the current design, it could be enabled by having a function like `log.IncludeCaller(bool)` and then every entry would include a field `caller` with value `file:line number`). Could also implement this as the default log library handles flags, e.g. `log.SetFlags(log.LstdFlags | log.Lshortfile)`.

I'm happy to create a PR for this if you'd like.

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.