Repository navigation
Convert OperatingSystem documentation to Markdown - #5710
Conversation
pekkaklarck
left a comment
There was a problem hiding this comment.
Looks really good in general! There are some recurring issues with examples, Args/Returns placement and linking to other libraries as well as some other smallish issues.
Are you @coyaSONG around so that you can take a look at my comments and fix the issues? If you are busy, I can also merge this PR in its current format and me or someone else can fix the problems.
|
Did you @coyaSONG notice the review? It would be great if you could take a look at my comments. If you don't have time for that, you could just remove the draft status from this PR and we can make those adjustments ourselves. |
# Conflicts: # src/robot/libraries/OperatingSystem.py
|
@pekkaklarck The follow-up at 5deb3e4 addresses the review feedback: Markdown formatting and reference targets were corrected, |
pekkaklarck
left a comment
There was a problem hiding this comment.
Looks very good! I added some comments so please take a look at them.
| | `[chars]` | One character in the bracket | | ||
| | `[!chars]` | One character not in the bracket | | ||
| | `[a-z]` | One character from the range in the bracket | | ||
| | `[!a-z]` | One character not from the range in the bracket | |
There was a problem hiding this comment.
Columns should be aligned to make source look better.
| [Regexp Escape]: https://robotframework.org/robotframework/latest/libraries/BuiltIn.html#Regexp%20Escape "BuiltIn.Regexp Escape" | ||
| [Should Be Equal]: https://robotframework.org/robotframework/latest/libraries/BuiltIn.html#Should%20Be%20Equal "BuiltIn.Should Be Equal" | ||
| [Should Be Equal As Integers]: https://robotframework.org/robotframework/latest/libraries/BuiltIn.html#Should%20Be%20Equal%20As%20Integers "BuiltIn.Should Be Equal As Integers" | ||
| [Log]: https://robotframework.org/robotframework/latest/libraries/BuiltIn.html#Log "BuiltIn.Log" |
There was a problem hiding this comment.
With other libraries we have decided that when referring to external keywords, we only link to the library, not to individual keywords. As an example, see the Collections library.
| *** Test Cases *** | ||
| Run And Return RC And Output | ||
| ${rc} ${output} = Run and Return RC and Output ${CURDIR}${/}mytool | ||
| Should Be Equal As Integers ${rc} 0 |
There was a problem hiding this comment.
With other libraries we've decided to use
Should Be Equal ${rc} 0 type=int
style instead of Should Be Equal As Integers. That works especially well in cases like this where arguments are aligned based on the longest keyword name.
| @{p3} = Join Paths my/base example/path/ other one/more | ||
| Should Be Equal ${p1} ${{['base/example', 'base/other']}} | ||
| Should Be Equal ${p2} ${{['/example', '/my/base/other']}} | ||
| Should Be Equal ${p3} ${{['my/base/example/path', 'my/base/other', 'my/base/one/more']}} |
There was a problem hiding this comment.
The inline Python evaluation syntax is somewhat complex. Using the newish type conversion functionality with Should Be Equal would allows this style that would probably be cleaner:
Should Be Equal ${p1} ['base/example', 'base/other'] type=list
|
I took a pretty quick look at this and didn't see major problems. It would be great if you could fix the few issues I reported, but I think this could be merged already in this shape. I anyway need to take the final look locally so that I can also see how the generated docs look like. Could you @Vinni82 take a look do you see something that could be fixed/enhanced based on the PRs you've worked with earlier? |
|
There has been no reaction to my latest review comments, but I consider this to be in good enough shape to be merged. @Vinni82 can do more enhancements after that, including fixing the issues I mentioned, and I'll do a final cleanup after that. |
- Addressed review comments on PR #5710 - Reworked the deprecated messages - Corrected the indentation Part of #5709. --------- Co-authored-by: Vincent <[email protected]>
What
Why
This is the OperatingSystem-only part of #5709. It does not touch Dialogs, Screenshot, String, DateTime, or Collections.
How
The library now declares ROBOT_LIBRARY_DOC_FORMAT = "Markdown". Existing documentation content and behavior are preserved while syntax is converted, and exception behavior remains in the prose where separate Raises entries would be redundant.
Testing
AI assistance
OpenAI Codex assisted with the documentation conversion, tests, and validation. I reviewed the resulting diff and verification evidence.