You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Today I used patch-package to patch verdaccio@5.18.0 for the project I'm working on.
The problem is in 5.x/src/api/endpoint/api/v1/search.ts (I checked and the same logical issue exists also in master 6.x branch master/packages/api/src/v1/search.ts).
Basically, search returns always total equal or less than size query param.
For example, direct search of @babel packages on npmjs (https://registry.npmjs.org/-/v1/search?text=@babel&size=20&from=0) returns total of 192 and I can do pagination by using size and from params.
Same call via verdaccio returns always total of 20 (equal to size) and pagination is not possible at all.
I applied the patch but seems not that simple, the total amount comes from npmjs but is not pass through to the verdaccio logic, the total returned is always the items from the first page + those local matches. It requires more internal changes.
Hi! 馃憢
Firstly, thanks for your work on this project! 馃檪
Today I used patch-package to patch
verdaccio@5.18.0
for the project I'm working on.The problem is in
5.x/src/api/endpoint/api/v1/search.ts
(I checked and the same logical issue exists also in master 6.x branchmaster/packages/api/src/v1/search.ts
).Basically, search returns always
total
equal or less thansize
query param.For example, direct search of
@babel
packages on npmjs (https://registry.npmjs.org/-/v1/search?text=@babel&size=20&from=0
) returns total of 192 and I can do pagination by usingsize
andfrom
params.Same call via verdaccio returns always total of 20 (equal to
size
) and pagination is not possible at all.Here is the diff that solved my problem:
This issue body was partially generated by patch-package.
The text was updated successfully, but these errors were encountered: