Skip to content

Commit 4077b7e

Browse files
Merge branch 'main' into feat/tech
2 parents 3847328 + 0f9db35 commit 4077b7e

40 files changed

+417
-499
lines changed

README.rst

Lines changed: 15 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
Ansys tools
2-
===========
1+
Ansys Common Tools
2+
==================
33
|pyansys| |python| |pypi| |MIT| |GH-CI| |pre-commit|
44

55
.. |pyansys| image:: https://img.shields.io/badge/Py-Ansys-ffc107.svg?logo=data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAIAAACQkWg2AAABDklEQVQ4jWNgoDfg5mD8vE7q/3bpVyskbW0sMRUwofHD7Dh5OBkZGBgW7/3W2tZpa2tLQEOyOzeEsfumlK2tbVpaGj4N6jIs1lpsDAwMJ278sveMY2BgCA0NFRISwqkhyQ1q/Nyd3zg4OBgYGNjZ2ePi4rB5loGBhZnhxTLJ/9ulv26Q4uVk1NXV/f///////69du4Zdg78lx//t0v+3S88rFISInD59GqIH2esIJ8G9O2/XVwhjzpw5EAam1xkkBJn/bJX+v1365hxxuCAfH9+3b9/+////48cPuNehNsS7cDEzMTAwMMzb+Q2u4dOnT2vWrMHu9ZtzxP9vl/69RVpCkBlZ3N7enoDXBwEAAA+YYitOilMVAAAAAElFTkSuQmCC
@@ -26,51 +26,47 @@ Ansys tools
2626
:target: https://results.pre-commit.ci/latest/github/ansys/ansys-tools-common/main
2727
:alt: pre-commit.ci status
2828

29-
.. contents::
30-
3129
Overview
3230
--------
3331

34-
The Ansys tools project is a set of tools for the PyAnsys libraries.
32+
Ansys Common Tools provides a set of tools for the PyAnsys ecosystem.
3533

3634

3735
Documentation and issues
3836
------------------------
3937

40-
Documentation for the latest stable release of the Ansys tools Tool is hosted
41-
at `Ansys tools documentation <https://ansys.tools.docs.pyansys.com/version/stable/index.html>`_.
38+
Documentation for the latest stable release of Ansys Common Tools is hosted
39+
at `Ansys Common Tools documentation <https://ansys.tools.docs.pyansys.com/version/stable/index.html>`_.
4240

4341
The documentation has these sections:
4442

4543
- `Getting started <https://ansys.tools.docs.pyansys.com/version/stable/getting_started/index.html>`_: Learn
46-
how to install the Ansys tools in user mode and quickly begin using it.
44+
how to install Ansys Common Tools in user mode.
4745
- `User guide <https://ansys.tools.docs.pyansys.com/version/stable/user_guide/index.html>`_: Understand key
48-
concepts for implementing the Ansys tools in your workflow.
46+
concepts for implementing the tools in your workflows.
4947
- `API reference <https://ansys.tools.docs.pyansys.com/version/stable/api/index.html>`_: Understand how to
50-
use Python to interact programmatically with the Ansys tools.
51-
- `Examples <https://ansys.tools.docs.pyansys.com/version/stable/examples/index.html>`_: Explore examples that
52-
show how to use the Ansys tools Tool to perform many different types of operations.
48+
use Python to interact programmatically with the tools.
5349
- `Contribute <https://ansys.tools.docs.pyansys.com/version/stable/contributing.html>`_: Learn how to
54-
contribute to the Ansys tools codebase or documentation.
50+
contribute to the Ansys Common Tools codebase or documentation.
5551

5652
In the upper right corner of the documentation's title bar, there is an option
5753
for switching from viewing the documentation for the latest stable release
5854
to viewing the documentation for the development version or previously
5955
released versions.
6056

61-
On the `Ansys tools Issues <https://github.com/ansys/ansys-tools-common/issues>`_
62-
page, you can create issues to report bugs and request new features. On the
63-
`Discussions <https://discuss.ansys.com/>`_ page on the Ansys Developer portal,
57+
On the Ansys Common Tools `Issues <https://github.com/ansys/ansys-tools-common/issues>`_
58+
page, you can create issues to report bugs and request new features. On the `Ansys Common Tools Discussions <https://github.com/ansys/ansys-tools-common/discussions>`_ page
59+
or the `Discussions <https://discuss.ansys.com/>`_ page on the Ansys Developer portal,
6460
you can post questions, share ideas, and get community feedback.
6561

6662
If you have general questions about the PyAnsys ecosystem, email
6763
68-
question is specific to the Ansys tools Tool, ask your
64+
question is specific to Ansys Common Tools, ask your
6965
question in an issue as described in the previous paragraph.
7066

7167
License
7268
-------
7369

74-
Ansys tools is licensed under the `MIT License <https://github.com/ansys/ansys-tools-common/blob/main/LICENSE>`_.
70+
Ansys Common Tools is licensed under the `MIT License <https://github.com/ansys/ansys-tools-common/blob/main/LICENSE>`_.
7571

76-
Ansys tools makes no commercial claim over Ansys whatsoever.
72+
Ansys Common Tools makes no commercial claim over Ansys whatsoever.

doc/.vale.ini

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,9 @@ Vocab = ANSYS
2525
[*.{md,rst}]
2626

2727
# Apply the following styles
28-
[*.{rst}]
2928
BasedOnStyles = Vale, Google
3029
Vale.Terms = NO
3130
Google.Headings = NO
32-
SkippedScopes = script, style, pre, figure, code-block, literal-block
3331

32+
# Inline roles are ignored
33+
TokenIgnores = (:.*:`.*`)
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
Update docstrings.
1+
Update documentation strings.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Overall review for public release

doc/source/contributing.rst

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,16 @@ Contribute
66
Overall guidance on contributing to a PyAnsys library appears in the
77
`Contributing <https://dev.docs.pyansys.com/how-to/contributing.html>`_ topic
88
in the *PyAnsys developer's guide*. Ensure that you are thoroughly familiar
9-
with this guide before attempting to contribute to the Ansys tools common repository.
9+
with this guide before attempting to contribute to Ansys Common Tools.
1010

11-
The following contribution information is specific to the Ansys tools common.
11+
The following contribution information is specific to Ansys Common Tools.
1212

1313
Install in developer mode
1414
-------------------------
1515

16-
Installing the Ansys tools in developer mode allows you to modify and enhance
17-
the source.
16+
Installing Ansys Common Tools in developer mode allows you to modify and enhance the source.
1817

19-
To clone and install the latest Ansys tools release in development mode, run
20-
these commands:
18+
To clone and install the latest Ansys Common Tools release in development mode, run these commands:
2119

2220
.. code::
2321
@@ -29,22 +27,20 @@ these commands:
2927
Run tests
3028
---------
3129

32-
Ansys tools common uses `pytest <https://docs.pytest.org/en/stable/>`_ for testing.
30+
Ansys Common Tools uses `pytest <https://docs.pytest.org/en/stable/>`_ for testing.
3331

34-
#. Prior to running tests, you must run this command to install
35-
test dependencies::
32+
#. Prior to running tests, you must run this command to install test dependencies::
3633

3734
pip install -e .[tests]
3835

39-
#. To then run the tests, navigate to the root directory of the repository and run this
40-
command::
36+
#. To then run the tests, navigate to the root directory of the repository and run this command::
4137

4238
pytest
4339

4440
Adhere to code style
4541
--------------------
4642

47-
The Ansys tools common follows the PEP8 standard as outlined in
43+
Ansys Common Tools follows the PEP8 standard as outlined in
4844
`PEP 8 <https://dev.docs.pyansys.com/coding-style/pep8.html>`_ in
4945
the *PyAnsys developer's guide* and implements style checking using
5046
`pre-commit <https://pre-commit.com/>`_.
@@ -76,7 +72,7 @@ This way, it's not possible for you to push code that fails the style checks::
7672
Build the documentation
7773
-----------------------
7874

79-
You can build the Ansys tools common documentation locally.
75+
You can build Ansys Common Tools documentation locally.
8076

8177
#. Prior to building the documentation, you must run this command to install
8278
documentation dependencies::
@@ -105,11 +101,10 @@ You can clean the documentation build by running this command::
105101
Post issues
106102
-----------
107103

108-
Use the `Ansys tools common Issues <https://github.com/ansys/ansys-tools-common/issues>`_
109-
page to report bugs and request new features. When possible, use the issue templates provided.
104+
Use the Ansys Common Tools `Issues <https://github.com/ansys/ansys-tools-common/issues>`_ page to report bugs and request new features. When possible, use the issue templates provided.
110105
If your issue does not fit into one of these templates, click the link for opening a blank issue.
111106

112107
If you have general questions about the PyAnsys ecosystem, email
113108
114-
question is specific to the Ansys tools common, ask your
109+
question is specific to Ansys Common Tools, ask your
115110
question in an issue as described in the previous paragraph.

doc/source/getting_started/index.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@
33
Getting started
44
===============
55

6-
This section describes how to install theAnsys tools common in user mode and
7-
quickly begin using it. If you are interested in contributing to theAnsys tools common,
8-
see :ref:`contribute` for information on installing in developer mode.
6+
This section describes how to install Ansys Common Tools in user mode.
7+
If you are interested in contributing to Ansys Common Tools, see
8+
:ref:`contribute` for information on installing in developer mode.
99

1010
Installation
1111
------------
1212

13-
To use `pip <https://pypi.org/project/pip/>`_ to install the Ansys tools common project,
13+
To use `pip <https://pypi.org/project/pip/>`_ to install Ansys Common Tools,
1414
run this command:
1515

1616
.. code:: bash

doc/source/index.rst

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
Ansys tools common |version|
1+
Ansys Common Tools |version|
22
############################
33

4-
The Ansys tools project is a collection of tools for the PyAnsys ecosystem.
4+
Ansys Common Tools provides a collection of tools for the PyAnsys ecosystem.
55

66

77

@@ -13,30 +13,30 @@ The Ansys tools project is a collection of tools for the PyAnsys ecosystem.
1313
:link: getting_started/index
1414
:link-type: doc
1515

16-
Learn how to install the collection.
16+
Learn how to install Ansys Common Tools in user mode.
1717

1818
.. grid-item-card:: User guide :material-regular:`menu_book`
1919
:padding: 2 2 2 2
2020
:link: user_guide/index
2121
:link-type: doc
2222

23-
Understand key concepts for using the tools into your workflow.
23+
Understand key concepts for implementing the tools
24+
in your workflows.
2425

2526

2627
.. grid-item-card:: API reference :material-regular:`bookmark`
2728
:padding: 2 2 2 2
2829
:link: api/index
2930
:link-type: doc
3031

31-
Understand how to use Python to interact programmatically with
32-
the Ansys tools collection.
32+
Understand how to use Python to interact programmatically with the tools.
3333

3434
.. grid-item-card:: Contribute :material-regular:`group`
3535
:padding: 2 2 2 2
3636
:link: contributing
3737
:link-type: doc
3838

39-
Learn how to contribute to the Ansys tools codebase or documentation.
39+
Learn how to contribute to the Ansys Common Tools codebase or documentation.
4040

4141

4242

doc/source/user_guide/ansys_downloader.rst

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,7 @@
33
Ansys example downloader
44
========================
55

6-
You can use any of the functions available in the
7-
to identify the path of the local Ansys installation.
8-
9-
For example you can use :func:`find_ansys <ansys.tools.common.path.find_ansys>`
10-
to locate the path of the latest Ansys installation available:
6+
Use the Ansys example downloader to download an example from a PyAnsys library. Import this tool and then specify the filename, directory, and local path for the file to download:
117

128
.. code:: pycon
139

doc/source/user_guide/ansys_exceptions.rst

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,24 +3,32 @@
33
Ansys exceptions
44
================
55

6-
The Ansys exceptions tool provides a way to handle exceptions that may occur when using Ansys tools.
7-
It allows you to catch specific exceptions and handle them gracefully, providing a better user experience.
6+
Ansys exceptions are a set of predefined error-handling classes designed to help developers identify, catch, and handle errors that might occur when using Ansys tools. These exceptions provide a structured way to manage errors, ensuring that your programs can gracefully recover from unexpected issues and provide meaningful feedback to users.
87

9-
How to use
10-
----------
8+
By using Ansys exceptions, you can improve the robustness and maintainability of your code. They allow you to differentiate between various types of errors, such as invalid input types or logical inconsistencies, and handle them appropriately.
119

12-
You can use the `AnsysException` class to catch exceptions related to Ansys tools.
13-
14-
For example, you can use it to extend your exceptions or use them directly on your programs:
10+
You can import exception classes and use the predefined exceptions directly in your programs:
1511

1612
.. code:: pycon
1713
1814
>>> from ansys.tools.exceptions import AnsysError
1915
>>> from ansys.tools.exceptions import AnsysTypeError
2016
>>> from ansys.tools.exceptions import AnsysLogicError
2117
>>> raise AnsysError("An error occurred in Ansys tools.")
22-
AnsysError: An error occurred in Ansys tools.
18+
AnsysError: An error occurred in Ansys tools.
2319
>>> raise AnsysTypeError("An invalid type was provided.")
2420
AnsysTypeError: An invalid type was provided.
2521
>>> raise AnsysLogicError("A logic error occurred in Ansys tools.")
2622
AnsysLogicError: A logic error occurred in Ansys tools.
23+
24+
You can also extend the base exception class to define your own custom exceptions. This allows you to create error types specific to your needs:
25+
26+
.. code:: python
27+
28+
class CustomError(AnsysError):
29+
"""A custom exception for specific error handling."""
30+
31+
pass
32+
33+
34+
raise CustomError("This is a custom error message.")

doc/source/user_guide/ansys_tools_path.rst

Lines changed: 3 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,9 @@
11
.. _ref_ansys_tools_path:
22

3-
Ansys pathing tool
4-
==================
3+
Ansys path tool
4+
===============
55

6-
The Ansys pathing tool provides a way to identify the path of the local Ansys installation.
7-
8-
How to use
9-
----------
10-
11-
You can use any of the functions available in the
12-
to identify the path of the local Ansys installation.
13-
14-
For example you can use :func:`find_ansys <ansys.tools.common.path.find_ansys>`
15-
to locate the path of the latest Ansys installation available:
6+
Use the Ansys path tool to find the path of the latest local Ansys installation. Importing this tool and then call the :func:`find_ansys <ansys.tools.common.path.find_ansys>` function to return the installation path:
167

178
.. code:: pycon
189

0 commit comments

Comments
 (0)