Open jsejcksn opened 4 years ago
Thid-party processing
I think the way you did it is correct. Any part of the action
after converting the file is not blocking. As in, Kap will move on to the next export while this is happening. So I would assume the action would set an indeterminate progress with a status of Processing
and poll the endpoint until it's ready. If the status comes as error, then it can fail. But if it's still processing I would assume the polling would continue without giving up
Messaging
We can add an action to the notification, as an optional second parameter, which will be called when the notification is clicked
Tests
If you are asking about testing the integration of the plugin with Kap, you can look into, you can look how to utilize the test modules we have available in this example
But if it's still processing I would assume the polling would continue without giving up
It should give up at some point though and show a timeout error. However, it's really up to the plugin author to decide how long it should try before timing out.
We can add an action to the notification, as an optional second parameter, which will be called when the notification is clicked
👍
But if it's still processing I would assume the polling would continue without giving up
It should give up at some point though and show a timeout error. However, it's really up to the plugin author to decide how long it should try before timing out.
Do you have a recommendation for your UX guidelines?
Currently, I wait for up to 1 min—and then, if it's still processing, I return the link to the unprocessed upload in the clipboard, informing the user of the unprocessed state in a notification.
@jsejcksn Hmm, I think I would either return the URL to the unprocessed upload almost right away or just wait until it's completely done. Does images too also need processing?
Does images too also need processing?
I'm not sure what you mean by this.
Do GIFs also need processing? I'm just trying to get a clear picture on how it works. Because if not, or if they have a very short processing time, I would wait for it.
Ah, I see. I have not found any documentation that indicates a relationship between filetype and processing time. In my experience, pixels and frames have more effect on processing time.
I want to include this idea here:
It'd be nice to have a way to show the user something like a log of temporary, but persisting information which can include links. Like if the export progress window had a "details" view for each export that could be expanded and could be directly linked to from notifications.
I just finished writing a gfycat plugin for Kap and the experience made me consider a couple of things about the system:
Thid-party processing The
setProgress
method is nice for known progress, but what about less-controlled aspects of uploading, like when the storage host also processes the uploaded file before making it available for consumption? Should we return from theaction
function after uploading completes, providing the user with a link that might not work yet? Or should we attempt to wait for processing to complete? And what if the host does not provide incremental detail about the processing? How long do we wait before timing out and giving up? How often do we poll and how do we convey this status? You can see how I tried to handle it in my first attempt, but there must be a better way.Messaging Notifications are ideal for this context, but I found myself wanting to convey richer information than the short static text allowed by a notification. It would be nice to be able to associate a URL to the notification so that the user can click it and see more information. This would also alleviate the need for replacing the user's clipboard contents (a destructive behavior, which is not ideal). Alternatively, the notification could be clicked to open a window in Kap with more text that can include URLs, etc.
Tests I'm not really sure what kinds of tests to create, as all of the data inputs produce results that aren't idempotent or deterministic.
Does anyone have thoughts about these and how they might be addressed?