mirror of
https://github.com/EDCD/EDMarketConnector.git
synced 2025-04-15 08:40:34 +03:00
Reduce some log spam:
* Comment out the traceback in plugins/eddn.py, the return is enough. * 'Called with no event_queue' can be TRACE. * Don't care about "Everything was alright, the near-neutral status just wasn't stored." from Inara.
This commit is contained in:
parent
6764cab36f
commit
aab2a58a2d
@ -845,7 +845,7 @@ class EDLogs(FileSystemEventHandler): # type: ignore # See below
|
||||
return None
|
||||
|
||||
if not self.event_queue:
|
||||
logger.debug('Called with no event_queue')
|
||||
logger.trace('Called with no event_queue')
|
||||
return None
|
||||
|
||||
else:
|
||||
|
@ -6,7 +6,6 @@ import pathlib
|
||||
import re
|
||||
import sys
|
||||
import tkinter as tk
|
||||
import traceback
|
||||
from collections import OrderedDict
|
||||
from os import SEEK_SET
|
||||
from os.path import join
|
||||
@ -187,9 +186,10 @@ Msg:\n{msg}'''
|
||||
|
||||
# Paranoia check in case this function gets chain-called.
|
||||
if not self.replaylog:
|
||||
logger.error(
|
||||
f'self.replaylog (type: {type(self.replaylog)}) is falsey after update_idletasks(). Traceback:\n'
|
||||
f'{"".join(traceback.format_list(traceback.extract_stack()))}')
|
||||
# import traceback
|
||||
# logger.error(
|
||||
# f'self.replaylog (type: {type(self.replaylog)}) is falsey after update_idletasks(). Traceback:\n'
|
||||
# f'{"".join(traceback.format_list(traceback.extract_stack()))}')
|
||||
return
|
||||
|
||||
try:
|
||||
|
@ -1275,8 +1275,11 @@ def send_data(url: str, data: Mapping[str, Any]) -> bool:
|
||||
# Log individual errors and warnings
|
||||
for data_event, reply_event in zip(data['events'], reply['events']):
|
||||
if reply_event['eventStatus'] != 200:
|
||||
logger.warning(f'Inara\t{status} {reply_event.get("eventStatusText", "")}')
|
||||
logger.debug(f'JSON data:\n{json.dumps(data_event)}')
|
||||
if ("Everything was alright, the near-neutral status just wasn't stored."
|
||||
not in reply_event.get("eventStatusText")):
|
||||
logger.warning(f'Inara\t{status} {reply_event.get("eventStatusText", "")}')
|
||||
logger.debug(f'JSON data:\n{json.dumps(data_event)}')
|
||||
|
||||
if reply_event['eventStatus'] // 100 != 2:
|
||||
plug.show_error(_('Error: Inara {MSG}').format(
|
||||
MSG=f'{data_event["eventName"]},'
|
||||
|
Loading…
x
Reference in New Issue
Block a user