Skip to content

Commit b7f89f7

Browse files
authored
Doc: flake8 todos (#1981)
* doc: added links for context * doc: changed to a central issue link
1 parent fd0c755 commit b7f89f7

File tree

6 files changed

+12
-3
lines changed

6 files changed

+12
-3
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ select = [
7171
# "I", # isort, see https://beta.ruff.rs/docs/rules/#isort-i
7272
# "N", # pep8-naming, see https://beta.ruff.rs/docs/rules/#pep8-naming-n
7373
"PTH", # flake9-use-pathlib, https://beta.ruff.rs/docs/rules/#flake8-use-pathlib-pth
74-
# "TD", # flake8-todos, https://docs.astral.sh/ruff/rules/#flake8-todos-td
74+
"TD", # flake8-todos, https://docs.astral.sh/ruff/rules/#flake8-todos-td
7575
]
7676
ignore = [
7777
# pycodestyle

src/ansys/dpf/core/core.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -427,6 +427,7 @@ def load_library(self, file_path, name="", symbol="LoadOperators", generate_oper
427427
)
428428
if generate_operators:
429429
# TODO: fix code generation upload posix
430+
# https://github.com/ansys/pydpf-core/issues/1984, todo was added in this PR
430431

431432
def __generate_code(TARGET_PATH, filename, name, symbol):
432433
from ansys.dpf.core.dpf_operator import Operator

src/ansys/dpf/core/fields_container.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,8 @@ def animate(self, save_as=None, deform_by=None, scale_factor=1.0, **kwargs):
584584
if frequencies is None:
585585
raise ValueError("The fields_container has no time_frequencies.")
586586

587-
# TODO /!\ We should be using a mechanical::time_selector, however it is not wrapped.
587+
# TODO: /!\ We should be using a mechanical::time_selector, however it is not wrapped.
588+
# https://github.com/ansys/pydpf-core/issues/1984, todo was added in this PR
588589

589590
wf.set_input_name("indices", extract_field_op.inputs.indices) # Have to do it this way
590591
wf.connect("indices", forward_index) # Otherwise not accepted

src/ansys/dpf/core/help.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,9 @@ def _check_type(instance, allowable_type):
4040

4141

4242
# TODO: deprecate this file
43+
# https://github.com/ansys/pydpf-core/issues/1984, todo was added in this PR
44+
45+
4346
def sum(var_inp):
4447
"""Sum all elementary data of a field to get one elementary data.
4548
@@ -228,6 +231,9 @@ def eqv(var_inp):
228231

229232

230233
# TODO: Consider combining eqv and eqv_fc
234+
# https://github.com/ansys/pydpf-core/issues/1984, todo was added in this PR
235+
236+
231237
def _eqv(field):
232238
"""Retrieve the von Mises stress field.
233239

src/ansys/dpf/core/server_types.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -416,6 +416,7 @@ class BaseServer(abc.ABC):
416416
def __init__(self):
417417
"""Define the base class for all server types, including grpc, in-process, and others."""
418418
# TODO: Use _server_id to compare servers for equality?
419+
# https://github.com/ansys/pydpf-core/issues/1984, todo was added in this PR
419420
self._server_id = None
420421
self._session_instance = None
421422
self._base_service_instance = None

tests/test_operator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,7 @@ def test_subresults_operator(cyclic_lin_rst, cyclic_ds):
509509
# model = dpf.core.Model(cyclic_lin_rst)
510510
# model.add_file_path(cyclic_ds)
511511

512-
# # TODO: this should be available from model's available_results
512+
# # TODO: this should be available from model's available_results # noqa: TD003
513513
# op = model.operator("mapdl::rst::U")
514514
# op.inputs.connect(model._data_sources)
515515
# op.inputs.bool_ignore_cyclic.connect(True)

0 commit comments

Comments
 (0)