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

Exception in E2E tests with mixed field containing an object #4724

Closed
papafe opened this issue May 31, 2021 · 3 comments
Closed

Exception in E2E tests with mixed field containing an object #4724

papafe opened this issue May 31, 2021 · 3 comments
Assignees

Comments

@papafe
Copy link
Contributor

papafe commented May 31, 2021

I am working on the E2E tests using the JS SDK.
In one of the tests I am creating an object with a mixed property in mongo, adding an object as the value of mixed (as DBRef in particular) and then I am waiting for it to be synchronised back to realm. Then I am checking that the object pointed by the mixed property in realm has the same properties as the one in mongo. The problem is that the test succeeds only about half the times, and I’m getting the following exception the other half of the times:

libc++abi: terminating with uncaught exception of type realm::LogicError: Instantiating a collection object not matching column type
Exception backtrace:
0   realm.node                          0x00000001604d1c36 _ZN5realm3LstINS_6ObjKeyEEC2ERKNS_3ObjENS_6ColKeyE + 598
1   realm.node                          0x000000016053f04f _ZN5realm3Obj23assign_pk_and_backlinksERKS0_ + 1471
2   realm.node                          0x00000001605953a6 _ZN5realm5Table30create_object_with_primary_keyERKNS_5MixedEONSt3__16vectorINS_10FieldValueENS4_9allocatorIS6_EEEEPb + 1718
3   realm.node                          0x000000016039bf11 _ZN5realm4sync18InstructionApplierclERKNS0_5instr12CreateObjectE + 1345
4   realm.node                          0x000000016034d274 _ZN5realm4sync18InstructionApplier5applyIS1_EEvRT_RKNS0_9ChangesetEPNS_4util6LoggerE + 100
5   realm.node                          0x0000000160348dad _ZN5realm5_impl17ClientHistoryImpl27integrate_server_changesetsERKNS_4sync12SyncProgressEPKyPKNS2_11Transformer15RemoteChangesetEmRNS2_11VersionInfoERNS2_21ClientReplicationBase16IntegrationErrorERNS_4util6LoggerEPNSE_20SyncTransactReporterE + 1053
6   realm.node                          0x000000016035ca8d _ZN5realm5_impl14ClientImplBase7Session29initiate_integrate_changesetsEyRKNSt3__16vectorINS_4sync11Transformer15RemoteChangesetENS3_9allocatorIS7_EEEE + 173
7   realm.node                          0x000000016039620a _ZN12_GLOBAL__N_111SessionImpl29initiate_integrate_changesetsEyRKNSt3__16vectorIN5realm4sync11Transformer15RemoteChangesetENS1_9allocatorIS6_EEEE + 42
8   realm.node                          0x000000016035b57d _ZN5realm5_impl14ClientImplBase7Session24receive_download_messageERKNS_4sync12SyncProgressEyRKNSt3__16vectorINS3_11Transformer15RemoteChangesetENS7_9allocatorISA_EEEE + 589
9   realm.node                          0x000000016035850d _ZN5realm5_impl14ClientProtocol22parse_message_receivedINS0_14ClientImplBase10ConnectionEEEvRT_PKcm + 6301
10  realm.node                          0x0000000160352ce4 _ZN5realm5_impl14ClientImplBase10Connection33websocket_binary_message_receivedEPKcm + 52
11  realm.node                          0x00000001605e50df _ZN12_GLOBAL__N_19WebSocket17frame_reader_loopEv + 1503
12  realm.node                          0x0000000160360c4c _ZN5realm4util7network7Service9AsyncOper22do_recycle_and_executeINSt3__18functionIFvNS5_10error_codeEmEEEJRS7_RmEEEvbRT_DpOT0_ + 220
13  realm.node                          0x00000001603612a4 _ZN5realm4util7network7Service14BasicStreamOpsINS1_6SocketEE16BufferedReadOperINSt3__18functionIFvNS7_10error_codeEmEEEE19recycle_and_executeEv + 196
14  realm.node                          0x00000001603d9b74 _ZN5realm4util7network7Service4Impl3runEv + 484
15  realm.node                          0x000000016038c1dd _ZN5realm4sync6Client3runEv + 29
16  realm.node                          0x000000016026cd1d _ZNSt3__1L14__thread_proxyINS_5tupleIJNS_10unique_ptrINS_15__thread_structENS_14default_deleteIS3_EEEEZN5realm5_impl10SyncClientC1ENS2_INS7_4util6LoggerENS4_ISB_EEEERKNS7_16SyncClientConfigENS_10shared_ptrIKNS7_11SyncManagerEEEEUlvE0_EEEEEPvSN_ + 45
17  libsystem_pthread.dylib             0x00007fff203c1954 _pthread_start + 224
18  libsystem_pthread.dylib             0x00007fff203bd4a7 thread_start + 15

I can point to the baas fork where the code for this test resides if necessary, just ping me.

Core version

Core version: 11.0.0-beta.4
realm-js version: 10.5.0-beta.2

@papafe
Copy link
Contributor Author

papafe commented May 31, 2021

@jbreams Hey! Nikola was saying that you probably should have already the E2E tests setup done, so maybe you want to give a look? :)

@ironage
Copy link
Contributor

ironage commented Jan 31, 2022

@papafe is this still happening? I think it was most likely fixed by #4785 but want to double check before closing.

@papafe
Copy link
Contributor Author

papafe commented Feb 1, 2022

I just checked, the test now is passing, thanks!

@papafe papafe closed this as completed Feb 1, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants