Mose Müller
ece68b4b99
docs: updates Task documentation
...
- updates Tasks.md
- updates docstrings
- adds api section
2024-09-16 15:30:47 +02:00
Mose Müller
0c95b5e3cb
frontend: removes AsyncMethodComponent (replaced by Task)
2024-09-16 14:22:29 +02:00
Mose Müller
2f5a640c4c
chore: refactored task autostart
2024-09-16 14:17:20 +02:00
Mose Müller
78964be506
adds serialization and deserialization support for task objects
2024-09-16 13:58:58 +02:00
Mose Müller
fbdf6de63c
npm run build
2024-09-16 13:58:16 +02:00
Mose Müller
62f28f79db
adds list and dictionary entries to task autostart
2024-09-16 07:53:44 +02:00
Mose Müller
e422d627af
adds docstring to autostart method
2024-09-13 16:07:30 +02:00
Mose Müller
71adc8bea2
adds autostart to server
2024-09-13 12:37:29 +02:00
Mose Müller
bfa0acedab
moves autostart from Task to separate autostart submodule
2024-09-13 12:37:18 +02:00
Mose Müller
416b9ee815
removes part of serializer for serializing start and stop methods of async methods
2024-09-13 11:27:30 +02:00
Mose Müller
d1d2ac2614
fixing circular import
2024-09-13 11:27:30 +02:00
Mose Müller
fa35fa53e2
removes TaskManager
2024-09-13 11:27:30 +02:00
Mose Müller
c0e5a77d6f
simplifies @task decorator (updates types), moves task logic into Task's run_task()
2024-09-13 11:27:30 +02:00
Mose Müller
96cc7b31b4
updates documentation
2024-09-13 11:27:30 +02:00
Mose Müller
0d6d312f68
chore: fixes type hints for python 3.10
2024-09-13 11:27:30 +02:00
Mose Müller
be3011c565
adapt device connection component to use @task decorator
2024-09-13 11:27:30 +02:00
Mose Müller
09fae01985
adds warning when _bound_func has not been bound yet
...
This might arise when calling the start method of a task which is part of a class
that has not been instantiated yet.
2024-09-13 11:27:30 +02:00
Mose Müller
12c0c9763d
delay task setup until called from class instance containing the task
2024-09-13 11:27:30 +02:00
Mose Müller
15322b742d
using explicit loop to create task even if loop is not running yet
2024-09-13 11:27:30 +02:00
Mose Müller
85d6229aa6
updates DataService import to avoid circular import
2024-09-13 11:27:30 +02:00
Mose Müller
083fab0a29
Carefully setting up asyncio event loop
2024-09-13 11:27:30 +02:00
Mose Müller
2a1aff589d
properly binding task method
2024-09-13 11:27:30 +02:00
Mose Müller
3cd7198747
task can only wrap async functions without arguments
2024-09-13 11:27:30 +02:00
Mose Müller
1e02f12794
adds autostart flag to task
2024-09-13 11:27:30 +02:00
Mose Müller
e4a3cf341f
task can receive bound and unbound functions now
2024-09-13 11:27:30 +02:00
Mose Müller
7ddcd97f68
fixing ruff and mypy errors
2024-09-13 11:27:30 +02:00
Mose Müller
80da96657c
tasks: don't start another task when it is already running
2024-09-13 11:27:30 +02:00
Mose Müller
861e89f37a
task: using functools to get correct func name
2024-09-13 11:27:30 +02:00
Mose Müller
c00cf9a6ff
updating property dependencies in PropertyObserver
...
As Task objects have to be class attributes, I have to loop through class attributes, as well
when calculating nested observables properties.
2024-09-13 11:27:30 +02:00
Mose Müller
ed7f3d8509
dont make descriptors attributes of the instance -> would loose functionality
2024-09-13 11:27:30 +02:00
Mose Müller
456090fee9
adds is_descriptor helper method
2024-09-13 11:27:30 +02:00
Mose Müller
e69ef376ae
replaces some code with helper function
2024-09-13 11:27:30 +02:00
Mose Müller
5f78771f66
tasks: need to bind method as soon as instance is passed to __get__
...
I cannot keep a reference to the parent class as the Task class is a DataService, as well.
2024-09-13 11:27:30 +02:00
Mose Müller
09ceae90ec
tasks: only care about async methods right now
2024-09-13 11:27:30 +02:00
Mose Müller
c34351270c
feat: first Task implementation
2024-09-13 11:27:29 +02:00
Mose Müller
743c18bdd7
fix: need to compare with serialized value (for enums)
2024-09-13 11:27:29 +02:00
Mose Müller
ab9b4257f2
adds overwritable sio client_manager
2024-08-28 12:37:56 +02:00
Mose Müller
a2effca2b0
fixes ruff errors
2024-08-20 13:14:03 +02:00
Mose Müller
dbc1fa00f7
adds autogenerated api documentation
2024-08-20 12:03:08 +02:00
Mose Müller
b1f75bb786
makes handle_server_shutdown a protected method
2024-08-20 11:50:27 +02:00
Mose Müller
0011a0f92e
fix: uses logger instead of logging in sio events
2024-08-20 08:30:13 +02:00
Mose Müller
b7ab364aab
adds "testing" operation mode
2024-08-20 08:29:54 +02:00
Mose Müller
6765246231
fixing ruff formatting error
2024-08-19 09:53:54 +02:00
Mose Müller
82d6a7f895
adds a context manager to the client, fixes running loop issue
2024-08-13 07:14:33 +02:00
Mose Müller
42357d7901
breaking: client takes url instead of hostname and port
...
Connecting to secure services (with wss) was not possible.
The user has to provide the whole URL now, which makes it much more flexible and less bug-prone.
2024-08-12 13:15:17 +02:00
Mose Müller
e0d710644b
sio_setup: removes unused function
2024-08-05 05:27:17 +02:00
Mose Müller
9663dea79d
feat: allow monkey patching serilization methods for api endpoints
2024-07-31 08:44:23 +02:00
Mose Müller
bd6220cb9e
chore: refactoring state_manager
2024-07-30 10:17:43 +02:00
Mose Müller
1fb296c3c1
removes read-only check from state manager's set_service_attribute_value_by_path
2024-07-30 10:15:34 +02:00
Mose Müller
bfe2d82c0b
api: getting value from service instead of cache
2024-07-30 09:30:28 +02:00