{"action":"created","issue":{"url":"https://api.github.com/repos/residentsummer/watoi/issues/8","repository_url":"https://api.github.com/repos/residentsummer/watoi","labels_url":"https://api.github.com/repos/residentsummer/watoi/issues/8/labels{/name}","comments_url":"https://api.github.com/repos/residentsummer/watoi/issues/8/comments","events_url":"https://api.github.com/repos/residentsummer/watoi/issues/8/events","html_url":"https://github.com/residentsummer/watoi/issues/8","id":300833884,"number":8,"title":"Can you help with this issue?","user":{"login":"lucasazevedonet","id":2625934,"avatar_url":"https://avatars2.githubusercontent.com/u/2625934?v=4","gravatar_id":"","url":"https://api.github.com/users/lucasazevedonet","html_url":"https://github.com/lucasazevedonet","followers_url":"https://api.github.com/users/lucasazevedonet/followers","following_url":"https://api.github.com/users/lucasazevedonet/following{/other_user}","gists_url":"https://api.github.com/users/lucasazevedonet/gists{/gist_id}","starred_url":"https://api.github.com/users/lucasazevedonet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lucasazevedonet/subscriptions","organizations_url":"https://api.github.com/users/lucasazevedonet/orgs","repos_url":"https://api.github.com/users/lucasazevedonet/repos","events_url":"https://api.github.com/users/lucasazevedonet/events{/privacy}","received_events_url":"https://api.github.com/users/lucasazevedonet/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2018-02-27T23:30:52Z","updated_at":"2018-03-25T10:02:43Z","closed_at":null,"author_association":"NONE","body":"2018-02-27 20:30:00.463 watoi[40149:5054170] Android store loaded\r\nCoreData: error: Attempt to add read-only file at path ChatStorage.sqlite -- file:///Users/lucasazevedo/Dev/_projects/whatsss/ read/write. Adding it read-only instead. This will be a hard error in the future; you must specify the NSReadOnlyPersistentStoreOption.\r\n2018-02-27 20:30:00.472 watoi[40149:5054170] CoreData loaded\r\nCoreData: warning: Unable to load class named 'WAChatSession' for entity 'WAChatSession'.  Class not found, using default NSManagedObject instead.\r\n2018-02-27 20:30:00.478 watoi[40149:5054170] 553194711004-1425855518@g.us: not found\r\nCoreData: warning: Unable to load class named 'WAGroupInfo' for entity 'WAGroupInfo'.  Class not found, using default NSManagedObject instead.\r\n2018-02-27 20:30:00.480 watoi[40149:5054170] \t is group chat\r\n2018-02-27 20:30:00.480 watoi[40149:5054170] \t not found member (null)\r\nCoreData: warning: Unable to load class named 'WAGroupMember' for entity 'WAGroupMember'.  Class not found, using default NSManagedObject instead.\r\n2018-02-27 20:30:00.481 watoi[40149:5054170] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[__NSDictionaryM setObject:forKey:]: key cannot be nil'\r\n*** First throw call stack:\r\n(\r\n\t0   CoreFoundation                      0x00007fff428f60fb __exceptionPreprocess + 171\r\n\t1   libobjc.A.dylib                     0x00007fff691eac76 objc_exception_throw + 48\r\n\t2   CoreFoundation                      0x00007fff429375b4 _CFThrowFormattedException + 202\r\n\t3   CoreFoundation                      0x00007fff427f943a -[__NSDictionaryM setObject:forKey:] + 986\r\n\t4   watoi                               0x000000010b96ec6c -[Importer addMissingMember:toChat:asAdmin:] + 614\r\n\t5   watoi                               0x000000010b96f57f -[Importer importChats] + 2267\r\n\t6   watoi                               0x000000010b96df41 -[Importer import] + 27\r\n\t7   watoi                               0x000000010b96db86 main + 354\r\n\t8   libdyld.dylib                       0x00007fff69dd9145 start + 1\r\n\t9   ???                                 0x0000000000000004 0x0 + 4\r\n)\r\nlibc++abi.dylib: terminating with uncaught exception of type NSException\r\n[1]    40149 abort      build/Release/watoi /Users/lucasazevedo/Dev/_projects/msgstore.db"},"comment":{"url":"https://api.github.com/repos/residentsummer/watoi/issues/comments/375958658","html_url":"https://github.com/residentsummer/watoi/issues/8#issuecomment-375958658","issue_url":"https://api.github.com/repos/residentsummer/watoi/issues/8","id":375958658,"user":{"login":"residentsummer","id":813112,"avatar_url":"https://avatars2.githubusercontent.com/u/813112?v=4","gravatar_id":"","url":"https://api.github.com/users/residentsummer","html_url":"https://github.com/residentsummer","followers_url":"https://api.github.com/users/residentsummer/followers","following_url":"https://api.github.com/users/residentsummer/following{/other_user}","gists_url":"https://api.github.com/users/residentsummer/gists{/gist_id}","starred_url":"https://api.github.com/users/residentsummer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/residentsummer/subscriptions","organizations_url":"https://api.github.com/users/residentsummer/orgs","repos_url":"https://api.github.com/users/residentsummer/repos","events_url":"https://api.github.com/users/residentsummer/events{/privacy}","received_events_url":"https://api.github.com/users/residentsummer/received_events","type":"User","site_admin":false},"created_at":"2018-03-25T10:02:43Z","updated_at":"2018-03-25T10:02:43Z","author_association":"OWNER","body":"As it turns out, changes in Android DB ain't the cause of this (`group_participants.jid` field is still not nullable). The reason is that watoi somehow can't determine the JID of the DB owner (our JID, in other words), but I'm not sure why...\r\n\r\nI haven't found a place where this info is stored neither in Android backup, nor in iOS, so I guess it by walking all the chats in iOS backup to count the number of rooms each JID is participating in. The one with the most groups should be ours. It was a fragile method and now it's failed to do its job.\r\n\r\nAfter taking a closer look at the import log, this line seemed suspicious:\r\n```\r\nCoreData: error: Attempt to add read-only file at path ChatStorage.sqlite -- file:///Users/lucasazevedo/Dev/_projects/whatsss/ read/write. Adding it read-only instead. This will be a hard error in the future; you must specify the NSReadOnlyPersistentStoreOption.\r\n```\r\nIt may not be the cause of current error, but if interpret the message correctly, it could mean that changes that we've made to iOS db won't be saved.\r\n\r\nAnd than this lines:\r\n```\r\n2018-02-27 20:30:00.478 watoi[40149:5054170] 553194711004-1425855518@g.us: not found\r\n2018-02-27 20:30:00.480 watoi[40149:5054170] is group chat\r\n```\r\nIt seemed strange that group chat was not found in iOS backup. While sometimes it's a valid situation (e.g. rooms that you no longer member of), it led me to the hypothesis that iOS backup db wasn't in the proper state. If no group chats were present in the ChatStorage.sqlite, that would explain `null` JID and the mentioned log line.\r\n\r\n@lucasazevedonet, @suhailsheikh7, @Tharkhun did you do the first step of the migration process?\r\n> Check that Whatsapp is activated on iDevice. You should see the list of group chats when you open the app. Most likely, there won't be any messages prior to moving to iOS. You can even send/receive a message or two to be sure that there is something to back up."}}
{"actor":{"display_login":"residentsummer"}}