SourceTree crash - "System.IO.IOException: The file exists."

I've been using SourceTree for half a year now - it's great. I'm running Windows 8.1, had version 1.5.2.0 and had no problems with it until now.

On 21st Feb as I was minding my own gits, Source Tree failed to open. No window would pop up or anything - the application would start to open, and then close.

Restarted my machine and tried again, but it still persisted. I ran the repair tool and eventually removed it, then reinstalled it, but it still wouldn't open. I removed it again and also removed the AppData folder. SourceTree opened this time and I was able to communicate with Bitbucket and open working copies of my git repositories.

However, when I go to open up a repository (tree view), the application crashes again with the same error. This is very puzzling.

 

Here's what happens currently (version 1.6.14.0):

sourcetree bug.gif

 

The log file outputs the following each time;

2015-02-24T19:12:14: Fatal error: 
System.IO.IOException: The file exists.

2015-02-24T19:12:14: Stack trace:
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.Path.InternalGetTempFileName(Boolean checkHost)
at System.Windows.Input.Cursor.LoadFromStream(Stream cursorStream)
at System.Windows.Controls.GridViewColumnHeader.GetCursor(Int32 cursorID)
at System.Windows.Controls.GridViewColumnHeader.get_SplitCursor()
at System.Windows.Controls.GridViewColumnHeader.HookupGripperEvents()

... (Full stack trace)

 

I'm horrendous with git on command line, and don't want to have to move to another GUI. Any ideas? Thanks in advance.

1 answer

A few things to try:

1) Stop using Tree View. It's known to have some issues.

2) On the nothing to commit screen, instead of closing the repo, go to the top dropdown, and select something other than "PENDING FILES". Currently there is nothing to display because you don't have any uncommitted changes.

3) Search for bugs relating to SourceTree for Windows crashes on jira.atlassian.com. If none seem to apply, submit a new bug.

Thanks for the reply. Looks like someone posted this bug 8 hours ago on Jira - https://jira.atlassian.com/browse/SRCTREEWIN-3020. I guess I'll be watching it for a while.

Need to clean out your %temp% it has over 65535 files, and developers should avoid use of System.IO.Path.InternalGetTempFileName.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Brian Ganninger
Published Jan 23, 2018 in Sourcetree

Tip from the team: workflow and keyboard shortcuts

Supported Platforms macOS Sourcetree has a lot to offer and, like many developer tools, finding and using it all can be a challenge, especially for a new user. Everyone might not love ...

798 views 0 4
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you