You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
A-LoggingSynapse's logs (structured or otherwise). Not metrics.A-TestingIssues related to testing in complement, synapse, etcT-DefectBugs, crashes, hangs, security vulnerabilities, or other reported issues.
Currently, the log lines in _trial_temp/test.log seem way too verbose and duplicate the timestamp for some reason. It's the exact same time in both places but one with timezone offset and one with millisecond precision.
Remove duplicate timestamps from _trial_temp/test.log log formatting
The text was updated successfully, but these errors were encountered:
MadLittleMods
added
A-Logging
Synapse's logs (structured or otherwise). Not metrics.
T-Defect
Bugs, crashes, hangs, security vulnerabilities, or other reported issues.
A-Testing
Issues related to testing in complement, synapse, etc
labels
May 18, 2023
…15636)
Fix#15618
### Before
```
2023-05-17 22:51:36-0500 [-] 2023-05-17 22:51:36,889 - synapse.server - 338 - INFO - sentinel - Finished setting up.
```
### After
```
2023-05-19 18:16:20-0500 [-] synapse.server - 338 - INFO - sentinel - Finished setting up.
```
### Dev notes
The `Twisted.Logger` controls the `2023-05-19 18:16:20-0500 [-]` prefix, see : [`twisted/twisted` -> `src/twisted/logger/_format.py#L362-L374`](https://github.com/twisted/twisted/blob/34b161e66bc7c9f9efbb95e82c770a863933e498/src/twisted/logger/_format.py#L362-L374)
And we delegate our logs to the Twisted Logger for the tests which puts it in `_trial_temp/test.log`
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
A-LoggingSynapse's logs (structured or otherwise). Not metrics.A-TestingIssues related to testing in complement, synapse, etcT-DefectBugs, crashes, hangs, security vulnerabilities, or other reported issues.
Currently, the log lines in
_trial_temp/test.log
seem way too verbose and duplicate the timestamp for some reason. It's the exact same time in both places but one with timezone offset and one with millisecond precision._trial_temp/test.log
This is in contrast to my own
homeserver.log
which uses the same logging format as what the tests seem to use but only has theasctime
as expected,synapse/tests/test_utils/logging_setup.py
Lines 43 to 46 in 41b9def
If you remove
%(asctime)s -
from the test logging setup, the logs in_trial_temp/test.log
still end up with a timestamp 🤔:Definition of done
_trial_temp/test.log
log formattingThe text was updated successfully, but these errors were encountered: