AmigaPorts / AmigaPorts/ACE

Unify logging

未关闭
#60 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement help wanted question
主要语言
C
星标
223
派生
38
平均合并
1 天 5 小时
30 天内合并 PR
6

描述

- Currently there is game.log and memory.log. Having mem logged in separate file makes it hard to determine where and when specifically given alloc is taking place.
- To unify it into single file, we need something to differentiate mem and other stuff in clean and filterable/searchable way (as easy as ctrl+f). Also, game logging should be distinct from ACE stuff, but still in same file.
- We lack standard means to print warnings and errors. Currently I mostly use `WARN:` and `ERR:` prefixes, but some messages aren't still conforming to this. When other contributions arrive, it's going to be even bigger mess. Having fns like `logErr`, `logWarn` and `logInfo` might be a good idea.
- Log categories could be mutable (as in _mute_) so that reading logs would be easier. But it's something that can be bypassed by filtering.
- Also, logs should have no footprint on release builds and be non-existent there.

Any ideas?

---

I've started doing this but needs further work, I think

- [x] move memory and general logging to same output
- [x] add ability to output to file or WinUAE debug console
- [ ] add consistent log message types (warning, error, info, etc.)

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。