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] Chats holds to load history for some time #26425

Merged
merged 4 commits into from
Aug 9, 2022
Merged

[FIX] Chats holds to load history for some time #26425

merged 4 commits into from
Aug 9, 2022

Conversation

filipemarins
Copy link
Contributor

@filipemarins filipemarins commented Jul 30, 2022

Proposed changes (including videos or screenshots)

Issue(s)

Steps to test or reproduce

Further comments

Fix the conditional of wait until wrapper exists function, the querySelector returns an Element when the selector is found and null when isn't and doesn't have the property length. So the element was not being returned when it was already in the dom.

@filipemarins filipemarins changed the title [FIX] return type and conditional [FIX] Chats holds to load history for some time Jul 30, 2022
@codecov
Copy link

codecov bot commented Jul 30, 2022

Codecov Report

Merging #26425 (2cf9528) into develop (0343424) will decrease coverage by 0.02%.
The diff coverage is 100.00%.

@@             Coverage Diff             @@
##           develop   #26425      +/-   ##
===========================================
- Coverage    39.08%   39.05%   -0.03%     
===========================================
  Files          748      749       +1     
  Lines        18647    18647              
  Branches      1424     1426       +2     
===========================================
- Hits          7288     7283       -5     
- Misses       11137    11141       +4     
- Partials       222      223       +1     
Flag Coverage Δ
e2e 39.05% <100.00%> (-0.03%) ⬇️

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

Impacted Files Coverage Δ
...teor/app/ui-utils/client/lib/RoomHistoryManager.js 48.73% <ø> (-3.68%) ⬇️
.../app/ui-utils/client/lib/waitUntilWrapperExists.ts 100.00% <100.00%> (ø)
...discussion/client/createDiscussionMessageAction.ts 31.25% <0.00%> (-12.50%) ⬇️
apps/meteor/app/ui-utils/client/lib/openRoom.js 74.50% <0.00%> (-3.93%) ⬇️
apps/meteor/app/ui/client/lib/UserAction.ts 62.50% <0.00%> (-2.28%) ⬇️
apps/meteor/app/ui/client/views/app/room.js 49.59% <0.00%> (ø)
apps/meteor/client/hooks/useUpdateAvatar.ts 48.57% <0.00%> (ø)
apps/meteor/app/ui-utils/client/lib/RoomManager.js 76.57% <0.00%> (+0.57%) ⬆️
apps/meteor/app/ui-login/client/login/form.js 73.85% <0.00%> (+0.65%) ⬆️
... and 1 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@lgtm-com
Copy link

lgtm-com bot commented Aug 1, 2022

This pull request introduces 1 alert when merging b0eb2d8 into 1431f2e - view on LGTM.com

new alerts:

  • 1 for Syntax error

Copy link
Member

@ggazzo ggazzo left a comment

Choose a reason for hiding this comment

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

I think we have some issues opened related to that issue, could you mention them with 'closes'?

btw, could you create some test reproducing the steps to get stuck in this situation?

thanks

@filipemarins
Copy link
Contributor Author

filipemarins commented Aug 2, 2022

I think we have some issues opened related to that issue, could you mention them with 'closes'?

btw, could you create some test reproducing the steps to get stuck in this situation?

thanks

Already mentioned here.

I added a unit test to this method, I had to use the jsdom library inside the test to mock the MutationObserver class. The jsdom-global doesn't export the MutationObserver class.

…history

* 'develop' of github.com:RocketChat/Rocket.Chat:
  Chore: Cache playwright (#26432)
  [FIX] Empty results on `im.list` endpoint (#26438)
  [IMPROVE] Upgrade nivo and React Query (#26338)
  Chore: Upgrade Fuselage packages to next dist-tag (#26435)
  Chore: Omnichannel endpoints e2e tests (#26376)
  Chore: Refactor UserInfo to typescript (#26323)
  Chore: Rewrite Location modal to React (#26196)
  Chore: Rewrite SaveToWebdav Modal to React Component (#24365)
  [IMPROVE] validateParams to accept different validators per request method (#26357)
  Regression: Fix spacing problem on AppStatus component (#26421)
  Chore: Convert client/views/account/security folder to ts (#26413)
  i18n: Makes the text less ambiguous (#20895)
  Chore: Missing some English translation keywords (#20131)
  Chore: Exclude private/public folders from typecheck (#26399)
  [NEW] Marketplace apps page new list view layout (#26181)
  Chore: Rewrite custom OAuth Modals to react (#26204)
  i18n: Manual sync from LingoHub (#26397)
  Chore: Options in BaseRaw model could possibly be undefined (#26395)
  [IMPROVE] Use single change stream to watch DB changes (#26336)
Copy link
Member

@gabriellsh gabriellsh left a comment

Choose a reason for hiding this comment

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

LGTM! I tested the old behaviour related to the message URLs and it doesn't seem to be happening. We should keep an eye open for it though.

@gabriellsh gabriellsh requested a review from ggazzo August 2, 2022 19:54
@ggazzo ggazzo merged commit 2ebd463 into develop Aug 9, 2022
@ggazzo ggazzo deleted the fix/history branch August 9, 2022 13:53
gabriellsh added a commit that referenced this pull request Aug 9, 2022
…homepage

* 'develop' of github.com:RocketChat/Rocket.Chat:
  Chore: Bypass turbo cache on `ui-contexts` (#26526)
  Chore: Refactor WebdavFilePicker Modal to React Component (#26422)
  [FIX] Chats holds to load history for some time (#26425)
  [FIX] Decrypt E2EE messages on thread list (#26133)
  Chore: Migrate AppPermissionsReviewModal from JS to TS (#26498)
  Chore: Convert `client/views/account/preferences` folder to ts (#26496)
@casalsgh casalsgh added this to the 5.0.3 milestone Aug 9, 2022
gabriellsh added a commit that referenced this pull request Aug 9, 2022
…e/refactor-reportMessage-modal

* 'develop' of github.com:RocketChat/Rocket.Chat:
  [FIX] Don't wrap wrap up notes (#26375)
  [IMPROVE] OTR refactoring (#24757)
  [FIX] Prevent VoIP issues during disconnection when network failed (#26321)
  Chore: Bypass turbo cache on `ui-contexts` (#26526)
  Chore: Refactor WebdavFilePicker Modal to React Component (#26422)
  [FIX] Chats holds to load history for some time (#26425)
  [FIX] Decrypt E2EE messages on thread list (#26133)
  Chore: Migrate AppPermissionsReviewModal from JS to TS (#26498)
sampaiodiego pushed a commit that referenced this pull request Aug 11, 2022
Co-authored-by: gabriellsh <gabriel.henriques@rocket.chat>
@sampaiodiego sampaiodiego mentioned this pull request Aug 11, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants