rcmaples / shftr

0 stars 0 forks source link

Mobile Assignment failed when Availability was 0 #28

Closed rcmaples closed 2 years ago

rcmaples commented 2 years ago

2021-11-19 08:00:01.032 [shftr] web.1 Total Availability: 0 2021-11-19 08:00:01.036 [shftr] web.1 at runMicrotasks () 2021-11-19 08:00:01.036 [shftr] web.1 (Use node --trace-warnings ... to show where the warning was created) 2021-11-19 08:00:01.036 [shftr] web.1 (node:4) UnhandledPromiseRejectionWarning: TypeError: Cannot destructure property 'zendeskId' of 'winningAgent' as it is undefined. 2021-11-19 08:00:01.036 [shftr] web.1 (node:4) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) 2021-11-19 08:00:01.036 [shftr] web.1 Bowl of Petunias: 0 2021-11-19 08:00:01.036 [shftr] web.1 at assignTicket (/app/utils/ticketAssignment.js:86:9) 2021-11-19 08:00:01.036 [shftr] web.1 (node:4) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. 2021-11-19 08:00:01.036 [shftr] web.1 at processTicksAndRejections (internal/process/task_queues.js:95:5)

image

rcmaples commented 2 years ago

Alright; replicated. This happens when there's only 1 person in the queue and that person doesn't have any queueShare for the queue the ticket came in on.

If Amir is the only person in the queue but has 0% share of Mobile then every ticket that comes into Mobile will throw this error and the ticket won't get assigned.

rcmaples commented 2 years ago

Resolved with #29