Skip to content

Commit

Permalink
Merge branch 'main' into release/0.2
Browse files Browse the repository at this point in the history
  • Loading branch information
ansnfernand committed Mar 7, 2024
2 parents d8e86d7 + 4f0126c commit c344ce4
Show file tree
Hide file tree
Showing 32 changed files with 3,307 additions and 215 deletions.
18 changes: 8 additions & 10 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
documentation:
- doc/**/*
- README.rst
- CONTRIBUTING.md
- changed-files:
- any-glob-to-any-file: ['doc/**/*', 'README.rst', 'CONTRIBUTING.md']
maintenance:
- .github/**/*
- .flake8
- pyproject.toml
- tox.ini
- .gitignore
- changed-files:
- any-glob-to-any-file: ['.github/**/*', '.flake8' , 'pyproject.toml', 'tox.ini', '.gitignore']
dependencies:
- pyproject.toml
- changed-files:
- any-glob-to-any-file: ['pyproject.toml']
testing:
- tests/*
- changed-files:
- any-glob-to-any-file: ['tests/*']
28 changes: 16 additions & 12 deletions .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: PyAnsys code style checks
uses: ansys/actions/code-style@v4
uses: ansys/actions/code-style@v5
with:
python-version: ${{ env.MAIN_PYTHON_VERSION }}

Expand All @@ -33,7 +33,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: PyAnsys documentation style checks
uses: ansys/actions/doc-style@v4
uses: ansys/actions/doc-style@v5
with:
token: ${{ secrets.GITHUB_TOKEN }}

Expand All @@ -53,7 +53,7 @@ jobs:
os: macos-latest
steps:
- name: Build wheelhouse and perform smoke test
uses: ansys/actions/build-wheelhouse@v4
uses: ansys/actions/build-wheelhouse@v5
with:
library-name: ${{ env.PACKAGE_NAME }}
library-namespace: ${{ env.PACKAGE_NAMESPACE }}
Expand All @@ -72,7 +72,7 @@ jobs:
- uses: actions/checkout@v4

- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

Expand All @@ -94,7 +94,7 @@ jobs:
pytest -v --cov=ansys.sherlock --cov-report=term --cov-report=html:.cov/html --cov-report=xml:.cov/coverage.xml
- name: Upload coverage results
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
if: env.MAIN_PYTHON_VERSION == matrix.python-version
with:
name: coverage-results
Expand All @@ -103,15 +103,19 @@ jobs:

- name: Upload coverage to Codecov
if: env.MAIN_PYTHON_VERSION == matrix.python-version
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
files: .cov/coverage.xml

docs:
name: Documentation
needs: [ docs-style ]
runs-on: ubuntu-latest
steps:
- name: Run documentation building action
uses: ansys/actions/doc-build@v4
uses: ansys/actions/doc-build@v5
with:
python-version: ${{ env.MAIN_PYTHON_VERSION }}

Expand All @@ -121,7 +125,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Build library source and wheel artifacts
uses: ansys/actions/build-library@v4
uses: ansys/actions/build-library@v5
with:
library-name: ${{ env.PACKAGE_NAME }}
python-version: ${{ env.MAIN_PYTHON_VERSION }}
Expand All @@ -133,14 +137,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Release to the public PyPI repository
uses: ansys/actions/release-pypi-public@v4
uses: ansys/actions/release-pypi-public@v5
with:
library-name: ${{ env.PACKAGE_NAME }}
twine-username: "__token__"
twine-token: ${{ secrets.PYPI_TOKEN }}

- name: Release to GitHub
uses: ansys/actions/release-github@v4
uses: ansys/actions/release-github@v5
with:
library-name: ${{ env.PACKAGE_NAME }}

Expand All @@ -151,7 +155,7 @@ jobs:
needs: [ package ]
steps:
- name: Deploy the latest documentation
uses: ansys/actions/doc-deploy-dev@v4
uses: ansys/actions/doc-deploy-dev@v5
with:
cname: ${{ env.DOCUMENTATION_CNAME }}
token: ${{ secrets.GITHUB_TOKEN }}
Expand All @@ -163,7 +167,7 @@ jobs:
needs: [ release ]
steps:
- name: Deploy the stable documentation
uses: ansys/actions/doc-deploy-stable@v4
uses: ansys/actions/doc-deploy-stable@v5
with:
cname: ${{ env.DOCUMENTATION_CNAME }}
token: ${{ secrets.GITHUB_TOKEN }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/label.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ jobs:

# Label based on modified files
- name: Label based on changed files
uses: actions/labeler@v4
uses: actions/labeler@v5
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
sync-labels: ''
sync-labels: true

# Label based on branch name
- uses: actions-ecosystem/action-add-labels@v1
Expand Down Expand Up @@ -70,7 +70,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Suggest to add labels
uses: peter-evans/create-or-update-comment@v3
uses: peter-evans/create-or-update-comment@v4
# Execute only when no labels have been applied to the pull request
if: toJSON(github.event.pull_request.labels.*.name) == '{}'
with:
Expand Down
2 changes: 1 addition & 1 deletion PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Checklist:
- pre-commit command line check
- Problems tab in PyCharm
- [] Bench test new/modified APIs by using and modifying the code in the example for the API method
- [] Add new methods to rst file for updated API script(<pysherlock>\doc\source\api)
- [] Add new classes to rst files, located at: <pysherlock>\doc\source\api
- [] Generate documentation
- [] Verify the HTML. It gets generated at: <pysherlock>\doc\build\html.
- Open index.html
Expand Down
20 changes: 2 additions & 18 deletions doc/source/api/analysis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,25 +3,9 @@
Analysis
========

The ``analysis`` module contains all analysis capabilities.

.. currentmodule:: ansys.sherlock.core.analysis
.. automodule:: ansys.sherlock.core.analysis

.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.analysis.Analysis.get_harmonic_vibe_input_fields
ansys.sherlock.core.analysis.Analysis.get_ict_analysis_input_fields
ansys.sherlock.core.analysis.Analysis.get_mechanical_shock_input_fields
ansys.sherlock.core.analysis.Analysis.get_random_vibe_input_fields
ansys.sherlock.core.analysis.Analysis.get_solder_fatigue_input_fields
ansys.sherlock.core.analysis.Analysis.run_analysis
ansys.sherlock.core.analysis.Analysis.run_strain_map_analysis
ansys.sherlock.core.analysis.Analysis.update_harmonic_vibe_props
ansys.sherlock.core.analysis.Analysis.update_ict_analysis_props
ansys.sherlock.core.analysis.Analysis.update_mechanical_shock_props
ansys.sherlock.core.analysis.Analysis.update_natural_frequency_props
ansys.sherlock.core.analysis.Analysis.update_part_modeling_props
ansys.sherlock.core.analysis.Analysis.update_pcb_modeling_props
ansys.sherlock.core.analysis.Analysis.update_random_vibe_props
ansys.sherlock.core.analysis.Analysis.update_solder_fatigue_props
ansys.sherlock.core.analysis.Analysis
10 changes: 2 additions & 8 deletions doc/source/api/common.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,9 @@
Common
======

The ``common`` module contains all common capabilities.

.. currentmodule:: ansys.sherlock.core.common
.. automodule:: ansys.sherlock.core.common

.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.common.Common.check
ansys.sherlock.core.common.Common.exit
ansys.sherlock.core.common.Common.is_sherlock_client_loading
ansys.sherlock.core.common.Common.list_solder_materials
ansys.sherlock.core.common.Common.list_units
ansys.sherlock.core.common.Common
2 changes: 2 additions & 0 deletions doc/source/api/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ Use the search feature or click links to view API documentation.
layer_types
parts_types
project
project_types
stackup

.. autosummary::
Expand All @@ -34,4 +35,5 @@ Use the search feature or click links to view API documentation.
ansys.sherlock.core.types.layer_types
ansys.sherlock.core.types.parts_types
ansys.sherlock.core.project
ansys.sherlock.core.types.project_types
ansys.sherlock.core.stackup
4 changes: 1 addition & 3 deletions doc/source/api/launcher.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
Launcher
========

The ``launcher`` module launches the Sherlock gRPC server and a Sherlock client.

.. currentmodule:: ansys.sherlock.core.launcher
.. automodule:: ansys.sherlock.core.launcher

.. autosummary::
:toctree: _autosummary
Expand Down
7 changes: 2 additions & 5 deletions doc/source/api/layer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,9 @@
Layer
=====

The ``layer`` module contains all layer management capabilities.

.. currentmodule:: ansys.sherlock.core.layer
.. automodule:: ansys.sherlock.core.layer

.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.layer.Layer.update_mount_points_by_file
ansys.sherlock.core.layer.Layer.add_potting_region
ansys.sherlock.core.layer.Layer
16 changes: 2 additions & 14 deletions doc/source/api/lifecycle.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,9 @@
Lifecycle
=========

The ``lifecycle`` module contains all life cycle management capabilities.

.. currentmodule:: ansys.sherlock.core.lifecycle
.. automodule:: ansys.sherlock.core.lifecycle

.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.lifecycle.Lifecycle.add_harmonic_event
ansys.sherlock.core.lifecycle.Lifecycle.add_harmonic_vibe_profiles
ansys.sherlock.core.lifecycle.Lifecycle.add_random_vibe_event
ansys.sherlock.core.lifecycle.Lifecycle.add_random_vibe_profiles
ansys.sherlock.core.lifecycle.Lifecycle.add_shock_event
ansys.sherlock.core.lifecycle.Lifecycle.add_shock_profiles
ansys.sherlock.core.lifecycle.Lifecycle.add_thermal_event
ansys.sherlock.core.lifecycle.Lifecycle.add_thermal_profiles
ansys.sherlock.core.lifecycle.Lifecycle.create_life_phase
ansys.sherlock.core.lifecycle.Lifecycle.load_harmonic_profile
ansys.sherlock.core.lifecycle.Lifecycle.load_random_vibe_profile
ansys.sherlock.core.lifecycle.Lifecycle
7 changes: 2 additions & 5 deletions doc/source/api/model.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,9 @@
Model
=====

The ``model`` module contains all model generation capabilities.

.. currentmodule:: ansys.sherlock.core.model
.. automodule:: ansys.sherlock.core.model

.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.model.Model.export_trace_reinforcement_model
ansys.sherlock.core.model.Model.generate_trace_model
ansys.sherlock.core.model.Model
15 changes: 2 additions & 13 deletions doc/source/api/parts.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,19 +2,8 @@

Parts
=====

The ``parts`` module contains all parts management capabilities.

.. currentmodule:: ansys.sherlock.core.parts

.. automodule:: ansys.sherlock.core.parts
.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.parts.Parts.enable_lead_modeling
ansys.sherlock.core.parts.Parts.export_parts_list
ansys.sherlock.core.parts.Parts.import_parts_list
ansys.sherlock.core.parts.Parts.update_parts_list
ansys.sherlock.core.parts.Parts.update_parts_locations
ansys.sherlock.core.parts.Parts.update_parts_locations_by_file
ansys.sherlock.core.parts.Parts.get_part_location
ansys.sherlock.core.parts.Parts.update_parts_from_AVL
ansys.sherlock.core.parts.Parts
25 changes: 15 additions & 10 deletions doc/source/api/parts_types.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,21 @@

Parts Types
===========

Constants and classes used for the Parts API.

.. automodule:: ansys.sherlock.core.types.parts_types
.. currentmodule:: ansys.sherlock.core.types.parts_types

.. autosummary::
:toctree: _autosummary
Constants
---------
.. autoclass:: AVLDescription
:members:
.. autoclass:: AVLPartNum
:members:
.. autoclass:: PartsListSearchDuplicationMode
:members:
.. autoclass:: PartsListSearchMatchingMode
:members:

PartLocation
PartsListSearchMatchingMode
PartsListSearchDuplicationMode
AVLPartNum
AVLDescription
Classes
-------
.. autoclass:: PartLocation
:members:
14 changes: 2 additions & 12 deletions doc/source/api/project.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,9 @@
Project
=======

The ``project`` module contains all project management capabilities.

.. currentmodule:: ansys.sherlock.core.project
.. automodule:: ansys.sherlock.core.project

.. autosummary::
:toctree: _autosummary

ansys.sherlock.core.project.Project.add_cca
ansys.sherlock.core.project.Project.add_strain_maps
ansys.sherlock.core.project.Project.delete_project
ansys.sherlock.core.project.Project.generate_project_report
ansys.sherlock.core.project.Project.import_odb_archive
ansys.sherlock.core.project.Project.import_ipc2581_archive
ansys.sherlock.core.project.Project.list_ccas
ansys.sherlock.core.project.Project.list_strain_maps
ansys.sherlock.core.project.Project.add_project
ansys.sherlock.core.project.Project
Loading

0 comments on commit c344ce4

Please sign in to comment.