R.12101 issues "The following files could not be checked out"
P4Connect - The following files could not be checked out:
C:\Path\to\project\Unity.sln
C:\Path\to\project\Unity-csharp.sln
-> Issue seems to be that the perforce path being requested is "//Path/to/project/Path/to/project/file-name.ext" (note duplicate "Path/to/project")
Perforce server version "p4 -Ztag info"
: ... serverVersion P4D/NTX64/2014.2/978861 (2014/12/19)
P4Connect release (look at the bottom right corner of the Perforce Configuration window)
: P4Connect 2.7 betaR.12101
Unity3d Version
: Unity 5.0.0b22 (32 bit)
Operating system version, 32bit or 64bit
: Windows 7, SP1, 64 bit.
1, No - Unity don't recommend putting the .sln under Perforce control as they're auto-generated, I think.
2, On boot up it attempts to add ProjectSettings/ProjectSettings.assets to the perforce repository, under //Path/to/project/Path/to/project/ProjectSettings/ProjectSettings.assets (mark for add). This can be seen in P4V as a new file marked for add (obviously it doesn't exist on disk, so can't be submitted).
1, Note pending changes in P4V / default changelist (should be empty)
2, Start Unity
3, Load Unity project with Perforce Integration Enabled
4, Note pending changes in P4V / default changelist - there will be an additional ProjectSettings.asset "mark for add" pending as noted above.
I haven't traced any deeper yet but I can see that the paths being sent to P5Command.Run looks correct, but on the return P4CommandResult object the TaggedObjectList contains depot specs with the mutated paths.
After a bit of research it seems like the unity project needs to be located at the root of the workspace for the system to work.
There is a "Project Root" field in the config asset (if you choose to create it) and that field seems to be redundant and is what causes trouble with the path names.
I think golonko deserves the prize. Yes, there is an old configuration field "Project Root" which isn't
used anymore, but can be found in the registry, or in an older Config.asset. The next release will
remove it entirely everywhere and should fix this issue.
I was able to create the config file by selecting the "Use Configuration Asset" checkbox in the settings dialog but I can't seem to edit any of the fields. Editing it manually in a hex editor just seems to break the config file and/or crash Unity.
Hi,
I need more information to investigate this:
Are your Unity.sln and Unity-csharp.sln files under Perforce already? Perhaps they need to be added first.
Where do you see the duplicate path issue? Can you send me the log output when this occurs, and give me reproduction steps?
Thanks!
1, No - Unity don't recommend putting the .sln under Perforce control as they're auto-generated, I think.
2, On boot up it attempts to add ProjectSettings/ProjectSettings.assets to the perforce repository, under //Path/to/project/Path/to/project/ProjectSettings/ProjectSettings.assets (mark for add). This can be seen in P4V as a new file marked for add (obviously it doesn't exist on disk, so can't be submitted).
As for repro steps, I'll try and get some to you later today (somewhat busy AM!).
Ok, to repro:
1, Note pending changes in P4V / default changelist (should be empty)
2, Start Unity
3, Load Unity project with Perforce Integration Enabled
4, Note pending changes in P4V / default changelist - there will be an additional ProjectSettings.asset "mark for add" pending as noted above.
Debug Log:
P4Connect - Adding ProjectSettings.asset
UnityEngine.Debug:Log(Object)
P4Connect.Utils:LogFile(FileAndMeta, String) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Utils.cs:260)
P4Connect.Utils:LogFiles(IList
1, String) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Utils.cs:305) P4Connect.Utils:LogFiles(IList
1, String) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Utils.cs:292)P4Connect.Operations:Add(PerforceConnection, IList
1, IList
1) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Engine.Operations.cs:233)P4Connect.FileListOperation:Run(PerforceConnection) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Engine.cs:220)
P4Connect.FileListOperations:Run(PerforceConnection) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Engine.cs:332)
P4Connect.Engine:PerformOperation(String[], String[], AssetOperation) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Engine.cs:885)
P4Connect.Engine:CreateAssets(String[]) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.Engine.cs:436)
P4Connect.AssetPostProcessor:OnPostprocessAllAssets(String[], String[], String[], String[]) (at c:/workshop/guest/perforce_software/p4connect/src/P4Connect/P4Connect/P4Connect.AssetPostProcessor.cs:27)
UnityEditor.AssetPostprocessingInternal:PostprocessAllAssets(String[], String[], String[], String[], String[])
Still occurring in Beta Release 2. In addition, any new files being added also have their paths doubled as described above.
I concur with vferguson. This is still an issue as of Beta Release 2.
I'm having trouble reproducing this issue with the doubled paths.
Could one of you email support@perforce.com with the following?
Thanks!
-Norman
I've sent an email off just now, Norman. Hope it helps. Let me know if you need any further info.
I'm having the same issue. Please let me know if you need anything from me.
I've emailed the requested details as well in the hopes of helping to track it down. Please let me know if you need anything further!
I haven't traced any deeper yet but I can see that the paths being sent to P5Command.Run looks correct, but on the return P4CommandResult object the TaggedObjectList contains depot specs with the mutated paths.
*P4Command
After a bit of research it seems like the unity project needs to be located at the root of the workspace for the system to work.
There is a "Project Root" field in the config asset (if you choose to create it) and that field seems to be redundant and is what causes trouble with the path names.
I think golonko deserves the prize. Yes, there is an old configuration field "Project Root" which isn't
used anymore, but can be found in the registry, or in an older Config.asset. The next release will
remove it entirely everywhere and should fix this issue.
How would we go about removing this locally or setting it to something useful?
I was able to create the config file by selecting the "Use Configuration Asset" checkbox in the settings dialog but I can't seem to edit any of the fields. Editing it manually in a hex editor just seems to break the config file and/or crash Unity.
I believe that this is fixed in 2.7 Beta 3