RocketChat / RocketChat/Rocket.Chat

Desktop don't play sound work at newest version 3.12.0

Open
#21,077 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
46.1k
Forks
13.9k
Avg merge
3d 3h
Merged PRs (30d)
130

Description

Description:

Does not play sound on the desktop when messages arrive on livechat

Steps to reproduce:

Send a message on livechat that will not play the sound on the desktop

Expected behavior:

Play a sound on the desktop when a message arrives on livehcat

Actual behavior:

User receives a new message and don't get notified. No sound is played and no desktop notification is send out.

Server Setup Information:
  • Version of Rocket.Chat Server: 3.12.0
  • Operating System: Debian 9
  • Deployment Method: tar
  • Number of Running Instances: 1
  • NodeJS Version: v12.18.2
  • MongoDB Version: v4.0.19
Client Setup Information
  • Desktop App or Browser Version: 89.0.4389.82 (Versão oficial) (x86_64)
  • Operating System: MacOs Mojane 10.14.6
Captura de Tela 2021-03-11 às 10 49 22
Additional context
Relevant logs:

I20210311-11:34:19.726(-3) API ➔ debug POST: /api/v1/livechat/visitor
I20210311-11:34:19.794(-3) API ➔ debug Success { statusCode: 200, body: { visitor: { _id: 'pPyJxuL7uQGvFinjo', username: 'guest-2', _updatedAt: 2021-03-11T14:34:19.729Z, name: 'José Sanchez-WhatsApp', phone: [Array], token: '5517988203040', lastChat: [Object], livechatData: [Object] }, success: true } }
I20210311-11:34:19.812(-3) API ➔ debug GET: /api/v1/livechat/room?token=5519988200000
I20210311-11:34:19.876(-3) Integrations ➔ Outgoing WebHook.debug Execute Trigger: sendMessage
I20210311-11:34:19.877(-3) Integrations ➔ Outgoing WebHook.debug Got the event arguments for the event: sendMessage { event: 'sendMessage', message: { t: 'livechat-started', msg: '', groupable: false, ts: 2021-03-11T14:34:19.834Z, u: { _id: 'pPyJxuL7uQGvFinjo', username: 'guest-2', name: 'José Sanchez-WhatsApp' }, rid: 'dgZCg8Kk53u6bPYp9', _id: '2Xx6A4sH6M3PkDifp', tmid: undefined, _updatedAt: 2021-03-11T14:34:19.861Z, editedBy: undefined, editedAt: undefined, emoji: undefined, avatar: undefined, alias: undefined, customFields: undefined, attachments: undefined, reactions: undefined, parseUrls: undefined, blocks: undefined, token: undefined, mentions: [], channels: [] }, room: { _id: 'dgZCg8Kk53u6bPYp9', msgs: 0, usersCount: 1, lm: 2021-03-11T14:34:19.822Z, fname: 'José Sanchez-WhatsApp', t: 'l', ts: 2021-03-11T14:34:19.822Z, departmentId: undefined, v: { _id: 'pPyJxuL7uQGvFinjo', username: 'guest-2', token: '5517988203040', status: 'online' }, cl: false, open: true, waitingResponse: true, _updatedAt: 2021-03-11T14:34:19.822Z } }
I20210311-11:34:19.878(-3) Integrations ➔ Outgoing WebHook.debug Starting search for triggers for the room: dgZCg8Kk53u6bPYp9
I20210311-11:34:19.878(-3) Integrations ➔ Outgoing WebHook.debug Found 0 to iterate over and see if the match the event.
I20210311-11:34:19.926(-3) API ➔ debug Success { statusCode: 200, body: { room: { _id: 'dgZCg8Kk53u6bPYp9', msgs: 0, usersCount: 1, lm: 2021-03-11T14:34:19.822Z, fname: 'José Sanchez-WhatsApp', t: 'l', ts: 2021-03-11T14:34:19.822Z, v: [Object], cl: false, open: true, waitingResponse: true, _updatedAt: 2021-03-11T14:34:19.822Z }, newRoom: true, success: true } }
I20210311-11:34:20.059(-3) API ➔ debug POST: /api/v1/livechat/message
I20210311-11:34:20.085(-3) Integrations ➔ Outgoing WebHook.debug Execute Trigger: sendMessage
I20210311-11:34:20.086(-3) Integrations ➔ Outgoing WebHook.debug Got the event arguments for the event: sendMessage { event: 'sendMessage', message: { _id: 'TamENMZoSzsA2bzrz', rid: 'dgZCg8Kk53u6bPYp9', msg: 'Teste', token: '5517988203040', alias: 'José Sanchez-WhatsApp', ts: 2021-03-11T14:34:20.064Z, u: { _id: 'pPyJxuL7uQGvFinjo', username: 'guest-2', name: 'José Sanchez-WhatsApp' }, tmid: undefined, _updatedAt: 2021-03-11T14:34:20.079Z, editedBy: undefined, editedAt: undefined, emoji: undefined, avatar: undefined, customFields: undefined, groupable: undefined, attachments: undefined, reactions: undefined, parseUrls: undefined, blocks: undefined, mentions: [], channels: [], newRoom: false, showConnecting: true }, room: { _id: 'dgZCg8Kk53u6bPYp9', msgs: 1, usersCount: 1, lm: 2021-03-11T14:34:19.834Z, fname: 'José Sanchez-WhatsApp', t: 'l', ts: 2021-03-11T14:34:19.822Z, v: { _id: 'pPyJxuL7uQGvFinjo', username: 'guest-2', token: '5517988203040', status: 'online' }, cl: false, open: true, _updatedAt: 2021-03-11T14:34:19.879Z, lastMessage: { t: 'livechat-started', msg: '', groupable: false, ts: 2021-03-11T14:34:19.834Z, u: [Object], rid: 'dgZCg8Kk53u6bPYp9', _id: '2Xx6A4sH6M3PkDifp', _updatedAt: 2021-03-11T14:34:19.861Z, mentions: [], channels: [] }, metrics: { reaction: [Object], response: [Object] }, responseBy: { _id: 'pPyJxuL7uQGvFinjo', username: 'guest-2', lastMessageTs: 2021-03-11T14:34:19.879Z } } }
I20210311-11:34:20.087(-3) Integrations ➔ Outgoing WebHook.debug Starting search for triggers for the room: dgZCg8Kk53u6bPYp9
I20210311-11:34:20.088(-3) Integrations ➔ Outgoing WebHook.debug Found 0 to iterate over and see if the match the event.
I20210311-11:34:20.096(-3) API ➔ debug Success { statusCode: 200, body: { message: { _id: 'TamENMZoSzsA2bzrz', rid: 'dgZCg8Kk53u6bPYp9', msg: 'Teste', token: '5519988200000', alias: 'José Sanchez-WhatsApp', ts: 2021-03-11T14:34:20.064Z, u: [Object], _updatedAt: 2021-03-11T14:34:20.079Z, mentions: [], channels: [] }, success: true } }
I20210311-11:34:20.122(-3) API ➔ debug GET: /api/v1/livechat/agent.info/dgZCg8Kk53u6bPYp9/5517988203040
I20210311-11:34:20.126(-3) API ➔ debug Failure { statusCode: 400, body: errorClass [Error]: [invalid-agent] at Object.get (app/livechat/server/api/v1/agent.js:28:11) at app/api/server/api.js:394:82 at Meteor.EnvironmentVariable.EVp.withValue (packages/meteor.js🔢12) at Object._internalRouteActionHandler [as action] (app/api/server/api.js:394:39) at Route.share.Route.Route._callEndpoint (packages/nimble_restivus/lib/route.coffee:150:32) at packages/nimble_restivus/lib/route.coffee:59:33 at packages/simple_json-routes.js:98:9 { isClientSafe: true, error: 'invalid-agent', reason: undefined, details: undefined, errorType: 'Meteor.Error', success: false } }
I20210311-11:34:20.292(-3) API ➔ debug POST: /api/v1/method.call/private-settings:get
I20210311-11:34:20.293(-3) Meteor ➔ method private-settings/get -> userId: w82AiaFnCyxy5N5Sy, arguments: [{}]
I20210311-11:34:20.302(-3) API ➔ debug Success { statusCode: 200, body: { message: '{"msg":"result","id":"401","result":{"update":[],"remove":[]}}', success: true } }

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file or test is named. Start by reproducing the livechat message flow in the desktop app or browser using the reported setup, then trace the client-side sound and desktop-notification entry points. Done means an arriving livechat message reliably plays a sound and sends a desktop notification.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.