First zellij log file format parser #1475
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hello,
I’m new to
lnav
and it looks like a very good project that I would have a hard time to learn since it does not understand the log format of tools I’m developing against regularly. So I went ahead and created a "parser" (not sure how you call them) forzellij
which is a terminal multiplexer (a bit liketmux
orscreen
but different).I’m seeing 2 log variant and asked if there are others. I also asked if a "producer id" (
lnav
'sopid-field
) could be added to quickly filter the server, each clients and each plugin’s instances. I also asked if they have better name for some capture groups (module
andmodule2
don’t feels good 😅)Anyway I have this 1st implementation where I have some questions/issues:
"file-pattern"
field with the most common log file path. I’m not sure it is necessary (or even a good idea), since almost no other formats appear to have it.cause_body
field is alwaysnull
, I’m not sure why sincemultiline
default totrue
. This is an optional field of multi-line log that regex101.com correctly detected.<cause_id>: <cause_log>
. Is this useful in your experience or too much? I did not achieved it on regex101.com, since I’m not sure how dynamically increment capture group’s names.Note: I did not compile this branch, I’m hoping that test done using the file installed in
~/.config/lnav/formats/installed
give the same results as compiled in.