FDC3 Workbench intent raising control could be more intuitive
Minor Issue
Please use minor issues for discrepancies or errors found in the spec or supporting documentation, examples, and other materials. If you wish to propose a new feature or a revision to an existing feature, please use the Enhancement Request template.
Area of Issue
- [ ] App Directory
- [ ] API
- [ ] Context Data
- [ ] Intents
- [ ] Desktop Agent Bridging
- [ ] Use Cases
- [x] Other
Issue Description:
When using the FDC3 workbench to test raising an intent I do not seem to be able to raise an intent. If I select an intent and click the "Raise Intent" button I get a validation error saying "Please Select a Context First":
It should be possible to raise an intent without a conext so IMHO this is an error but when I try to select a context I am unable to select an intent:
I am able to type in an intent and add that. Once I have done that I am able to raise an intent (this always fails but I suspect this is beacuse there are no listeners).
context is a required parameter in raiseIntent:
raiseIntent(intent: string, context: Context, app?: AppIdentifier): Promise<IntentResolution>;
https://fdc3.finos.org/docs/api/ref/DesktopAgent#raiseintent
Riasing an intent without context is done by passing the fdc3.nothing context, as described here: https://fdc3.finos.org/docs/api/spec#intents-and-context
Perhaps the fdc3.nothing context type could/should be selected by default?
I am able to type in an intent and add that. Once I have done that I am able to raise an intent (this always fails but I suspect this is beacuse there are no listeners).
Yeah, it's likely responding with ResolveError.NoAppsFound if its a made up intent. The field accepts any string so that unstandardized intetns can be entered. From memroy, if you set a context it auto-populates the list with intents that have handlers...
@Roaders did I manage to explain this away? If not we can pick up in the meeting in an hour...
No I'm afraid not, I'm pretty sure it's not behaving as it should. I am planning to be at the meeting but having issues with South west rail at the moment!
I'd propose:
- Making the "Raise Intent" button disabled until both the context and the intent are selected.
- If the intent type has no options, instead of saying "no options", it could say "No apps have registered intents that support the selected context."
Turns out that this was user error and just a little explanation as suggested by @julianna-ciq would make the situation much clearer.
We should probably also disable the Intent selection list until a context has been selected. Any selection that's made in there is removed when a context is selected anyway.