Function
stop_task
(
app_handle: AppHandle,
body: ProfileContext,
)
Source from the content-addressed store, hash-verified
| 334 | |
| 335 | @tauri_profile_aware_command |
| 336 | async def stop_task( |
| 337 | app_handle: AppHandle, |
| 338 | body: ProfileContext, |
| 339 | ) -> None: |
| 340 | task_process = task_processes.get(body.profile_index, None) |
| 341 | if task_process and task_process.is_alive(): |
| 342 | logging.info("Stopping Task") |
| 343 | task_process.terminate() |
| 344 | task_process.join() |
| 345 | await asyncio.sleep(0.5) # wait a bit for start_task tear down |
| 346 | |
| 347 | |
| 348 | class CacheClear(ProfileContext): |
Callers
nothing calls this directly
Tested by
no test coverage detected