- Home /
Version Control Perforce: Inspector becomes editable w/o checking out
I've been trying to use the integrated Perforce integration for months, but it consistently and constantly stops working for me.
Upon starting Unity, all prefabs are checked in and are not editable unless you do a check out on them as expected. However, after between a few minutes and a few hours, some prefabs that are not checked out become editable and no version control operations can be done on the prefab as all version control right click menu items are gray.
When this happens, the version control settings indicate that I am indeed still connected to my Perforce server, and hitting the refresh button or connect button again does not fix the situation, only closing and re-opening Unity fixes it.
This is super bad if I don't realize that I have not checked out a prefab and start editing it because even after restarting Unity to fix the perforce state, it results in local changes on my disk while Unity thinks there are no changes to the prefab I edited and does not try to check it out or otherwise warn me in anyway. This could be build breaking to other team members who have only some of my changes and not others. The only thing I can do to fix my state now is to "Reconcile offline work" via perforce tools, but this can be incredibly slow for large projects and remote servers.
Help please ... I've had this issue since Unity 4.5, and I'm currently using Unity 5.1 and I've been reporting it to Unity for months and months and have gotten no response on it whatsoever.
Unity 5.1 running on Mac Pro OS X 10.10.3
Perforce Server running on Mac Mini OS X 10.10.3
Perforce Server Version: P4D/DARWIN90X86_64/2015.1/1073410 (2015/06/11)
I've also tried server version: P4D/DARWIN90X86/2014.2/962050 (2014/11/13)
Not an answer to this question, but it might be worth trying the free integration Perforce provides:
https://www.assetstore.unity3d.com/en/#!/content/25523
(disclaimer: I'm a Perforce employee)
That's a great recommendation ... and because I had this issue with the Unity Perforce integration back in 4.5, I did switch over to P4Connect and was happily using it for months. However, after upgrading to Unity 5, P4Connect now also broken in a similar but different way as it becomes disconnected and out of sync with the state of the data, forcing me to do a resolve offline once again.
P4Connect also has the issue of not respecting the type map I have setup for the server which is not a deal breaker, but is annoying and after reporting it I was told that the community is responsible for fixing anything, so it may or may not happen ... and the Unity Perforce integration doesn't have that issue.
Curses! There goes my easy answer. I put a developer on it part time, so it's definitely moving ahead, if slowly. I'll keep an eye on that type map issue.
That would be awesome. For the type map issue, I know I'm not the only one experiencing it and is easy to replicate. I have my server type map setup to make *.cs files writable in workspace all the time, but when P4Connect adds new .cs files to a changelist it they don't have the +w file type.
Type$$anonymous$$ap:
text+w //....js
text+w //....cs
Answer by jdrewsen · Jun 23, 2015 at 01:44 PM
Please see http://issuetracker.unity3d.com/issues/perforce-unity-fails-to-checkout-project-assets since it seems to be the same issue and a fix will be in an upcoming 5.1 patch release.
Your answer
Follow this Question
Related Questions
All inspector fields reverting to default values when built to executable 1 Answer
VersionControl.Provider.Checkout throws chmod error, but all code works 1 Answer
Version control tab not showing incoming changes 1 Answer
How to set up existing project for Perforce version control 0 Answers
Perforce and Unity 2 Answers