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

Assertion failed: _impl::TableFriend::is_link_type(ColumnType(type)) #1662

Closed
tspecht opened this issue Mar 18, 2015 · 7 comments
Closed

Assertion failed: _impl::TableFriend::is_link_type(ColumnType(type)) #1662

tspecht opened this issue Mar 18, 2015 · 7 comments

Comments

@tspecht
Copy link

tspecht commented Mar 18, 2015

../tightdb/impl/transact_log.hpp:741: [realm-core-0.88.5] Assertion failed: _impl::TableFriend::is_link_type(ColumnType(type))
0   MyApp                            0x006d72ad _ZN7tightdb4util9terminateEPKcS2_lbxx + 580
1   MyApp                            0x0075702f _ZN7tightdb5_impl17TransactLogParser8do_parseINS_5Group16TransactReverserEEEvRT_ + 4982
2   MyApp                            0x007557b7 _ZN7tightdb5Group16reverse_transactEmRKNS_10BinaryDataE + 182
3   MyApp                            0x0075da0f _ZN7tightdb11SharedGroup32do_rollback_and_continue_as_readEPKcS2_ + 22
4   MyApp                            0x0075286d _ZN7tightdb5_impl17WriteLogCollector26do_rollback_write_transactERNS_11SharedGroupE + 92
5   MyApp                            0x0075d987 _ZN7tightdb11SharedGroup29rollback_and_continue_as_readEv + 98
6   MyApp                            0x0065abe7 _ZN7tightdb14LangBindHelper29rollback_and_continue_as_readERNS_11SharedGroupE + 14
7   MyApp                            0x00656c3f -[RLMRealm cancelWriteTransaction] + 206
8   MyApp                            0x00618695 RLMUpdateRealmToSchemaVersion + 624
9   MyApp                            0x006546c9 +[RLMRealm realmWithPath:key:readOnly:inMemory:dynamic:schema:error:] + 2988
10  MyApp                            0x00653721 +[RLMRealm realmWithPath:readOnly:error:] + 192
11  MyApp                            0x006535c9 +[RLMRealm realmWithPath:] + 152
12  MyApp                            0x0016c65b -[DSAppDelegate application:didFinishLaunchingWithOptions:] + 8434
13  UIKit                               0x316095a7 <redacted> + 274
14  UIKit                               0x31608efb <redacted> + 1610
15  UIKit                               0x3160358b <redacted> + 714
16  UIKit                               0x3159f709 <redacted> + 3540
17  UIKit                               0x3159e871 <redacted> + 72
18  UIKit                               0x31602cc9 <redacted> + 616
19  GraphicsServices                    0x33bd4aed <redacted> + 608
20  GraphicsServices                    0x33bd46d7 <redacted> + 34
21  CoreFoundation                      0x2ed48ab7 <redacted> + 34
22  CoreFoundation                      0x2ed48a53 <redacted> + 346
23  CoreFoundation                      0x2ed47227 <redacted> + 1398
24  CoreFoundation                      0x2ecb1f0f CFRunLoopRunSpecific + 522
25  CoreFoundation                      0x2ecb1cf3 CFRunLoopRunInMode + 106
26  UIKit                               0x31601ef1 <redacted> + 760
27  UIKit                               0x315fd16d UIApplicationMain + 1136
28  MyApp                            0x0018de25 main + 116
29  libdyld.dylib                       0x399d5ab7 <redacted> + 2
IMPORTANT: if you see this error, please send this log to help@realm.io.

The error occured while executing a normal migration where a 1-m foreign key was removed.

@segiddins
Copy link
Contributor

@tspecht I just tried to reproduce this issue, and was unable to. If you could share an example project that demonstrates it, that would be immensely helpful. Thanks for sending this in!

@tspecht
Copy link
Author

tspecht commented Mar 23, 2015

@segiddins sorry but won't be able to, the issue just occurred once I'm afraid. Just posted it here because the error message said so ;)

@segiddins
Copy link
Contributor

In that case, thanks for sharing it! I'm going to close this issue, but I've opened a ticket with our Core team to investigate. Feel free to comment if you see this again.

@calmez
Copy link

calmez commented Jun 2, 2015

I just ran into this issue as well using version 0.92.1. It seems to be reproducible each time with the following scenario:
I had a RLMObject subclass removed and delete all objects of that class from the default realm. There is another RLMObject subclass that holds references to the deleted one in a RLMArray property. Of course this property is deleted during the migration (happens automatically).
From what I can see the migration seems to be aborted and then the crash happens.

@calmez
Copy link

calmez commented Jun 2, 2015

I found out that this only happens when deleting the objects either via the realm's or the migration's deleteObject:. With deleteDataForClassName: on RLMMigration from version 0.93.1 though the migrations seem to run through.

@lbanders
Copy link

I have also seen this error during migration 0.93.2.
Given I have migration for version 1, 2, 3 and introduce version 4.
I have a field, field1 in version 1 which I rename to field1mk1 in version 2.
Now, in version 4, I rename this field again to field1mk2.
Then I will get the above error when migrating from a database version 1 as field1mk1 is not part of the new datamodel.
This was NOT my expected behaviour based on your documentation on the migration block.

@jpsim
Copy link
Contributor

jpsim commented Sep 7, 2015

Hi all, we just fixed a crash due to an assertion being triggered when rolling back a transaction in which an RLMObject or RLMArray property was removed.

We believe this addresses the problem discussed here. We're aiming to ship this fix in the next major release of Realm (should be 0.96).

Thanks for your patience!

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Mar 17, 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

5 participants