New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revise log messages for #3973 #4287
Conversation
@infotexture, I appreciate this work! It adds polish to the software and makes a good first impression on new users. |
6f31d4d
to
1e5001f
Compare
@jelovirt @robander ❓ Any preference on how to format empty response elements? The vast majority are currently expanded as ➕/➖ We could save a few bytes by collapsing them all, but it would cause more diffs. That said, by the time this PR is ready, we may end up touching most lines anyway, so I'm not sure the extra diffs would be all that disruptive. |
cf6c169
to
067e5b7
Compare
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
7181c96
to
e060b7a
Compare
@infotexture - do you want me to search for obsolete messages? I can script something up for this. |
@chrispy-snps Sure, if you have an easy way of finding those automatically, that would help. 🙏 We may not remove them yet, but could mark them as deprecated/unused. |
Per #4287 (comment) Most are expanded, so this aligns those that were collapsed. Signed-off-by: Roger Sheen <roger@infotexture.net>
@infotexture - here's a Perl script that you can run from the root of the dita-ot development repo: The script does the following:
For conservatism, step 1 considers messages defined in commented code (so we can delete them even if commented), but step 2 does not consider references in commented code. But I might be missing something because it's claiming to find quite a number of unused messages. Can you run this on your side and see what you think? |
@chrispy-snps The script returns 139 supposedly unused message IDs, but the main messages_template.xml file only contains ~160 messages (plus 20-odd more in default plug-ins), so I'm skeptical that that many are really unused. 🧐 My gut feeling says ~80% can't be obsolete. 🤔 If it were ~20% it would seem more plausible, but my Perl fu isn't strong enough to review the logic in the script. @jelovirt @robander Any thoughts? Results
|
— Just a thought: Could it be that the code composes certain message IDs as |
@infotexture - I wondered the same thing, but I could not find any code instances of messages being constructed dynamically like that. The lines in your "results" excerpt seem to have run together. Can you reformat them? I am as perplexed by the results as you are. Hopefully I did something wrong, but if so, I haven't been able to figure it out. |
Sorry, that broke when I deleted an empty line between the ✅ Fiddly formatting fixed. |
@infotexture great job, I skimmed a bit through the updated messages. Looking in the messages templates, there are still places like this where double quotes are still used instead of single quotes like:
Maybe replace "should" with "must" here:
Here maybe remove the last " href=""":
Maybe rephrase messages which contain "will" to avoid future tenses. |
This might be as good a place as any to mention that I tried to create a god-awful Python script with a god-awful regex parse_ot_log.py.txt to parse OT error messages into distinct fields. My latest attempt tried to parse the messages.xml file and use it to compute a regex pattern to parse a log's actual messages. It's a work in progress, to say the least. In some messages no file paths are mentioned, while in others there are 1 or possibly two. Has there been any discussion of also providing an XML version of an OT log so we don't have to infer structure from raw text that already has a structure to begin with? Is an OT-log schema out of the question to pursue separately? My intention is to save a structured representation of these logs in our CI/CD environment so our Information Architecture group can ingest them into a datastore can do analytics on them, if not some ML experiments at some point. I can move this into a discussion if anyone is interested in engaging with it there. |
d5efcf2
to
5644f5a
Compare
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Most are expanded, so this aligns those that were collapsed. Signed-off-by: Roger Sheen <roger@infotexture.net>
Signed-off-by: Roger Sheen <roger@infotexture.net>
Signed-off-by: Roger Sheen <roger@infotexture.net>
Signed-off-by: Roger Sheen <roger@infotexture.net>
Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per - #4287 (comment) - #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
Per #4287 (comment) Signed-off-by: Roger Sheen <roger@infotexture.net>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Really big cleanup project, looks ready to go...
@infotexture - as someone with a technical writing background, this is an impressive piece of work. Thanks for doing it. |
Description
Error message refactoring for #3973
%
placeholders (a17c7c8)(
@rev
attribute,<topicref>
element, etc.)(9d64912, 4253c33 , 13e57f6, and 62c8d0b)