Skip to content

Commit 6001dfe

Browse files
committed
require flake8-idom-hooks 0.2.0
1 parent ce3216f commit 6001dfe

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

Diff for: docs/source/life-cycle-hooks.rst

+4-2
Original file line numberDiff line numberDiff line change
@@ -338,14 +338,16 @@ the ``lint`` extra for IDOM:
338338

339339
.. code-block:: bash
340340
341-
pip install idom[stable,lint]
341+
pip install flake8-idom-hooks
342342
343-
Once installed running ``flake8`` on your could will start catching errors:
343+
Once installed running, ``flake8`` on your code will start catching errors. For example:
344344

345345
.. code-block:: bash
346346
347347
flake8 my_idom_elements.py
348348
349+
Might produce something like the following output:
350+
349351
.. code-block:: text
350352
351353
./my_idom_elements:10:8 ROH102 hook 'use_effect' used inside if statement

Diff for: requirements/extras.txt

-3
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,3 @@ matplotlib
99
htm
1010
pyalect
1111
tagged
12-
13-
# extra=lint
14-
flake8-idom-hooks

Diff for: requirements/lint.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
black
22
flake8
33
pep8-naming
4-
flake8-idom-hooks
4+
flake8-idom-hooks >=0.2.0

Diff for: tests/test_core/test_hooks.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -748,7 +748,8 @@ async def test_use_memo_with_stored_args_is_empty_tuple_after_args_are_none():
748748
@element_hook.capture
749749
def ElementWithMemo():
750750
value = idom.hooks.use_memo(
751-
lambda: next(iter_values), args_used_in_memo.current
751+
lambda: next(iter_values),
752+
args_used_in_memo.current, # noqa: ROH202
752753
)
753754
used_values.append(value)
754755
return idom.html.div()

0 commit comments

Comments
 (0)