Comment #5 on issue 1735 by steven...@gmail.com: Perforce clients not adding the charset
http://code.google.com/p/reviewboard/issues/detail?id=1735

Hi, I got this error in version 1.6.4.1. According to workaround, I modified perforce.py which is under ~/reviewboard/scmtools folder. Then the system show below info:
 "Please correct the error below.
    global name 'repository' is not defined"

Modified content:

  import P4
  self.p4 = P4.P4()
  self.p4.port = str(repository.mirror_path or repository.path)
  self.p4.user = str(repository.username)
  self.p4.password = str(repository.password)
  if (str(repository.encoding)):
    self.p4.charset = str(repository.encoding)
  self.p4.exception_level = 1

  cmdline = ['p4', '-p', self.p4.port]
  if self.p4.user:
    cmdline.extend(['-u', self.p4.user])
  if self.p4.password:
    cmdline.extend(['-P', self.p4.password])
  if self.p4.charset:
    cmdline.extend(['-C', self.p4.charset])
  cmdline.extend(['print', '-q', file])


--
You received this message because you are subscribed to the Google Groups 
"reviewboard-issues" group.
To post to this group, send email to reviewboard-issues@googlegroups.com.
To unsubscribe from this group, send email to 
reviewboard-issues+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/reviewboard-issues?hl=en.

Reply via email to