Skip to content

Commit 4aa71eb

Browse files
committed
Merge branch 'main' into release/0.6
2 parents 5675561 + fe68ac8 commit 4aa71eb

File tree

102 files changed

+1185
-1753
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+1185
-1753
lines changed

.flake8

Lines changed: 0 additions & 7 deletions
This file was deleted.

.pre-commit-config.yaml

Lines changed: 4 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -6,46 +6,17 @@ ci:
66
exclude: "tests/integration/files"
77
repos:
88

9-
- repo: https://github.com/psf/black
10-
rev: 24.4.2 # IF VERSION CHANGES --> MODIFY "blacken-docs" MANUALLY AS WELL!!
9+
- repo: https://github.com/astral-sh/ruff-pre-commit
10+
rev: v0.4.9
1111
hooks:
12-
- id: black
13-
14-
- repo: https://github.com/adamchainz/blacken-docs
15-
rev: 1.16.0
16-
hooks:
17-
- id: blacken-docs
18-
additional_dependencies: [black==24.4.2]
19-
20-
- repo: https://github.com/pycqa/isort
21-
rev: 5.13.2
22-
hooks:
23-
- id: isort
24-
25-
- repo: https://github.com/PyCQA/flake8
26-
rev: 7.1.0
27-
hooks:
28-
- id: flake8
29-
30-
- repo: https://github.com/PyCQA/docformatter
31-
rev: v1.7.5
32-
hooks:
33-
- id: docformatter
34-
additional_dependencies: [tomli]
12+
- id: ruff
3513

3614
- repo: https://github.com/codespell-project/codespell
3715
rev: v2.3.0
3816
hooks:
3917
- id: codespell
4018
args: ["--ignore-words", "doc/styles/config/vocabularies/ANSYS/accept.txt", "-w"]
4119

42-
- repo: https://github.com/pycqa/pydocstyle
43-
rev: 6.3.0
44-
hooks:
45-
- id: pydocstyle
46-
additional_dependencies: [tomli]
47-
exclude: "tests/"
48-
4920
- repo: https://github.com/pre-commit/pre-commit-hooks
5021
rev: v4.6.0
5122
hooks:
@@ -55,7 +26,7 @@ repos:
5526
- id: trailing-whitespace
5627

5728
- repo: https://github.com/ansys/pre-commit-hooks
58-
rev: v0.3.1
29+
rev: v0.3.2
5930
hooks:
6031
- id: add-license-headers
6132
files: '(src|examples|tests|docker)/.*\.(py)|\.(proto)'

README.rst

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
PyAnsys Geometry
22
================
3-
|pyansys| |python| |MIT| |black|
3+
|pyansys| |python| |MIT| |ruff|
44
|codecov| |GH-CI| |pre-commit|
55
|pypi| |pypi-downloads| |conda| |conda-downloads|
66

@@ -40,9 +40,9 @@ PyAnsys Geometry
4040
:target: https://opensource.org/blog/license/mit
4141
:alt: MIT
4242

43-
.. |black| image:: https://img.shields.io/badge/code%20style-black-000000.svg?style=flat
44-
:target: https://github.com/psf/black
45-
:alt: Black
43+
.. |ruff| image:: https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json
44+
:target: https://github.com/astral-sh/ruff
45+
:alt: Ruff
4646

4747
.. |pre-commit| image:: https://results.pre-commit.ci/badge/github/ansys/pyansys-geometry/main.svg
4848
:target: https://results.pre-commit.ci/latest/github/ansys/pyansys-geometry/main

doc/changelog.d/1273.changed.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
chore: update CHANGELOG for v0.6.3

doc/changelog.d/1274.added.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
feat: using ruff as the main linter/formatter

doc/changelog.d/1275.fixed.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
fix: backticks breaking doc build after ruff linter

doc/changelog.d/1276.changed.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
chore: bump pre-commit-hook version

doc/changelog.d/1277.dependencies.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
build: bump pint from 0.24 to 0.24.1

doc/source/conf.py

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def get_wheelhouse_assets_dictionary():
5454
content = response.content
5555
break
5656
else:
57-
print(f"Failed to retrieve the latest release. Retrying...")
57+
print("Failed to retrieve the latest release. Retrying...")
5858
time.sleep(2)
5959

6060
if content is None:
@@ -83,8 +83,7 @@ def get_wheelhouse_assets_dictionary():
8383

8484

8585
def intersphinx_pyansys_geometry(switcher_version: str):
86-
"""
87-
Auxiliary method to build the intersphinx mapping for PyAnsys Geometry.
86+
"""Auxiliary method to build the intersphinx mapping for PyAnsys Geometry.
8887
8988
Notes
9089
-----
@@ -383,8 +382,7 @@ def intersphinx_pyansys_geometry(switcher_version: str):
383382

384383

385384
def convert_notebooks_to_scripts(app: sphinx.application.Sphinx, exception):
386-
"""
387-
Convert notebooks to scripts.
385+
"""Convert notebooks to scripts.
388386
389387
Parameters
390388
----------
@@ -431,15 +429,14 @@ def convert_notebooks_to_scripts(app: sphinx.application.Sphinx, exception):
431429

432430

433431
def setup(app: sphinx.application.Sphinx):
434-
"""
435-
Run different hook functions during the documentation build.
432+
"""Run different hook functions during the documentation build.
436433
437434
Parameters
438435
----------
439436
app : sphinx.application.Sphinx
440437
Sphinx instance containing all the configuration for the documentation build.
441438
"""
442-
logger.info(f"Configuring Sphinx hooks...")
439+
logger.info("Configuring Sphinx hooks...")
443440
if BUILD_EXAMPLES:
444441
# Run at the end of the build process
445442
logger.info("Connecting build-finished hook for converting notebooks to scripts...")

doc/source/contributing.rst

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -71,19 +71,14 @@ This way, it's not possible for you to push code that fails the style checks::
7171

7272
$ pre-commit install
7373
$ git commit -am "added my cool feature"
74-
black....................................................................Passed
75-
blacken-docs.............................................................Passed
76-
isort....................................................................Passed
77-
flake8...................................................................Passed
78-
docformatter.............................................................Passed
74+
ruff.....................................................................Passed
7975
codespell................................................................Passed
80-
pydocstyle...............................................................Passed
8176
check for merge conflicts................................................Passed
8277
debug statements (python)................................................Passed
8378
check yaml...............................................................Passed
8479
trim trailing whitespace.................................................Passed
85-
Add License Headers......................................................Passed
8680
Validate GitHub Workflows................................................Passed
81+
check pre-commit.ci config...............................................Passed
8782

8883
Build the documentation
8984
-----------------------

0 commit comments

Comments
 (0)