Laurens Valk
52b3b4c007
pybricks.tools.read_input_byte: Add last and chr options.
2024-04-04 21:45:26 +02:00
Laurens Valk
7acdfc035e
pybricks.tools: Document run loop active check.
2024-03-05 15:00:03 +01:00
Laurens Valk
209fba5c7e
pybricks.tools: Document multitasking.
2023-10-24 17:05:10 +02:00
Laurens Valk
faf11581c0
pybricks.tools: Document hub_menu.
...
Fixes https://github.com/pybricks/pybricks-api/issues/144
2023-10-24 16:23:59 +02:00
David Lechner
821a3e4455
pybricks.*: add MaybeAwaitable types
...
Many blocking functions now return Awaitable[T] when the async run
loop is running. The static analysis tools don't have a way of
knowing this, so the best we can do is return both types so that
x = method() and x = await method() both work mostly as expected.
2023-06-12 17:04:09 -05:00
David Lechner
41b9ce71dd
pybricks.tools: add read_input_byte()
...
This adds stubs and docs for the new `pybricks.tools.read_input_byte()`
function.
2023-06-12 11:06:20 -05:00
Laurens Valk
be9f99d41b
pybricks.tools: Add category headings.
2023-04-21 13:59:16 +02:00
Laurens Valk
870aae83c0
pybricks.tools: Document cross product.
2023-04-21 13:39:08 +02:00
Laurens Valk
9cde749e8a
pybricks.geometry: Drop module.
...
See https://github.com/pybricks/pybricks-micropython/pull/160
2023-04-21 13:33:19 +02:00
David Lechner
e95386e23e
jedi: improve signature information
...
This fixes numerous issues where jedi provided incomplete or poorly
formatted signatures and docstrings.
Issue: https://github.com/pybricks/pybricks-code/issues/932
2022-06-25 23:54:49 -05:00
Laurens Valk
6500440031
pybricks: Drop most ellipsis and pass instances.
...
See [1]: "I still prefer ... over pass. This clarifies to the readers that they are reading a stub. But if there's a docstring we need neither."
[1] https://github.com/srittau/type-stub-pep/issues/88#issuecomment-758843441
Fixes https://github.com/pybricks/pybricks-api/issues/101#issuecomment-1148780369
2022-06-10 10:46:44 +02:00
Laurens Valk
31256d70c1
pybricks.tools: Add typing.
2022-06-10 10:05:12 +02:00
Laurens Valk
bd7806d2d4
all: Format with black.
...
Also activate auto formatting. Bump flake8 and mark black
disagreements in setup.cfg.
2022-05-27 16:22:05 +02:00
David Lechner
7126431f9f
pybricks: move into src/ directory
...
Moving the pybricks package into a src/ directory so that we can add
additional packages without polluting the top-level directory.
2021-07-14 09:41:30 +02:00