Skip to content

Commit

Permalink
Merge pull request #120 from ansys/new_architecture
Browse files Browse the repository at this point in the history
New architecture
  • Loading branch information
Samuelopez-ansys authored Aug 8, 2023
2 parents 319a35d + b37d513 commit 80dcdef
Show file tree
Hide file tree
Showing 182 changed files with 10,277 additions and 6,012 deletions.
2 changes: 1 addition & 1 deletion .gitattributes
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
* text=auto !eol
*.sh eol=lf
*.bat eol=crlf
*.bat eol=crlf
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.github/* @Samuelopez-ansys @MaxJPRey @maxcapodi78
2 changes: 1 addition & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ updates:
labels:
- "maintenance"
commit-message:
prefix: "MAINT"
prefix: "MAINT"
2 changes: 1 addition & 1 deletion .github/labels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,4 @@

- name: release
description: Anything related to an incoming release
color: ffffff
color: ffffff
99 changes: 85 additions & 14 deletions .github/workflows/ci_cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ on:
env:
MAIN_PYTHON_VERSION: '3.10'
DOCUMENTATION_CNAME: 'aedt.antenna.toolkit.docs.pyansys.com'
LIBRARY_NAME: 'ansys-aedt-toolkits-antennas'
LIBRARY_NAMESPACE: 'ansys.aedt.toolkits.antennas'
LIBRARY_NAME: 'ansys-aedt-antenna-toolkits'

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand All @@ -44,31 +43,33 @@ jobs:

smoke-tests:
name: "Build and Smoke tests"
runs-on: ubuntu-latest
# needs: [code-style]
strategy:
fail-fast: false
matrix:
python-version: ['3.9']
os : [windows-latest, ubuntu-latest]
python-version: [ '3.7', '3.10' ]
runs-on: ${{ matrix.os }}
steps:
- uses: ansys/actions/build-wheelhouse@v4
with:
library-name: ${{ env.LIBRARY_NAME }}
library-namespace: ${{ env.LIBRARY_NAMESPACE }}
operating-system: ${{ matrix.os }}
python-version: ${{ matrix.python-version }}

tests:
name: "Tests"
runs-on: [self-hosted, pyaedt-toolkits]
# needs: [smoke-tests]
tests_windows:
name: "Windows Tests"
strategy:
matrix:
python-version: [ '3.7', '3.10' ]
fail-fast: false
runs-on: [self-hosted, pyaedt, toolkits, Windows]
steps:
- uses: actions/checkout@v3

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

- name: Create Python venv
run: |
Expand All @@ -81,12 +82,81 @@ jobs:
python -m pip install --upgrade pip
pip install --upgrade build wheel
pip install .[tests]
env:
ANSYSLMD_LICENSE_FILE: 1055@${{ secrets.LICENSE_SERVER }}

- name: Testing
- name: Backend Testing
timeout-minutes: 30
run: |
.\.venv\Scripts\Activate.ps1
pytest -v --cov=pyaedt-antenna-toolkit --cov-report=xml --junitxml=junit/test-results.xml --cov-report=html tests
pytest -v --cov=pyaedt-antenna-toolkit --cov-report=xml --junitxml=junit/test-results.xml --cov-report=html tests/backend
- name: Models Testing
timeout-minutes: 30
run: |
.\.venv\Scripts\Activate.ps1
pytest -v --cov=pyaedt-antenna-toolkit --cov-report=xml --junitxml=junit/test-results.xml --cov-report=html tests/models
- name: Upload Coverage Results
uses: actions/upload-artifact@v3
with:
name: coverage-html
path: .cov/html
retention-days: 7

tests_linux:
name: "Linux Tests"
strategy:
matrix:
python-version: [ '3.7', '3.10' ]
fail-fast: false
runs-on: [ self-hosted, pyaedt, toolkits, Linux ]
steps:
- uses: actions/checkout@v3

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

- name: Create Python venv
run: |
python -m venv .venv_linux
export ANSYSEM_ROOT231=/ansys_inc/v231/Linux64
export LD_LIBRARY_PATH=$ANSYSEM_ROOT231/common/mono/Linux64/lib64:$ANSYSEM_ROOT231/Delcross:$LD_LIBRARY_PATH
- name: Install packages for testing
run: |
source .venv_linux/bin/activate
python -m pip install --trusted-host pypi.org --trusted-host pypi.python.org --trusted-host files.pythonhosted.org pip -U
python -m pip install --trusted-host pypi.org --trusted-host pypi.python.org --trusted-host files.pythonhosted.org wheel setuptools -U
python -c "import sys; print(sys.executable)"
python -m pip install --upgrade pip
pip install --upgrade build wheel
pip install .[tests]
pip install --trusted-host pypi.org --trusted-host pypi.python.org --trusted-host files.pythonhosted.org pytest-azurepipelines
- name: Backend Testing
timeout-minutes: 30
run: |
export ANS_NODEPCHECK=1
export ANSYSEM_ROOT231=/ansys_inc/v231/Linux64
export LD_LIBRARY_PATH=$ANSYSEM_ROOT231/common/mono/Linux64/lib64:$ANSYSEM_ROOT231/Delcross:$LD_LIBRARY_PATH
source .venv_linux/bin/activate
pytest -v --cov=pyaedt-antenna-toolkit --cov-report=xml --junitxml=junit/test-results.xml --cov-report=html tests/backend
env:
ANSYSLMD_LICENSE_FILE: 1055@${{ secrets.LICENSE_SERVER }}

- name: Models Testing
timeout-minutes: 30
run: |
export ANS_NODEPCHECK=1
export ANSYSEM_ROOT231=/ansys_inc/v231/Linux64
export LD_LIBRARY_PATH=$ANSYSEM_ROOT231/common/mono/Linux64/lib64:$ANSYSEM_ROOT231/Delcross:$LD_LIBRARY_PATH
source .venv_linux/bin/activate
pytest -v --cov=pyaedt-antenna-toolkit --cov-report=xml --junitxml=junit/test-results.xml --cov-report=html tests/models
env:
ANSYSLMD_LICENSE_FILE: 1055@${{ secrets.LICENSE_SERVER }}

- name: Upload Coverage Results
uses: actions/upload-artifact@v3
Expand All @@ -108,6 +178,7 @@ jobs:
uses: ansys/actions/doc-build@v4
with:
python-version: ${{ env.MAIN_PYTHON_VERSION }}
check-links: false

doc-deploy-dev:
name: "Deploy development documentation"
Expand All @@ -134,7 +205,7 @@ jobs:
build-library:
name: "Build library basic example"
runs-on: ubuntu-latest
needs: [tests, doc-deploy-stable]
needs: [doc-deploy-stable]
steps:
- uses: ansys/actions/build-library@v4
with:
Expand Down
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
exclude: |
(?x)(
src/ansys/aedt/toolkits/antennas/ui/antennas_main.py
src/ansys/aedt/toolkits/antennas/ui/common/frontend_ui.py
)
repos:
Expand All @@ -10,7 +10,7 @@ repos:
hooks:
- id: black
args:
- --line-length=100
- --line-length=120

- repo: https://github.com/pycqa/isort
rev: 5.12.0
Expand All @@ -24,7 +24,7 @@ repos:
hooks:
- id: flake8
args:
- --max-line-length=100
- --max-line-length=120

- repo: https://github.com/codespell-project/codespell
rev: v2.2.2
Expand Down
1 change: 0 additions & 1 deletion CHANGELOG.md

This file was deleted.

2 changes: 0 additions & 2 deletions CONTRIBUTING.md

This file was deleted.

2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Toolkit features are accessible from the user interface, **Antenna Wizard** or t
Requirements
~~~~~~~~~~~~
In addition to the runtime dependencies listed in the installation information, this toolkit
requires Ansys Electronics Desktop (AEDT) 2022 R1 or later. The AEDT Student Version is also supported.
requires Ansys Electronics Desktop (AEDT) 2023 R1 or later. The AEDT Student Version is also supported.

Documentation and issues
~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
4 changes: 2 additions & 2 deletions doc/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
#

# You can set these variables from the command line.
SPHINXOPTS = -j auto
SPHINXOPTS = -j auto -w build_errors.txt --color
SPHINXBUILD = sphinx-build
SOURCEDIR = source
BUILDDIR = _build
Expand Down Expand Up @@ -30,4 +30,4 @@ clean:
pdf:
@$(SPHINXBUILD) -M latex "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
cd $(BUILDDIR)/latex && latexmk -r latexmkrc -pdf *.tex -interaction=nonstopmode || true
(test -f $(BUILDDIR)/latex/*.pdf && echo pdf exists) || exit 1
(test -f $(BUILDDIR)/latex/*.pdf && echo pdf exists) || exit 1
43 changes: 0 additions & 43 deletions doc/source/Antennas/antenna_wizard.rst

This file was deleted.

16 changes: 7 additions & 9 deletions doc/source/Contributing.rst
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
.. _contributing_aedt:

==========
Contribute
==========
Expand All @@ -8,34 +6,34 @@ Overall guidance on contributing to a PyAnsys repository appears in
in the *PyAnsys Developer's Guide*. Ensure that you are thoroughly familiar
with this guide before attempting to contribute to PyAEDT or its toolkits.

The following contribution information is specific to PyAEDT Antenna toolkit.
The following contribution information is specific to PyAEDT toolkits.

Clone the repository
--------------------
To clone and install the latest version of PyAEDT Antenna toolkit in
To clone and install the latest version of this toolkit in
development mode, run:

.. code::
git clone https://github.com/pyansys/pyaedt-antenna-toolkit.git
git clone https://github.com/ansys/pyaedt-antenna-toolkit.git
cd pyaedt-antenna-toolkit
python -m pip install --upgrade pip
pip install -e .
Post issues
-----------
Use the `PyAEDT Antenna toolkit Issues <https://github.com/pyansys/pyaedt-antenna-toolkit/issues>`_ page
Use the `PyAEDT antenna toolkit issues <https://github.com/ansys/pyaedt-antenna-toolkit/issues>`_ page
to submit questions, report bugs, and request new features.

View antenna toolkit documentation
View toolkit documentation
-----------------------------------------
Documentation for the latest development version, which tracks the
``main`` branch, is hosted at `PyAEDT Antenna toolkit Documentation <https://aedt.antenna.toolkit.docs.pyansys.com/>`_.
``main`` branch, is hosted at `PyAEDT Antenna Toolkit Documentation <https://aedt.antenna.toolkit.docs.pyansys.com/>`_.
This version is automatically kept up to date via GitHub actions.

Adhere to code style
--------------------
PyAEDT antenna toolkit is compliant with `PyAnsys code style
PyAEDT toolkit is compliant with `PyAnsys code style
<https://dev.docs.pyansys.com/coding-style/index.html>`_. It uses the tool
`pre-commit <https://pre-commit.com/>`_ to select the code style. You can install
and activate this tool with:
Expand Down
Loading

0 comments on commit 80dcdef

Please sign in to comment.