Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: First response time livechat metrics are associated with the last agent who served the room #34156

Merged
merged 11 commits into from
Dec 16, 2024

Conversation

matheusbsilva137
Copy link
Member

@matheusbsilva137 matheusbsilva137 commented Dec 10, 2024

Proposed changes (including videos or screenshots)

  • Fixed rooms' "first response time" metric being attached to the last agent who served a room instead of the first one -- this leads to incorrect values for the "Best first response time" and "Average first response time" metrics for each agent in case rooms are forwarded among agents/departments.

Issue(s)

Steps to test or reproduce

Make sure to grant the transfer-livechat-guest permission to agents or to a manager.
Create a new agent and respond a livechat room with it, then transfer the room to another one. The "first response time" aggregation metrics are available under Omnichannel > Analytics > Productivity (or by using the livechat/analytics/agent-overview endpoint), and we need to make sure that both metrics related to the room that has been transferred are associated to the first agent who responded to the room (and not to the last one who served it).

Further comments

CORE-669

@matheusbsilva137 matheusbsilva137 added this to the 7.2.0 milestone Dec 10, 2024
Copy link
Contributor

dionisio-bot bot commented Dec 10, 2024

Looks like this PR is ready to merge! 🎉
If you have any trouble, please check the PR guidelines

Copy link

changeset-bot bot commented Dec 10, 2024

🦋 Changeset detected

Latest commit: 5fae225

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 35 packages
Name Type
@rocket.chat/meteor Patch
@rocket.chat/model-typings Patch
@rocket.chat/apps Patch
@rocket.chat/models Patch
@rocket.chat/account-service Patch
@rocket.chat/authorization-service Patch
@rocket.chat/ddp-streamer Patch
@rocket.chat/omnichannel-transcript Patch
@rocket.chat/presence-service Patch
@rocket.chat/queue-worker Patch
@rocket.chat/stream-hub-service Patch
@rocket.chat/omnichannel-services Patch
rocketchat-services Patch
@rocket.chat/core-services Patch
@rocket.chat/cron Patch
@rocket.chat/instance-status Patch
@rocket.chat/presence Patch
@rocket.chat/network-broker Patch
@rocket.chat/core-typings Patch
@rocket.chat/rest-typings Patch
@rocket.chat/uikit-playground Patch
@rocket.chat/api-client Patch
@rocket.chat/ddp-client Patch
@rocket.chat/freeswitch Patch
@rocket.chat/fuselage-ui-kit Patch
@rocket.chat/gazzodown Patch
@rocket.chat/livechat Patch
@rocket.chat/ui-contexts Patch
@rocket.chat/license Patch
@rocket.chat/pdf-worker Patch
@rocket.chat/ui-avatar Patch
@rocket.chat/ui-client Patch
@rocket.chat/ui-video-conf Patch
@rocket.chat/ui-voip Patch
@rocket.chat/web-ui-registration Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

github-actions bot commented Dec 10, 2024

PR Preview Action v1.4.8
🚀 Deployed preview to https://RocketChat.github.io/Rocket.Chat/pr-preview/pr-34156/
on branch gh-pages at 2024-12-16 11:32 UTC

Copy link

codecov bot commented Dec 10, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 75.79%. Comparing base (b32c629) to head (3c10350).
Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff            @@
##           develop   #34156   +/-   ##
========================================
  Coverage    75.79%   75.79%           
========================================
  Files          511      511           
  Lines        22132    22132           
  Branches      5394     5394           
========================================
  Hits         16775    16775           
  Misses        4709     4709           
  Partials       648      648           
Flag Coverage Δ
unit 75.79% <100.00%> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

@matheusbsilva137 matheusbsilva137 marked this pull request as ready for review December 10, 2024 20:12
@matheusbsilva137 matheusbsilva137 requested review from a team as code owners December 10, 2024 20:12
@matheusbsilva137 matheusbsilva137 changed the title fix: First response time livechat metrics are associated to the last agent who served the room fix: First response time livechat metrics are associated with the last agent who served the room Dec 10, 2024
Copy link
Contributor

@KevLehman KevLehman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can u add unit tests cases for your fix?
if possible, similar tests to the API tests ones 👀

KevLehman
KevLehman previously approved these changes Dec 11, 2024
@jessicaschelly jessicaschelly added the stat: QA assured Means it has been tested and approved by a company insider label Dec 12, 2024
@scuciatto scuciatto added stat: QA assured Means it has been tested and approved by a company insider and removed stat: QA assured Means it has been tested and approved by a company insider labels Dec 16, 2024
@dionisio-bot dionisio-bot bot added the stat: ready to merge PR tested and approved waiting for merge label Dec 16, 2024
@kodiakhq kodiakhq bot merged commit 47f24c2 into develop Dec 16, 2024
49 checks passed
@kodiakhq kodiakhq bot deleted the fix/first-response-metrics-forward branch December 16, 2024 14:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stat: QA assured Means it has been tested and approved by a company insider stat: ready to merge PR tested and approved waiting for merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants