-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
Installation for the readme says to run: pip install nginx-monitor, but it appears it should be nginx-parser instead: https://pypi.org/project/nginx-parser/0.1/
The time parser cannot handle offsets, instead of '%d/%b/%Y:%H:%M:%S +0000' it should be '%d/%b/%Y:%H:%M:%S %z' here:
Line 42 in 591dfb3
| TIME_LOCAL_FORMAT = '%d/%b/%Y:%H:%M:%S +0000' |
strptime(): https://www.programiz.com/python-programming/datetime/strptime
It would make sense to also be able to override that time string in the configuration too as is done for LOG_FORMAT. Something like:
def get_time_local_format(self):
if self.time_local_format is not None:
return self.time_local_format
try:
self.time_local_format = self.yaml_config['nginx']['time_local_format']
except (KeyError, TypeError):
self.time_local_format self.TIME_LOCAL_FORMAT
return self.time_local_formatReactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels