isamert / scli

a simple terminal user interface for signal messenger (using signal-cli)
GNU General Public License v3.0
439 stars 40 forks source link

Wrong sender in reaction notification #162

Closed maximbaz closed 2 years ago

maximbaz commented 2 years ago

When I receive a reaction on my message, notification contains my name, not the one who reacted.

Debug log:

DEBUG:root:Daemon: json_data =
{'account': '+ME',
 'envelope': {'dataMessage': {'expiresInSeconds': 0,
                              'message': None,
                              'reaction': {'emoji': '❤️',
                                           'isRemove': False,
                                           'targetAuthor': '+ME',
                                           'targetAuthorNumber': '+ME',
                                           'targetAuthorUuid': 'xxx',
                                           'targetSentTimestamp': 1643404298094},
                              'timestamp': 1643404310642,
                              'viewOnce': False},
              'source': '+THEM',
              'sourceDevice': 1,
              'sourceName': 'Jane Smith',
              'sourceNumber': '+THEM',
              'sourceUuid': 'yyy',
              'timestamp': 1643404310642}}
DEBUG:root:callf: `['notify-send', 'MaximBaz', 'New Signal message']`

My config contains notification-command = notify-send "%s" "New Signal message"

As you can see, I got notification with the title "MaximBaz", but I expect it to be "Jane Smith" from the data above.

UPDATE: I have just seen the issue is not only with reaction to my messages, if a person A posted a message and person B reacted on it, the notification will state that it was person A who reacted.

exquo commented 2 years ago

Ok, I see the problem. Thanks! Will create a fix soon.