-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Workflow cmds #180
Workflow cmds #180
Conversation
FYI: I have used WorkflowStatusInternal class and _sys_db method to get workflow status. There is also a WorkflowStatus exposed by the dbos class. If you prefer that we use that, let me know |
Found a minor bug in It's in |
Fixed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
workflows = _list_workflows( | ||
config, limit, user, starttime, endtime, status, request, appversion | ||
) | ||
print(jsonpickle.encode(workflows, unpicklable=False)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we use a standard string representation, not jsonpickle
, for readability?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you mean print it out field by field with our own formatting ?
This is a list of workflowInformation. Python does not know how to serialize it
Even the field by field might not work as there are some fields like input that python might not be able to serialize
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Python might not be able to serialize it, but it can (almost) always stringify it to print it in a human-readable format. My worry with jsonpickle
is that its outputs are often not human-readable. In your testing, how does it look it a workflow, say, returns a list? Is it printed in a human-readable format?
dbos workflow list
dbos workflow get
dbos workflow cancel