TaskLogs
Introduction
TheTaskLogs
widget in Supervisely is designed to display task logs for a given task ID.
ℹ️ This widget will display logs only when the application with the widget is released in production. In development mode, a message will be shown:
"You are currently in development mode. Task logs will be displayed only in production mode."
Function signature
Parameters
task_id
int
The task ID to display logs for
widget_id
str
ID of the widget
task_id
The task ID to display logs for.
type: str
default value: None
widget_id
ID of the widget.
type: str
default value: None
Methods and attributes
get_task_id()
Get the task ID.
set_task_id(task_id: int)
Set the task ID.
Mini App Example
You can find this example in our Github repository:
supervisely-ecosystem/ui-widgets-demos/status-elements/005_task_logs/src/main.py
Import libraries
ℹ️ This widget will display logs only when the application with the widget is released in production. In development mode, a message will be shown:
"You are currently in development mode. Task logs will be displayed only in production mode."
Initialize TaskLogs
widget we will use in UI
TaskLogs
widget we will use in UIor
Add Button
and InputNumber
widgets to use in demo
Button
and InputNumber
widgets to use in demoCreate app layout
Prepare a layout for app using Card
widget with the content
parameter and place widget that we've just created in the Container
widget.
Create app using layout
Create an app object with layout
parameter.
Add function to controls widgets from python code
Last updated