# RESOLVED: Scrivener Crashing ... plea for help!



## Jane Killick (Aug 29, 2014)

Over the last week or so, I've had a problem with Scrivener crashing when I open my project in the morning. It tries to open, says Scrivener Unexpectedly Quit, hit reopen to send report. I send the report and it re-opens no problem.

This morning, it would not open at all on my MacBook Air. It crashes, I get the same message, but nothing I click will make it open. It shows me a fleeting glimpse of my WIP and then just quits.

Fortunately, when I try opening the same project on my iMac desktop machine, it also crashes but will still open. However, I feel the writing is on the wall and the whole thing will soon fail.

Note that I have all the files at present and backup is not an issue, but I would still like to continue to work in Scrivener.

What could be causing this crash and what can I do about it?

The only thing that comes up when I send a report, it claims I was doing the following:
1...
2...
(suggesting I was writing bullet points). I wasn't doing this, although last week I jotted down a few notes in list form about the plot before I dashed to work.

If anyone has any helpful suggestions as to what I should do at this point to get Scrivener working again, I'd be grateful. All my updates are up to date, including a recent iOS from Apple.

I'm now going to compile the whole project and export to Word as best back up.

Here's some computerese from the crash report if it will help computer types. There is a hell of a lot of it, so here's just the bit that looks like it might be relevant

Crashed Thread: 0 Dispatch queue: com.apple.main-thread

Exception Type: EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000002, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY

Application Specific Information:
*** Terminating app due to uncaught exception 'CALayerInvalidGeometry', reason: 'CALayer position contains NaN: [nan nan]'

Application Specific Backtrace 1:
0 CoreFoundation 0x9124bf79 __raiseError + 201
1 libobjc.A.dylib 0x9e883fd1 objc_exception_throw + 276
2 CoreFoundation 0x9124be8d +[NSException raise:format:] + 141
3 QuartzCore 0x90494920 _ZN2CA5Layer12set_positionERKNS_4Vec2IdEEb + 190
4 QuartzCore 0x9049485d -[CALayer setPosition:] + 47
5 QuartzCore 0x90497e5d -[CALayer setFrame:] + 801
6 AppKit 0x91eb8c43 __100-[_NSFullScreenTransitionOverlayWindow startEnterFullScreenAnimationWithDuration:completionHandler:]_block_invoke + 493
7 libdispatch.dylib 0x92b3b3e9 _dispatch_call_block_and_release + 15
8 libdispatch.dylib 0x92b2f763 _dispatch_client_callout + 50
9 libdispatch.dylib 0x92b43f9b _dispatch_main_queue_callback_4CF + 1672
10 CoreFoundation 0x9118392e __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 14
11 CoreFoundation 0x9113b3c7 __CFRunLoopRun + 2407
12 CoreFoundation 0x9113a7f6 CFRunLoopRunSpecific + 390
13 CoreFoundation 0x9113a65b CFRunLoopRunInMode + 123
14 HIToolbox 0x92bc52f1 RunCurrentEventLoopInMode + 267
15 HIToolbox 0x92bc50f3 ReceiveNextEventCommon + 503
16 HIToolbox 0x92bc4eec _BlockUntilNextEventMatchingListInModeWithFilter + 99
17 AppKit 0x91bf1512 _DPSNextEvent + 1053
18 AppKit 0x91ffc0b0 -[NSApplication _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 1057
19 AppKit 0x91bf0f8b -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 121
20 AppKit 0x91be612f -[NSApplication run] + 1063
21 AppKit 0x91b61025 NSApplicationMain + 1630
22 Scrivener 0x000027b5 Scrivener + 6069

Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 com.apple.CoreFoundation 0x9124c837 ___TERMINATING_DUE_TO_UNCAUGHT_EXCEPTION___ + 7
1 com.apple.CoreFoundation 0x9124c282 __raiseError + 978
2 libobjc.A.dylib 0x9e883fd1 objc_exception_throw + 276
3 com.apple.CoreFoundation 0x9124be8d +[NSException raise:format:] + 141
4 com.apple.QuartzCore 0x90494920 CA::Layer::set_position(CA::Vec2<double> const&, bool) + 190
5 com.apple.QuartzCore 0x9049485d -[CALayer setPosition:] + 47
6 com.apple.QuartzCore 0x90497e5d -[CALayer setFrame:] + 801
7 com.apple.AppKit 0x91eb8c43 __100-[_NSFullScreenTransitionOverlayWindow startEnterFullScreenAnimationWithDuration:completionHandler:]_block_invoke + 493
8 libdispatch.dylib 0x92b3b3e9 _dispatch_call_block_and_release + 15
9 libdispatch.dylib 0x92b2f763 _dispatch_client_callout + 50
10 libdispatch.dylib 0x92b43f9b _dispatch_main_queue_callback_4CF + 1672
11 com.apple.CoreFoundation 0x9118392e __CFRUNLOOP_IS_SERVICING_THE_MAIN_DISPATCH_QUEUE__ + 14
12 com.apple.CoreFoundation 0x9113b3c7 __CFRunLoopRun + 2407
13 com.apple.CoreFoundation 0x9113a7f6 CFRunLoopRunSpecific + 390
14 com.apple.CoreFoundation 0x9113a65b CFRunLoopRunInMode + 123
15 com.apple.HIToolbox 0x92bc52f1 RunCurrentEventLoopInMode + 267
16 com.apple.HIToolbox 0x92bc50f3 ReceiveNextEventCommon + 503
17 com.apple.HIToolbox 0x92bc4eec _BlockUntilNextEventMatchingListInModeWithFilter + 99
18 com.apple.AppKit 0x91bf1512 _DPSNextEvent + 1053
19 com.apple.AppKit 0x91ffc0b0 -[NSApplication _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 1057
20 com.apple.AppKit 0x91bf0f8b -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] + 121
21 com.apple.AppKit 0x91be612f -[NSApplication run] + 1063
22 com.apple.AppKit 0x91b61025 NSApplicationMain + 1630
23 com.literatureandlatte.scrivener2	0x000027b5 0x1000 + 6069

Thread 1:
0 libsystem_kernel.dylib 0x9ca1bd76 __workq_kernreturn + 10
1 libsystem_pthread.dylib 0x9adb852d _pthread_wqthread + 1289
2 libsystem_pthread.dylib 0x9adb5f72 start_wqthread + 34

etc...


----------



## Guest (Dec 22, 2015)

Not sure how it works on a Mac, but my first step would be to completely uninstall and then reinstall.  This won't affect your project files at all.

Beyond that, your best bet is to contact Literature and Latte who can probably understand the error better than most of us


----------



## Jane Killick (Aug 29, 2014)

Thanks for your quick response.


Anma Natsu said:


> Not sure how it works on a Mac, but my first step would be to completely uninstall and then reinstall. This won't affect your project files at all.


Yes, I should do that (when I figure out how). Although, as it is happening on two machines, I think it's the project, not the Scrivener software. Both copies of the software having the same issue simultaneously seems unlikely.



Anma Natsu said:


> Beyond that, your best bet is to contact Literature and Latte who can probably understand the error better than most of us


Don't think I can wait until Jan 2nd, when they are back from their Christmas break. 
EDIT: There is a support forum, however, and I have posted in there. Thanks for the suggestion.


----------



## Gone 9/21/18 (Dec 11, 2008)

I'm not a Mac person, but in Windows, the first thing I'd try is on the machine that brings the project up, if I could remember the last thing I did before the error started, delete that. If you need it, copy it out somewhere else. So for instance, if you did some list in that project just before it went south, delete the list. Then do a Save As and save the project under a new name in a new folder. Even if you can't remember the last thing you did before the error started, I'd still try that.


----------



## Mark E. Cooper (May 29, 2011)

Unlike everyone else here, the first thing I would do is find my project file and copy it to a safe location. I might try to open it and see if it self corrected. BUT please be aware that open and closing a broken file will screw up any backups. It auto backs up and only keeps the last 10. Open it too many times, and you could end up with 10 busted backups.

So copy it and rename it before opening.


----------



## Patty Jansen (Apr 5, 2011)

When you get everything working again... export to Word alternately on Dropbox and Google Drive, every night before you shut down the computer. If ever your computer or the file crashes, rename it by putting a, b, c etc after the project name.


----------



## Jane Killick (Aug 29, 2014)

Thanks for all your helpful suggestions. I have read about the over-writing thing and it's very scary, so my backups are ok. I also just backed up the whole project to Word to be doubly sure, as I could still open my project on my desktop machine.

I had a nice PM from one of the software dudes behind Scrivener and they suggested this thread:
http://www.literatureandlatte.com/forum/viewtopic.php?f=2&t=33255&start=15

The deleting preference in the library folder thing seemed to work for me. At least, I have opened Scrivener OK on my Air without crashing.


----------



## Jeff Hughes (May 4, 2012)

Glad you seem to have a resolution in hand, Jane.  Trashing an app's preferences (which are then automatically rebuilt when you next start the app) is a frequent fix when things go awry on OS X.

Based on the thread you linked, I'm assuming you're running El Capitan?  Did you recently upgrade?

You mention using two Macs.  Be very careful that only one has Scrivener open at any given time.  Simultaneously opening the same project on a second machine - usually done inadvertently - is a quick way to corrupt the project file.  It's an issue I'm very cautious with, since I use three different Macs at times.

Good luck!


----------



## Jane Killick (Aug 29, 2014)

Jeff Hughes said:


> Based on the thread you linked, I'm assuming you're running El Capitan? Did you recently upgrade?


There was an update to the OS last week. I don't actually know what it is, but I ran the updates.



Jeff Hughes said:


> You mention using two Macs. Be very careful that only one has Scrivener open at any given time. Simultaneously opening the same project on a second machine - usually done inadvertently - is a quick way to corrupt the project file.


I don't think I did, but who knows? I have Scrivener set to backup to Dropbox where several other backups are kept (five I think). When I close it, it zips up to dropbox. When I go onto the other machine, I unzip the Dropbox file, put the Scrivener file into the place where it lives on the machine's local drive, overwriting the older version. Then I open that. So having two versions of Scrivener open shouldn't be a problem (I think there is another way of sharing files between two machines, but I ended up using this slightly more fiddly version which I think works better). As far as I know, the only problem I have had doing it that way is not using the most recent back up. But that is easily fixed by looking for the right backup!

Yes, getting rid of those library preference files has fixed it on both machines. This is obviously a good tip for the future.


----------



## Jeff Hughes (May 4, 2012)

It sounds like you are running your Scrivener project file off the hard disks in your local machines, with your backups going to Dropbox.  That's the opposite of the way I do it.  The benefit of your method is that it pretty much obviates the issue of having the the project file corrupted by being opened simultaneously on multiple machines.  The disadvantage is that you have to find the latest/correct project file each time you change machines (and, actually, that's not precisely correct, since you're using your backup files each time, not the native project file).

Just to be clear, it's the backup files that get zipped.  The project file does not.

I'm not going to try and talk you into changing your method, since it seems to work for you.  But you might consider using a thumb drive to move your project file back and forth between machines, rather than trying to find the latest backup and unzipping that.  The backups work, obviously, but it's an unusual way of using them.

Also, OS updates happen regardless of which version you're on.  You might want to click on the Apple-->About_this_Mac and verify what you're running, so you can advise support folks if nothing else.


----------



## CASD57 (May 3, 2014)

I was having the same problem and I did everything to fix it...I also was saving and backing in one drive.. I stopped that but I think what the problem really was that I was running two anti-virus programs and the new one was Baidu so I turned that off and everything has been good for a month.. 
All this was talked about at Scriveners Forum...
I haven't tried putting everything back into OneDrive but if you think about it...With the sync'ing it could of been the cause..


----------



## NoLongerPosting (Apr 5, 2014)

Removed due to site owner's change of TOS.


----------



## Speaker-To-Animals (Feb 21, 2012)

> I don't think I did, but who knows? I have Scrivener set to backup to Dropbox where several other backups are kept (five I think). When I close it, it zips up to dropbox. When I go onto the other machine, I unzip the Dropbox file, put the Scrivener file into the place where it lives on the machine's local drive, overwriting the older version. Then I open that. So having two versions of Scrivener open shouldn't be a problem (I think there is another way of sharing files between two machines, but I ended up using this slightly more fiddly version which I think works better). As far as I know, the only problem I have had doing it that way is not using the most recent back up. But that is easily fixed by looking for the right backup!


That's a lot of work. Just create a WIP folder in dropbox and run the project there.


----------



## Jeff Hughes (May 4, 2012)

Speaker-To-Animals said:


> That's a lot of work. Just create a WIP folder in dropbox and run the project there.


Exactly. But then move backups so they go to your local drive.


----------



## Jane Killick (Aug 29, 2014)

Speaker-To-Animals said:


> That's a lot of work. Just create a WIP folder in dropbox and run the project there.


Goodness, no! It has to be saved locally. You're at the mercy of the internet if you do that.

Above suggestion that I use a memory stick is a good one, but this never happens because I forget / run out of time to put on a stick at the end of my writing session and next day I start a new session and it's a faff to go to the other machine and copy the file onto the stick, then copy again onto other machine.


----------



## Speaker-To-Animals (Feb 21, 2012)

> Goodness, no! It has to be saved locally. You're at the mercy of the internet if you do that.


Using dropbox, the file resides on your hard drive, dropbox then copies that file to the cloud each and every time you change it, and then copies it down to every other device on the account. So it's not "file is in cloud" it's "file is on my laptop, on my partner's laptop, on our shared desktop, on my desktop at work, and in the cloud."

Also note that if you don't have a connection to the net at any given time, you can still work on the local file and the next time you hit internet, it will sync behind the scenes. That's the glory of Dropbox, Google Drive, OneDrive, etc.--they are automatic. You don't need to worry about remembering to back something up. It just happens.

And Scrivener also does automatic backups. Every time you close out of a file, it backs the whole thing into a zip file and stores the last five versions of those in a separate spot.


----------



## 75845 (Jan 1, 1970)

Speaker-To-Animals said:


> Also note that if you don't have a connection to the net at any given time, you can still work on the local file and the next time you hit internet, it will sync behind the scenes. That's the glory of Dropbox, Google Drive, OneDrive, etc.--they are automatic. You don't need to worry about remembering to back something up. It just happens.


This is a primary cause of Scrivener file corruption.

1. edit Dropbox Wip on desktop.
2. close desktop and take laptop to cafe making sure to open it before leaving house so it updates WiP from DropBox.
3. cafe wi-fi does not work edit away as its the current version you are working on.
4. get in and fire up desktop without logging in on laptop.
5. edit version ignoring cafe work.
6. need to sort out backups.

OneDrive would save your cafe work as WiP.laptop just as well it doesn't save different versions. Jutoh has an option to save the file in a temporary folder when using Dropbox to prevent corruption. Maybe Scrivener has a similar option.


----------



## Guest (Dec 26, 2015)

I've done something similar before and DropBox does save both versions, one with .conflicted on it.  The problem is that, of course, Scrivener doesn't see those and you have to notice it fairly quickly because Scrivener starts writing stuff almost immediately on open.


----------



## Speaker-To-Animals (Feb 21, 2012)

I could swear I got a notice that DB was downloading an older version of the file the one time I didn't let the laptop sync.


----------

