Skip to content

Commit 95e8c37

Browse files
PipKatakaszynski
andauthored
Fix minor doc issues (#32)
* Fix minor doc issues * Fix use of both interpreted text role prefix and reference suffix * Fix branch_naming`and and :ref:`branching_model * Tried yet another approach to get past line 40 * Additional doc edits * Update doc/source/guidelines/dev_practices.rst Co-authored-by: Alex Kaszynski <[email protected]> Co-authored-by: Alex Kaszynski <[email protected]>
1 parent 97037a9 commit 95e8c37

File tree

3 files changed

+111
-108
lines changed

3 files changed

+111
-108
lines changed

doc/source/guidelines/dev_practices.rst

Lines changed: 44 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
Development Practices
44
=====================
55
This page explains how PyAnsys development is conducted. When
6-
contributing directly to PyAnsys libraries, use these general
6+
contributing to a PyAnsys repository, use these general
77
coding paradigms:
88

99
#. Follow the `Zen of Python <https://www.python.org/dev/peps/pep-0020/>`__.
1010
As silly as core Python developers are sometimes, there's much to be
1111
gained by following the basic guidelines listed in PEP 20. As suggested
1212
in these guidelines, focus on making your additions intuitive, novel,
13-
and helpful for PyAnsys library users. When in doubt, use ``import this``.
13+
and helpful for PyAnsys users. When in doubt, use ``import this``.
1414
For Ansys code quality standards, see :ref:`coding_style`.
1515

1616
#. Document your contributions. Include a docstring for any added
@@ -31,13 +31,15 @@ coding paradigms:
3131

3232
Contributing Through GitHub
3333
---------------------------
34-
To submit new code to a PyAnsys Library:
34+
To submit new code to a PyAnsys repository:
3535

3636
#. `Fork <https://docs.github.com/en/get-started/quickstart/fork-a-repo>`_
37-
the respective library's GitHub repository and then clone
38-
the forked repository to your computer.
37+
the respective GitHub repository and then clone the forked repository
38+
to your computer.
3939

40-
#. In your local repository, create a branch. See `Branching Model <#Branching Model>`__.
40+
#. In your local repository, create a branch. See :ref:`branch_naming`.
41+
Comprehensive information on our model for branching is availible in
42+
`Branching Model <#Branching Model>`__.
4143

4244
#. Add your new feature and commit it locally. Be sure to commit
4345
frequently as the ability to revert to past commits is often helpful,
@@ -54,15 +56,15 @@ Once you have tested your branch locally, create a PR and target your
5456
merge to ``main``. This will automatically run CI testing and verify
5557
that your changes will work across all supported platforms.
5658

57-
For code verification, someone from the development team for the PyAnsys library
58-
will review your code to verify that it meets our standards. Once your code
59-
is approved, if you have write permission, you may merge the PR branch. If you
60-
don't have write permission, the reviewer or someone else with write permission
61-
will merge and delete the PR branch.
59+
For code verification, someone from the PyAnsys development team will review your
60+
code to verify that it meets our standards. Once your code is approved, if you
61+
have write permission, you may merge the PR branch. If you don't have write
62+
permission, the reviewer or someone else with write permission will merge your
63+
PR and then delete your PR branch.
6264

6365
If your PR branch is a ``fix/`` branch, do not delete it because it may be necessary to
64-
merge your PR branch with the current release branch. See the next section for branch
65-
naming conventions.
66+
merge your PR branch with the current release branch. The next section explains our
67+
branch naming conventions.
6668

6769
.. _branch_naming:
6870

@@ -124,7 +126,8 @@ like this:
124126

125127
Documentation
126128
-------------
127-
Documentation for a PyAnsys library is generated from three sources:
129+
The source and content for documentation varies from repository to repository. For a PyAnsys library,
130+
documentation is generated from three sources:
128131

129132
- Docstrings from the library's classes, functions, and modules using
130133
`sphinx.ext.autodoc <https://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html>`_.
@@ -161,21 +164,21 @@ and will be compiled dynamically during the build process. Always ensure that
161164
examples run properly locally because they will be verified through the CI performed
162165
via GitHub Actions.
163166

164-
Documentation for the latest stable release of a PyAnsys libary is accessible
165-
from its repository. You can access the latest development version of the
167+
Documentation for the latest stable release of a PyAnsys library is accessible
168+
from its repository. You can generally access the latest development version of the
166169
documentation tracking the ``main`` branch by adding the prefix ``dev.`` to
167-
the URL for the latest stable release. For example, the URL for the latest
168-
stable release of the PyAEDT documentation is
169-
`<https://dev.aedtdocs.pyansys.com/>`_, and the URL for the latest development
170-
version of this documentation is `<https://dev.aedtdocs.pyansys.com/>`_. The
171-
latest development version is kept up-to-date automatically via GitHub actions.
170+
the URL for the latest stable release. For example, the URL for documentation of the
171+
latest stable release of PyAEDT is `<https://aedtdocs.pyansys.com/>`_, and
172+
the URL for the latest documentation for the development version of PyAEDT is
173+
`<https://dev.aedtdocs.pyansys.com/>`_. The latest development versions of both
174+
the library and its documentation are kept up-to-date automatically via GitHub actions.
172175

173-
Building the Documentation Locally
174-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
175-
You can build and verify a library's HTML documentation locally by installing
176-
Sphinx and other documentation build dependencies.
176+
Building Documentation Locally
177+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
178+
You can build and verify the HTML documentation for a PyAnsys project locally
179+
by installing Sphinx and other documentation build dependencies.
177180

178-
#. Optionally install the library in development mode:
181+
#. Optionally install the project in development mode:
179182

180183
.. code::
181184
@@ -201,14 +204,14 @@ Otherwise, if running on Windows, build the documentation:
201204
cd doc
202205
make.bat html
203206
204-
#. After documentation builds successfully locally, use your
205-
browser to open the file ``index.html`` in ``doc/_build/html/``
206-
to review it.
207+
#. After documentation builds successfully locally, navigate to
208+
``doc/_build/html/`` and use your browser to open the
209+
``index.html`` so that you can review the documenation.
207210

208211
Continuous Integration and Continuous Delivery (CI/CD)
209212
------------------------------------------------------
210213

211-
A PyAnsys library uses continuous integration (CI) and continuous delivery (CD)
214+
A PyAnsys project uses continuous integration (CI) and continuous delivery (CD)
212215
to automate building, testing, and deployment tasks. The CI pipeline is
213216
deployed on both GitHub Actions and Azure Pipelines and performs the following
214217
tasks:
@@ -218,9 +221,11 @@ tasks:
218221
- Spelling and style verification
219222
- Documentation build
220223

224+
.. _branching_model:
225+
221226
Branching Model
222227
---------------
223-
The branching model for a PyAnsys library enables rapid development of
228+
The branching model for a PyAnsys project enables rapid development of
224229
features without sacrificing stability. The model closely follows the
225230
`Trunk Based Development <https://trunkbaseddevelopment.com/>`_ approach:
226231

@@ -276,11 +281,10 @@ Release procedures follow for major and minor releases.
276281
#. After building the documentation, open the local build and examine
277282
the examples for any obvious issues.
278283

279-
#. Update the version numbers in
280-
``ansys/<product>/<library>/_version.py`` and commit this file. Push the
281-
branch to GitHub and create a new PR for this release that merges
282-
it to ``main``. While effort is focused on the release, development
283-
to ``main`` should be limited.
284+
#. Update the version numbers in ``ansys/<product>/<library>/_version.py``
285+
and commit this file. Push the branch to GitHub and create a new PR
286+
for this release that merges it to ``main``. While effort is focused
287+
on the release, development to ``main`` should be limited.
284288

285289
#. Wait for the PyAnsys developers and community to functionally test the
286290
new release. Testors should locally install this branch and use it in
@@ -327,11 +331,12 @@ should not wait until a minor release. These are the steps for a patch release:
327331
an opportunity to validate and approve the bug fix release. Any
328332
additional hotfixes should be outside of this PR.
329333

330-
#. When the PR is approved, merge it with the release branch, but not with
331-
``main`` as there is no reason to increment the version of the ``main`` branch.
334+
#. When the PR is approved, merge it with the release branch but not with
335+
``main`` because there is no reason to increment the version of the
336+
``main`` branch.
332337

333338
#. Create a tag from the release branch with the applicable version number
334339
as described in the previous section.
335340

336-
4. If deemed necessary, create and add release notes as described in the
341+
#. If deemed necessary, create and add release notes as described in the
337342
previous section.

doc/source/overview/basic.rst

Lines changed: 30 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,40 @@
11
Quick Start Guide
22
=================
33

4-
This is a brief overview on how to get started right away with your own PyAnsys library on the `PyAnsys GitHub Organization`_
4+
This is a brief overview on how to get started right away with your own PyAnsys
5+
repository on the `PyAnsys GitHub Organization`_. A repository is generally a
6+
project for a particular PyAnsys library.
7+
8+
#. **Create the repository:** Create a repository from the
9+
`pyansys/template`_. See `Creating a repository from a template`_.
10+
Be sure that the `repository visibility`_ is initially private.
11+
12+
#. **Rename the package:** Rename ``ansys/product/library`` to match
13+
your product or library. For example, the package name for
14+
PyMAPDL is ``ansys/mapdl/core``. Do the
15+
same renaming in ``setup.py``. Do this as a pull request. In fact, only add
16+
code as pull requests. Do not push to ``main``.)
17+
18+
#. **Add source:** Add your source files to
19+
``ansys/<product>/<library>`` or create them. Also add unit tests to
20+
``tests/`` following the `pytest`_ convention. Be sure to maintain
21+
sufficient coverage when adding your library. See `pytest-cov`_.
522

6-
#. **Create the Repository:** Create a new repository from the
7-
`pyansys/template`_. See
8-
`Creating a repository from a template`_. Be sure to start as a
9-
private repository.
23+
.. note::
24+
If your tests require an active service, application, or product,
25+
be sure to set up this application to run in an automated manner.
1026

11-
#. **Rename the Package:** Rename ``ansys/product/library`` to match
12-
your product or library. For example ``ansys/mapdl/core``. Do the
13-
same in ``setup.py``. Do this as a pull request. In fact, only add
14-
code as pull requests (don't push to main).
27+
#. **Update documentation:** The documentation source and content will
28+
vary from repository to _repository. In ``doc/``, there are folders for
29+
different types of documentation, which can include guides, examples,
30+
and API. Ensure that all documentation is updated. See :ref:`api_documentation`.
1531

16-
#. **Add Source:** Add your source files to
17-
``ansys/<product>/<library>``, or create them. At the same time,
18-
add unit tests to ``tests/`` following the `pytest`_ convention.
19-
Be sure to maintain sufficient coverage when adding your library.
20-
See `pytest-cov`_.
32+
#. **Prepare the package for release:** When you are ready to release
33+
your package publicly, email `[email protected] <[email protected]>`_
34+
to obtain the release checklist for obtaining official Ansys approval.
35+
Once you have completed this checklist, change the `repository visibility`_
36+
to public and create a release branch.
2137

22-
.. note::
23-
If your tests require an active service,
24-
application, or product, be sure to setup this application to run
25-
in an automated manner.
26-
27-
#. **Documentation:** Update documentation at ``doc/``. There are two
28-
types of docs, User-Guide and API. Be sure that both are updated.
29-
See :ref:`api_documentation`.
30-
31-
#. **Package Release:** When ready to release your package publicly,
32-
contact [email protected] to obtain the release
33-
checklist in regards to official Ansys approval. Once the
34-
checklist is complete, change the `repository visibility`_,
35-
create a release branch.
36-
37-
The manner of the source and content of the documentation will vary
38-
from project to project.
3938

4039
.. todo::
4140

doc/source/overview/contributing.rst

Lines changed: 37 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,13 @@ our libraries powerful tools for all users. As such, we
1010
encourage you to submit questions, report bugs, request new
1111
features, contribute code, and start discussions.
1212

13-
This page provides general information about contributing to a
14-
PyAnsys library. Contribution information specific to a particular
15-
library appears on the ``Contributing`` page in the respective
16-
library's documentation, including:
13+
This page provides general information about contributing code to a
14+
PyAnsys respository. Contribution information specific to a particular
15+
repository appears on the ``Contributing`` page in the respective
16+
respository's documentation, including:
1717

1818
- Instructions for cloning the source repository from GitHub
19-
- URL to the library's ``Issues`` page
19+
- URL to the repository's ``Issues`` page
2020

2121
Creating Issues
2222
---------------
@@ -36,8 +36,9 @@ it with a comment that explains why you have done so. If you need to contact the
3636
PyAnsys project support team directly, email `[email protected] <[email protected]>`_.
3737

3838
For convenience, here are URLs for ``Issues`` pages for
39-
Ansys product repositories:
39+
public Ansys repositories:
4040

41+
- `OpenAPI Common Issues <https://github.com/pyansys/openapi-common/issues>`_
4142
- `PyAEDT Issues <https://github.com/pyansys/pyaedt/issues>`_
4243
- `PyDPF-Core Issues <https://github.com/pyansys/pydpf-core/issues>`_
4344
- `PyDPF-Post Issues <https://github.com/pyansys/pydpf-post/issues>`_
@@ -46,61 +47,59 @@ Ansys product repositories:
4647

4748
Submitting Questions
4849
~~~~~~~~~~~~~~~~~~~~
49-
For general or technical questions about a PyAnsys library, its
50-
applications, or software usage, create issues on the respective
51-
library's ``Issues`` page. This allows PyAnsys developers and
52-
community members with the needed expertise to collectively address
53-
them. It also makes their responses available to all users.
50+
For general or technical questions about the code in a PyAnsys repository or
51+
about its application or software usage, create issues on the ``Issues`` page
52+
of the repository. This allows PyAnsys developers and community members with
53+
the needed expertise to collectively address them. It also makes their responses
54+
available to all users.
5455

5556
Reporting Bugs
5657
~~~~~~~~~~~~~~
57-
If you encounter a bug or your workflow crashes while using a
58-
PyAnsys library, create an issue on the respective library's
59-
``Issues`` page and tag it with an appropriate label so that it
60-
can be promptly addressed. In describing the issue, be as descriptive
61-
as possible so that the issue can be reproduced. Whenever possible,
62-
provide a traceback, screenshots, and sample files that might help
63-
the community to address the issue.
58+
If you encounter a bug or your workflow crashes while using code in a PyAnsys
59+
repository, create an issue on the repository's ``Issues`` page and tag it with
60+
an appropriate label so that it can be promptly addressed. In describing the
61+
issue, be as descriptive as possible so that the issue can be reproduced.
62+
Whenever possible, provide a traceback, screenshots, and sample files that might
63+
help the community to address the issue.
6464

6565
Requesting New Features
6666
~~~~~~~~~~~~~~~~~~~~~~~
67-
We encourage you to submit ideas for improving PyAnsys libraries.
68-
To suggest a new feature, create an issue on the respective library's
69-
``Issues`` page and tag it with the ``Feature Request`` label. Use a
70-
descriptive title and provide ample background information to help the
71-
community decide how the feature might be implemented. For example,
72-
if you would like to see a reader added for a specific file format,
73-
in the issue, provide a link to documentation for this file
74-
format and possibly some sample files and screenshots. The community
75-
will then use the issue thread to discuss the request and
76-
provide feedback on how the feature might best be implemented.
67+
We encourage you to submit ideas for improving the code in a PyAnsys
68+
repository. To suggest a new feature, create an issue on the repository's
69+
``Issues`` page and tag this issue with the ``Feature Request`` label.
70+
Use a descriptive title and provide ample background information to help the
71+
community decide how the feature might be implemented. For example, if you
72+
would like to see a reader added for a specific file format, in the issue,
73+
provide a link to documentation for this file format and possibly some sample
74+
files and screenshots. The community will then use the issue thread to discuss
75+
the request and provide feedback on how the feature might best be implemented.
7776

7877
Contributing New Code
7978
---------------------
8079
When you are ready to start contributing code, see:
8180

82-
- :ref:`development_practices` for information on how development is
83-
conducted in PyAnsys repositories
81+
- :ref:`development_practices` for information on how PyAnsys development is
82+
conducted
8483
- :ref:`best_practices` for information on how to style and format your
8584
code to adhere to PyAnsys standards
8685

8786
Starting Discussions
8887
--------------------
8988
For general questions about development practices, you should create discussions
90-
rather than issues. The repository for each PyAnsys library has its own
91-
``Discussions`` page. For example, to ask a question about a PyMAPDL development
92-
practice, you would create a discussion on this library's `Discussions <https://github.com/pyansys/pymapdl/discussions>`_
89+
rather than issues. Each PyAnsys repository has its own ``Discussions`` page.
90+
For example, to ask a question about a PyMAPDL development practice, you would
91+
create a discussion on the `PyMAPDL Discussions <https://github.com/pyansys/pymapdl/discussions>`_
9392
page. It is possible for discussions to lead to the creation of issues.
9493

9594
.. note::
96-
Because the ``Discussions`` page is still a beta feature on GitHub, usage
95+
Because the ``Discussions`` page is still a GitHub beta feature, usage
9796
may change in the future.
9897

9998
Cloning the Source Repository
10099
-----------------------------
101100
As mentioned earlier, specific instructions for cloning a source
102101
repository from GitHub appear on the ``Contributing`` page in the
103-
respective library's documentation. In the following code for cloning and
102+
respective repository's documentation. In the following code for cloning and
104103
installing the latest version of a PyAnsys repository, ``<pyansy-repository>``
105104
is a placeholder for the name of the repository.
106105

@@ -119,7 +118,7 @@ you would run the following:
119118
cd pymapdl
120119
pip install -e .
121120
122-
If you want to eventually push a contribution to the official
121+
If you want to eventually push a contribution to a
123122
PyAnsys repository, consider creating a `fork <https://docs.github.com/en/get-started/quickstart/fork-a-repo>`_
124123
of the repository. For information on how to contribute through
125124
GitHub, see :ref:`development_practices`, paying particular attention to :ref:`branch_naming`
@@ -128,8 +127,8 @@ when you are ready to create a pull request.
128127
Licensing
129128
---------
130129
All contributed code will be licensed under the MIT License. For more information, see
131-
:ref:`license_file`. The ``LICENSE`` file with the MIT License must be included in
132-
the root directory of the repository for a PyAnsys library.
130+
:ref:`license_file`. The ``LICENSE`` file containing the MIT License must be included in
131+
the root directory of a PyAnsys repository.
133132

134133
If you did not write the code that you are contributing yourself, it is your
135134
responsibility to ensure that the existing license for this code is compatible and

0 commit comments

Comments
 (0)