Open isaacs opened 7 years ago
It sounds like a bug, will need to investigate. Will post updates here.
+1
another example search term: dynamodb
returns a package with a score of 16
when:
exact-name matching receives too much boost that wipes the value in scoring
@isaacs doing what you suggest has one possible side-effect that can be exploited: users can create dummy packages, e.g.: @my-user/react
, and take advantage of this in order to just mess around with the top results for certain searches. Do you have any idea how can we get around this?
Scroll up for through twitter conversation here: https://twitter.com/izs/status/905120512879165440
If searching for
foo-bar
, a module named exactly"foo-bar"
will rank higher than"@username/foo-bar"
, even if it is lower quality. This is surprising to users who think of the bit after the/
as the "name" portion of a scoped module.Suggestion: apply exact-name boost if the bit after the
/
in the name matches the search string exactly.cc @rgrove @brianleroux