Skip to content

Conversation

@slitayem
Copy link

No description provided.

actions_results[method_name] = method(**params)

return dict((method_name, actions_results[method_name]) for method_name
in actions_results.keys() if actions_results.get(method_name))

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

what if None is expected result from method? you should not filter None value

@bhargavrpatel
Copy link

bhargavrpatel commented Jan 5, 2020

I am wondering if there is still interest in seeing this one through (edit: I am happy to create a separate PR if not). This is a valid use case. One alternative approach here would be to return a tuple in all cases. The first element is the result bool, the second is the output. This would allow us to consider None as a valid result.

@jreeter
Copy link

jreeter commented Nov 14, 2020

@bhargavrpatel We also have a need for this use case. Ideally, though we could return a business description with the resulting value. My initial ideas were to tag the conditions with a unique id, these ids could be linked to descriptions end users could understand. We essentially want end users to understand how the engine arrived at the result.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants