Skip to content

Commit

Permalink
Migrate Vale version (#281)
Browse files Browse the repository at this point in the history
  • Loading branch information
widerschein authored May 6, 2024
1 parent a0c0f32 commit a01aabb
Show file tree
Hide file tree
Showing 13 changed files with 29 additions and 23 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
- uses: ansys/actions/doc-style@v6
with:
token: ${{ secrets.GITHUB_TOKEN }}
vale-version: "2.29.6"
vale-version: "3.4.1"

wheelhouse:
name: "Wheelhouse and smoke tests"
Expand Down
3 changes: 2 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,10 @@ repos:
exclude: "examples/"

- repo: https://github.com/codespell-project/codespell
rev: v2.2.2
rev: v2.2.6
hooks:
- id: codespell
args: ["--ignore-words", "doc/styles/config/vocabularies/ANSYS/accept.txt"]

- repo: https://github.com/pycqa/pydocstyle
rev: 6.3.0
Expand Down
2 changes: 2 additions & 0 deletions doc/.vale.ini
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,5 @@ Vocab = ANSYS

# Apply the following styles
BasedOnStyles = Vale, Google
TokenIgnores = :py:(?:class|meth|const|attr|mod):`.*`
Vale.Terms = NO
4 changes: 2 additions & 2 deletions doc/source/api/node_types.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
NodeTypes
=========
Node types
==========
.. currentmodule:: ansys.optislang.core.node_types

.. toctree::
Expand Down
2 changes: 1 addition & 1 deletion doc/source/api/node_types/parametric_systems.rst
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Parametric Systems
Parametric systems
==================
.. currentmodule:: ansys.optislang.core.node_types

Expand Down
2 changes: 1 addition & 1 deletion doc/source/user_guide/create_workflow.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ with types of most of the available nodes are declared in
Type of the created node can be also created manually using
:py:class:`NodeType <ansys.optislang.core.node_types.NodeType>` if constant is not available.
Code below shows value of constant
:py:const:`Sensitivity <ansys.optislang.core.node_types.Sensitivity>` from snippet above:
:py:const:`Sensitivity <ansys.optislang.core.node_types.Sensitivity>` from the preceding snippet:

.. code:: python
Expand Down
2 changes: 1 addition & 1 deletion doc/source/user_guide/functions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ Within the context of the :py:class:`Application <ansys.optislang.core.applicati
class instance, there is further
property :py:attr:`project <ansys.optislang.core.application.Application.project>`,
which holds an instance of the :py:class:`Project <ansys.optislang.core.project.Project>` class
(if any project is loaded). This instance groups functionality to get project information
(if any project is loaded). This instance groups features to get project information
and execute operations on the active project.

.. code:: python
Expand Down
4 changes: 2 additions & 2 deletions doc/source/user_guide/launch.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
=============================
OptiSLang instance management
=============================
You use the :class:`Optislang <ansys.optislang.core.optislang.Optislang>`
You use the :py:class:`Optislang <ansys.optislang.core.optislang.Optislang>`
class to launch optiSLang as a server and to control and query optiSLang projects.
You can either launch optiSLang locally or connect to a remote optiSLang instance.

Expand Down Expand Up @@ -164,7 +164,7 @@ initialized with the ``shutdown_on_finished`` parameter set to ``False``.
* To shut down the optiSLang server, use both the
:py:meth:`shutdown() <ansys.optislang.core.optislang.Optislang.shutdown>` and
:py;meth:`dispose() <ansys.optislang.core.optislang.Optislang.dispose>` methods:
:py:meth:`dispose() <ansys.optislang.core.optislang.Optislang.dispose>` methods:

.. code:: python
Expand Down
4 changes: 2 additions & 2 deletions doc/styles/.gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
*
!Vocab
!Vocab/**
!config
!config/**
!.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ optiSLang
OptiSLang
Optislang
optislang
optiSLang TCP
PyOptiSLang
osl
Pythonic
(?!)ansys
Ansys
design_flow
integration_plugins
File renamed without changes.
2 changes: 1 addition & 1 deletion src/ansys/optislang/core/tcp/osl_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -3487,7 +3487,7 @@ def reset(self, actor_uid: Optional[str] = None, hid: Optional[str] = None):
Parameters
----------
actor_uid: Optional[str], optional
Actor uid entry. A Hirearchical ID (hid) is required. By default ``None``.
Actor uid entry. A Hierarchical ID (hid) is required. By default ``None``.
hid: Optional[str], optional
Hid entry. The actor uid is required. By default ``None``.
Expand Down
20 changes: 10 additions & 10 deletions src/ansys/optislang/core/tcp/server_commands.py
Original file line number Diff line number Diff line change
Expand Up @@ -1168,7 +1168,7 @@ def reset(
Parameters
----------
actor_uid: Optional[str], optional
Actor uid entry. A Hirearchical ID (hid) is required. By default ``None``.
Actor uid entry. A Hierarchical ID (hid) is required. By default ``None``.
hid: Optional[str], optional
Hid entry. The actor uid is required. By default ``None``.
password : Optional[str], optional
Expand All @@ -1180,7 +1180,7 @@ def reset(
JSON string of ``reset`` command.
"""
if actor_uid and hid is None:
raise ValueError("The Hirearchical ID (hid) is required.")
raise ValueError("The Hierarchical ID (hid) is required.")
elif actor_uid is None and hid:
raise ValueError("The actor uid is required.")
return _to_json(
Expand All @@ -1196,7 +1196,7 @@ def restart(
Parameters
----------
actor_uid: Optional[str], optional
Actor uid entry. A Hirearchical ID (hid) is required. By default ``None``.
Actor uid entry. A Hierarchical ID (hid) is required. By default ``None``.
hid: Optional[str], optional
Hid entry. The actor uid is required. By default ``None``.
password : Optional[str], optional
Expand All @@ -1208,7 +1208,7 @@ def restart(
JSON string of ``restart`` command.
"""
if actor_uid and hid is None:
raise ValueError("The Hirearchical ID (hid) is required.")
raise ValueError("The Hierarchical ID (hid) is required.")
elif actor_uid is None and hid:
raise ValueError("The actor uid is required.")
return _to_json(
Expand Down Expand Up @@ -1772,7 +1772,7 @@ def start(
Parameters
----------
actor_uid: Optional[str], optional
Actor uid entry. A Hirearchical ID (hid) is required. By default ``None``.
Actor uid entry. A Hierarchical ID (hid) is required. By default ``None``.
hid: Optional[str], optional
Hid entry. The actor uid is required. By default ``None``.
password : Optional[str], optional
Expand All @@ -1784,7 +1784,7 @@ def start(
JSON string of ``start`` command.
"""
if actor_uid and hid is None:
raise ValueError("The Hirearchical ID (hid) is required.")
raise ValueError("The Hierarchical ID (hid) is required.")
elif actor_uid is None and hid:
raise ValueError("The actor uid is required.")

Expand All @@ -1801,7 +1801,7 @@ def stop(
Parameters
----------
actor_uid: Optional[str], optional
Actor uid entry. A Hirearchical ID (hid) is required. By default ``None``.
Actor uid entry. A Hierarchical ID (hid) is required. By default ``None``.
hid: Optional[str], optional
Hid entry. The actor uid is required. By default ``None``.
password : Optional[str], optional
Expand All @@ -1813,7 +1813,7 @@ def stop(
JSON string of ``stop`` command.
"""
if actor_uid and hid is None:
raise ValueError("The Hirearchical ID (hid) is required.")
raise ValueError("The Hierarchical ID (hid) is required.")
elif actor_uid is None and hid:
raise ValueError("The actor uid is required.")

Expand All @@ -1830,7 +1830,7 @@ def stop_gently(
Parameters
----------
actor_uid: Optional[str], optional
Actor uid entry. A Hirearchical ID (hid) is required. By default ``None``.
Actor uid entry. A Hierarchical ID (hid) is required. By default ``None``.
hid: Optional[str], optional
Hid entry. The actor uid is required. By default ``None``.
password : Optional[str], optional
Expand All @@ -1842,7 +1842,7 @@ def stop_gently(
JSON string of ``stop_gently`` command.
"""
if actor_uid and hid is None:
raise ValueError("The Hirearchical ID (hid) is required.")
raise ValueError("The Hierarchical ID (hid) is required.")
elif actor_uid is None and hid:
raise ValueError("The actor uid is required.")
return _to_json(
Expand Down

0 comments on commit a01aabb

Please sign in to comment.