heroiclabs / nakama-dart

Pure Dart Client for Nakama Server
https://heroiclabs.com/docs/nakama/client-libraries/dart
163 stars 50 forks source link

Both  listLeaderboardRecords and listLeaderboardRecordsAroundOwner Functions can't return full list. even if ownerIds is null #52

Closed okworld26 closed 7 months ago

okworld26 commented 1 year ago

For example:

listLeaderboardRecords function,

If ownerId parameter is set to exact user id list, It 's ok to return the correct records.

But if ownerId is null or [], or just remove this parameter, It return empty leaderboard records!

okworld26 commented 1 year ago

According to Doc :https://heroiclabs.com/docs/nakama/client-libraries/javascript/#listing-the-top-records

empty ownerIds should return FULL record list.

obrunsmann commented 1 year ago

Hey, please use the provides issue template and add the installed package version as well as the flutter doctor output to your report.

okworld26 commented 1 year ago

sorry, version is 1.0.0-dev2. Let me give more details soon

okworld26 commented 1 year ago

Describe the bug

listLeaderboardRecords function,

If ownerId parameter is set to exact user id list, It 's ok to return the correct records.

But if ownerId is null or [], or just remove this parameter, It return empty leaderboard records!

Reproduction Code final allrecords = await nakamaClient!.listLeaderboardRecordsAroundOwner( session: session!, leaderboardName: globalLeaderBoardId, ownerId: null );

    print(oldrecord);  // this is empty records!,   it should be the full record list

Expected behavior

allrecords should return the full list of leaderboard record. But it returns empty records.

output: flutter: LeaderboardRecordList(records: [], ownerRecords: [], nextCursor: , prevCursor: )

Screenshots

pubspec.yaml

[```yaml (nakama: ^1.0.0-dev.2)



**Additional context**

The leader board record has two records in fact.  But it retures empty records
okworld26 commented 1 year ago

@obrunsmann , hi. any update on this? Should I use raw http request to get the correct data as a workaround for now?

obrunsmann commented 1 year ago

@obrunsmann , hi. any update on this? Should I use raw http request to get the correct data as a workaround for now?

Currently tracking this issue with Nakama team. Coming back to you with some feedback soon :)

iammuho commented 8 months ago

No solution to that issue since 5 jan ? I'm still having the same problem