-
Notifications
You must be signed in to change notification settings - Fork 131
Add support for Python docstring.json template format #6418
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
Conversation
|
jenkins build this please |
1 similar comment
|
jenkins build this please |
python/docstrings_simulators.json
Outdated
| } | ||
| } | ||
| } | ||
| } |
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.
vscode is "starting" to annoy me just wee little bit.
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.
Welcome to the club
|
jenkins build this please |
| "name": "BlackOilSimulator", | ||
| "doc": "The BlackOilSimulator class to run simulations using a given Deck." | ||
| }, | ||
| "GasWater": { |
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.
i guess this block belongs in the other PR.
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.
Yes. I suggest we merge #6075 first with the old docstring format for BlackOil simulator (and no documentation for the GasWater simulator). When that is merged I will rebase this (which will add the documentation for the GasWater simulator back).
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.
#6075 is in, rebase when convenient.
akva2
left a comment
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.
With the niggles addressed (or argued against).
- Create unified template structure with 'simulators', 'constructors', and 'common_methods' sections
- Add support for both BlackOil and GasWater simulators
- Use {{name}} and {{class}} placeholders for template expansion
- Eliminates need for duplicate JSON files
- Add 'BlackOil' as 5th parameter to generate_docstring_hpp.py - Prepares for template-based docstring generation - Will work with updated opm-common generate_docstring_hpp.py script
de2946e to
2f6bf95
Compare
|
jenkins build this please |
1 similar comment
|
jenkins build this please |
Extend
docstrings_simulators.jsonto support a template format with different simulator configurations. This will help reduce documentation duplication when we implement support for more than one python simulator, see #6075 for more information. And see also companion PRs OPM/opm-common#4690 and OPM/opm-python-documentation#17