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

sync multiple client functional test fails intermittently #1404

Closed
murali-shris opened this issue Sep 24, 2024 · 1 comment · Fixed by atsign-foundation/at_server#2099
Closed
Assignees
Labels
bug Something isn't working

Comments

@murali-shris
Copy link
Member

Describe the bug

https://github.com/atsign-foundation/at_client_sdk/actions/runs/11007843917
sync_multiple_client_test.dart fails intermittently with the error

  INFO|2024-09-24 05:58:05.513521|SyncSystemTest|Server commit log: {public:signing_publickey@alice🛠: [0, +], @alice🛠:signing_privatekey@alice🛠: [1, +], public:pkaminstalled@alice🛠: [3, *], shared_key.bob🛠@alice🛠: [11, *], @bob🛠:shared_key@alice🛠: [12, *], public:location.wavi@alice🛠: [15, *], public:image.wavi@alice🛠: [19, *], public:city.wavi@alice🛠: [20, *], public:foo.at_lookup_race_test@alice🛠: [21, *], public:bar.at_lookup_race_test@alice🛠: [22, *], public:baz.at_lookup_race_test@alice🛠: [23, *], public:wavi-46050236.iphone.pkam.__pkams.__public_keys@alice🛠: [25, +], public:wavi-946541363.iphone.pkam.__pkams.__public_keys@alice🛠: [28, +], public:linkedin.wavi@alice🛠: [558, *], public:testkey.wavi@alice🛠: [565, *], public:fb_username-b4806309-d9e3-42c6-95bb-28e652a8992a@alice🛠: [574, *], public:test.wavi@alice🛠: [585, *], public:phone@alice🛠: [586, *], public:email@alice🛠: [587, *], public:location@alice🛠: [588, *], public:publickey@alice🛠: [590, *], phone-484848642.wavi@alice🛠: [595, *], country-484848642.wavi@alice🛠: [596, *], city-484848642.wavi@alice🛠: [597, -], location-484848642.wavi@alice🛠: [598, *]} 
  
  INFO|2024-09-24 05:58:05.514130|SyncSystemTest|mapEntry: MapEntry(phone-484848642.wavi@alice🛠: {commitId: 595, commitOp: CommitOp.UPDATE_ALL}) 
  
  INFO|2024-09-24 05:58:05.514231|SyncSystemTest|mapEntry: MapEntry(location-484848642.wavi@alice🛠: {commitId: 598, commitOp: CommitOp.UPDATE_ALL}) 
  
  INFO|2024-09-24 05:58:05.514296|SyncSystemTest|mapEntry: MapEntry(worknumber-484848642.wavi@alice🛠: {commitId: 599, commitOp: CommitOp.UPDATE_ALL}) 
  NoSuchMethodError: The method '[]' was called on null.
  Receiver: null
  Tried calling: [](0)
  dart:core                                   Object.noSuchMethod
  test/sync_multiple_client_test.dart 424:42  assertCommitEntries
  test/sync_multiple_client_test.dart 156:24  main.<fn>
✅ test/atclient_putText_test.dart: (setUpAll)

Issue seems to be a key missing in sync response from server (worknumber-484848642.wavi in the above failure)
Issue is not replicated in local run of functional tests

Steps to reproduce

Run github actions

Expected behavior

test should pass consistently

Screenshots

No response

Smartphones

  • Device: [e.g. iPhone6]
  • OS: [e.g. iOS8.1]
  • Browser [e.g. stock browser, safari]
  • Version [e.g. 22]

Were you using an atApplication when the bug was found?

No response

Additional context

No response

@murali-shris murali-shris added the bug Something isn't working label Sep 24, 2024
@murali-shris murali-shris self-assigned this Sep 24, 2024
@murali-shris
Copy link
Member Author

Issue seems to be in metrics_impl.dart on server code
atCommitLog!.getEntries(lastCommitIdReceived, regex: regex) returns max 25 entries(default limit)
If there are commits greater than 25, then the test fails.
I have fixed the issue by paginating till we retrieve all entries
atsign-foundation/at_server@d50f8f3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
1 participant