You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You should avoid using wild cards in imports because doing so
97
93
can make it difficult to detect undefined names. For more information,
98
-
see `Python Anti-Patterns: using wildcard imports<(https://docs.quantifiedcode.com/python-anti-patterns/maintainability/from_module_import_all_used.html>`_.
94
+
see `Python Anti-Patterns: using wildcard imports`_.
99
95
100
96
Instead of:
101
97
@@ -259,7 +255,7 @@ from PyPi.
259
255
260
256
Class Naming Conventions
261
257
~~~~~~~~~~~~~~~~~~~~~~~~
262
-
Use `camel case<https://en.wikipedia.org/wiki/Camel_case>`_ when naming classes. Do not separate words
258
+
Use `camel case`_ when naming classes. Do not separate words
263
259
with underscores.
264
260
265
261
.. code:: python
@@ -433,21 +429,17 @@ same line:
433
429
434
430
For a multi-line docstring, put the ending ``"""`` on a line by itself.
docstring style, which is used by `numpy <https://numpy.org/>`_,
439
-
`scipy <https://www.scipy.org/>`_, `pandas
440
-
<https://pandas.pydata.org/>`_, and a variety of other Python open
441
-
source projects. For more information on docstrings for PyAnsys
442
-
libraries, see :ref:`api_documentation`.
432
+
`PyAEDT`_ follows the `numpydoc`_ docstring style, which is used by `numpy`_
433
+
`scipy`_, `pandas`_, and a variety of other Python open source projects. For
434
+
more information on docstrings for PyAnsys libraries, see
435
+
:ref:`API Documentation Style`.
443
436
444
437
445
438
Programming Recommendations
446
439
~~~~~~~~~~~~~~~~~~~~~~~~~~~
447
-
The following sections provide some `PEP8
448
-
<https://www.python.org/dev/peps/pep-0008/>`_ suggestions for removing
449
-
ambiguity and preserving consistency. They address some common pitfalls
450
-
when writing Python code.
440
+
The following sections provide some `PEP 8`_ suggestions for removing ambiguity
441
+
and preserving consistency. They address some common pitfalls when writing
442
+
Python code.
451
443
452
444
453
445
Booleans and Comparisons
@@ -714,6 +706,13 @@ Any library should be secure and implement good practices that avoid or mitigate
714
706
This is especially relevant in libraries that request user input (such as web services).
715
707
Because security is a broad topic, we recommend you review this useful Python-specific resource:
716
708
717
-
* `10 Unknown Security Pitfalls for Python<https://blog.sonarsource.com/10-unknown-security-pitfalls-for-python>`_ - By Dennis Brinkrolf - Sonar source blog
709
+
* `10 Unknown Security Pitfalls for Python`_ - By Dennis Brinkrolf - Sonar source blog
718
710
719
-
.. [#] Wikipedia - `Software development security <https://en.wikipedia.org/wiki/Software_development_security>`_.
711
+
712
+
.. LINKS AND REFERENCES
713
+
.. include:: ../links.rst
714
+
.. [#] Wikipedia - Software development security https://en.wikipedia.org/wiki/Software_development_security
715
+
.. _10 Unknown Security Pitfalls for Python: https://blog.sonarsource.com/10-unknown-security-pitfalls-for-python
0 commit comments