Perforce Plugin (0.3 & 0.4) error, plugin doesn't recognize files are in Perforce

I have a Perforce server setup at home, along with a repository. From a Win2K box I can use the Perforce plugin just fine. From a WinXP box it consistently gives me the error that the files are not in Perforce. I have tried multiple version of IDEA and multiple version of the Perforce plugin and I still get this error. I can enable Perforce support through external tools and it works fine, but I lose the VCS integration which has some nice features.

I finally broke down and started trying to figure out the source of this error. Essentially P4Package is saying that one of the depot path or the client path are not set. The error is from FileEntry.java, line 618:

if( getClientPath() == null || getDepotPath() == null ) {
throw new PerforceException("Cann't edit a file if its not in perforce already....");
}

Before I spend more time tracking down why these variables aren't being set properly, has anyone seen this. If so, can you provide any pointers to get me going?

James

3 comments

Ok, did some digging and discovered a critical system dependency in the Perforce constructor, which loads p4.properties from the user's home directory and includes the following default:

setSystemRoot(getProperty("p4.sysroot", "C:
WINNT"));

Despite trying to override this in my p4.properties file I was unable to (I even wrote a test program to convince myself it was loading correctly into a Properties object). So rather than mess with it more, I simply built my own copy of the plugin that references the correct directory under XP. Lo and behold, it works now. :)

James

0

Oh, and it's worth noting that there's no documentation that I found on the need for a p4.properties file, most especially setting things like the path separator, file separator, system drive, and system directory -- all of which aren't accessible via the configuration dialog from within IDEA. Combine that with the fact that I couldn't make it load my p4.properties once I knew it needed to be there and I think there's some room for improvement here. :)

James

p.s. posting from my Wiki account, this is the same person who posted above.

0

Thanks for reporting the bug and the solution too :) . The p4.properties is
required by P4Package tool that I use. Will fix it pretty soon.

-Dash.

"James Waldrop" <sulam@well.com> wrote in message
news:28050534.1050050296013.JavaMail.jrun@is.intellij.net...

Oh, and it's worth noting that there's no documentation that I found on

the need for a p4.properties file, most especially setting things like the
path separator, file separator, system drive, and system directory -- all of
which aren't accessible via the configuration dialog from within IDEA.
Combine that with the fact that I couldn't make it load my p4.properties
once I knew it needed to be there and I think there's some room for
improvement here. :)
>

James

>

p.s. posting from my Wiki account, this is the same person who posted

above.
>


0

Please sign in to leave a comment.