Question
· Jun 16

How to get Task Status through IRISNAtive/Python

Hi,

After  executing a task using RunNow() method of class %SYS.task i am not able to find suitable method for getting the status in %SYS.Task class. Please help how to get the task status throuhgh Python/IRISNAtive for Python combination

Discussion (4)2
Log in or sign up to continue

If I understand correctly, you want the Status property of a given task. In that case, this is going to be similar to your other question about fetching the gmheap property, except that you'll call a slightly different method to open the object:

task = native.classMethodValue('%SYS.Task', '%OpenId', id)
task.get('Status')

Since you're able to call RunNow(), I assume that you know the ID of the task. The same idea will work for the Error property.

If you're stuck with the ancient 1.0.0 wheel for some reason, you'll have to write helper class methods of your own.