This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Rewrite userdir to be faster #4537
Rewrite userdir to be faster #4537
Changes from all commits
07b82a2
f993fd6
e8dd750
cf079f3
e818649
35b33d1
c123c71
1b271f2
ee98058
994243e
b845be4
487bdc0
e7e94d7
be4f84b
84a0240
060c5fb
766b86d
1b3bc5b
cf03ec7
c3b168f
bd66799
2b3f166
c6a68b4
f21dcc7
b11de34
829fb4a
2cd5abc
e224f9c
ebe8bb5
aa13be6
3c4d418
ff78918
4716266
d3e216a
75174bb
f385f75
a88c1d6
28239aa
a689842
06a93b0
fab3b33
2574889
a50de76
960b3f0
d64fbc6
7c5b66e
59334f5
42d0d3e
8110905
d0d8a6e
be857fd
8e64d86
e652138
43b71b3
6c46504
95ed0fa
385a075
1e7d2a4
eed6db8
2bf1d6a
72e74f4
1335416
c628aaa
843d287
f35b3cf
8e963dd
2847e65
ea0cc09
765c458
a8c48b5
3408e8d
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it feels like we're (still) repeating ourselves here.
Suppose there are 3 local users in the room: A, B, C.
First we call _handle_new_user with A. That will add entries: (A, A), (A, B), (A, C), (B, A), (C, A).
Then we call _handle_new_user with B. That will add entries: (B, B), (B, A), (B, C), (A, B), (C, B).
Finally we call _handle_new_user with C. That will add entries: (C, C), (C, A), (C, B), (A, C), (B, C).
So most of those entries are being added twice.
(happy if you want to say that's an existing problem, to be ignored for now, but since we're rewriting this it seems a reasonable time to consider it, or at least add a comment)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Without the adding yourself, that drops one of those, but yes, it does repeat that, but that's an existing problem.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ironically the "adding yourself" was the only entry which wasn't being redone.
Fair enough. I'd still be happier if you could add a TODO or something so that I know I'm not going mad next time I look at this code.