Describe the bug
When the parser encounters the absence of the EE.log
file, it exhibits unexpected behavior, likely terminating the parser with an error.
If the parser finds that the EE.log
lacks data relevant to the Profit Taker run information, it generates an empty JSON {}
. Consequently, this empty JSON causes issues on the app side as it interprets it as an error.
To Reproduce
Steps to reproduce empty JSON:
- Navigate to the directory containing the EE.log file.
- Verify that the EE.log file is empty or lacks relevant data.
- Run the parser.
- Observe the empty JSON generated as output.
Steps to reproduce error:
- Navigate to the directory containing the EE.log file.
- Verify that the EE.log file does not exist
- Run the parser.
- Observe the output.
Expected behavior
The parser should handle scenarios where the EE.log
file is empty or lacks relevant data by sending initialized data instead of an empty JSON. Please note, this should only be done once on launch and should not be stored as a file. It's simply to make sure the app has a stable connection with the parser.
If the EE.log
file is not found, the parser should generate a new JSON containing an error code or message. This approach will enable us to identify and gracefully handle this error within the app by displaying a specific error message telling the user to run Warframe or do a mission to create the EE.log
. The parser can be kept running, checking for the existence of the file every second or, whatever time you feel is most adequate. Don't worry about this running forever, because the app force closes the parser when the app is closed.
Screenshots
Screenshots are not available, but here is the error message when no EE.log
exists:
Traceback (most recent call last):
File "main.py", line 29, in <module>
File "main.py", line 23, in main
File "src\analyzer.py", line 443, in run
File "src\analyzer.py", line 546, in follow_log
File "src\analyzer.py", line 623, in store_start_time
File "src\analyzer.py", line 469, in follow
FileNotFoundError: [WinError 2] The system cannot find the file specified: 'C:\\Users\\user\\AppData\\Local/Warframe/EE.log'
An unknown error occurred. Please screenshot this and report this along with your EE.log attached.
Additional context
N/A.