at_client_sdk
at_client_sdk copied to clipboard
Notifications sent to self never get a callback.
Describe the bug If an @ sign sends a notification to itself (to notify another client on the same @ sign the call back never gets called. This could be a bug or a limitation not sure but it had me scratching my head for a while To Reproduce Steps to reproduce the behavior:
- First write a small program that sends notification to yourself
- Then call notificationService.notify(NotificationParams.forUpdate(key, value: 'myvalue')
- And then wait and never get success or failure
Expected behavior Whether sending to yourself or another @ sign I would have expected the same behavor
Example
AtClientManager atClientManager = AtClientManager.getInstance();
NotificationService notificationService = atClientManager.notificationService;
var metaData = Metadata()
..isPublic = false
..isEncrypted = true
..namespaceAware = true
..ttr = -1
..ttl = 90000;
var key = AtKey()
..key = 'sshd'
..sharedBy = '@blueamateurbinding'
..sharedWith = '@blueamateurbinding'
..metadata = metaData;
await notificationService
.notify(NotificationParams.forUpdate(key, value: sshString),
onSuccess: (notification) {
_logger.info('SUCCESS:' + notification.toString() + ' ' + sshString);
}, onError: (notification) {
_logger.info('ERROR:' + notification.toString() + ' ' + sshString);
});
onSuccess or onError never get called although all other clients do get the notification.
dart 2.10.4
- Linux
Were you using an @application when the bug was found?
- ssh trigger
Additional context Add any other context about the problem here.
I think we should make this work... But interested in your PoV..
Notifications were deliberately built for sending between different at-signs, it seems, so I think this is probably more of a feature request than a bug
I agree it's useful & I think we should do it once the notifications basics are rock solid
migrated to enhancement
@gkc or @cconstab is this still an active ticket? If so can you please assign a priority or close? TY!
Still active. Will set to Medium priority