Perforce and utf-16

I am having issues using TeamCity's Perforce checkout, when some of my files are in utf-16 format. Here's the problem:

I have a unicode enabled Perforce server, in which are stored some utf-16 files. My p4 client is version 2007.2, which can handle this encoding.

My build agent has it's p4charset set as utf8, however according to the Perforce docs this shouldn't be applied to the utf-16 files.

If I perform a manual sync on the command line, using the -C utf8 option, the files are correctly retrieved as utf-16.

If I then get TeamCity to checkout the files (I have set the charset to be utf8 on the Version Control Settings page), they are retrieved as ANSI.

This is causing me very subtle problems, and I need to fix it!

Any help would be much appreciated!

Thanks,
Peter.

3 comments
Comment actions Permalink

Hello Peter,

  I assume you're using TC 4.0. If so, please enable perforce debugging for the log4j category
  jetbrains.buildServer.VCS.P4 . After you should be able to see the exact commands
  executed by TeamCity in TeamCity/logs/teamcity-vcs.log .

  Please send the log to me (kir$jetbrains.com) , I'll try to take a look. I'd also appreciate if
  you send be an example of incorrectly returned utf-16 file.

  Regards,
  KIR

0
Comment actions Permalink

Hi Kirill,

I'm actually using TeamCity 3.1.2. Perhaps it's worth me upgrading to version 4 to see if that makes a difference? I'll try and do that today, and then obtain the logs you asked for.

Thanks,
Peter.

0
Comment actions Permalink

Hello Peter,

   I'm afraid there will be no difference with 4.0 version (we didn't make changes in utf processing),
   but there is at least a possibility to get perforce logs. Will be awaiting for the logs and further feedback.

   Regards,
   KIR

0

Please sign in to leave a comment.