google-code-export / flies

Automatically exported from code.google.com/p/flies
GNU Lesser General Public License v2.1
2 stars 0 forks source link

python client flies publican pull doesn't work for some file format #247

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. set up configuration files for python client
2. run flies publican pull from the python client

What is the expected output?
pull po files from the server successfully

What do you see instead?
#
[INFO]Fetch the content of RPM1 from Flies server:
#
Traceback (most recent call last):
#
  File "/usr/bin/flies", line 26, in <module>
#
    client.run()
#
  File "/usr/lib/python2.6/site-packages/fliesclient/flies.py", line 935, in run
#
    self._pull_publican(command_args)
#
  File "/usr/lib/python2.6/site-packages/fliesclient/flies.py", line 720, in _pull_publican
#
    publicanutil.save_to_pofile(item, pofile, result, pot)
#
  File "/usr/lib/python2.6/site-packages/fliesclient/publicanutil.py", line 251, in save_to_pofile
#
    po.save()
#
  File "/usr/lib/python2.6/site-packages/polib.py", line 419, in save
#
    contents = getattr(self, repr_method)()
#
  File "/usr/lib/python2.6/site-packages/polib.py", line 626, in __str__
#
    return ret + _BaseFile.__str__(self)
#
  File "/usr/lib/python2.6/site-packages/polib.py", line 303, in __str__
#
    ret.append(entry.__str__(self.wrapwidth))
#
  File "/usr/lib/python2.6/site-packages/polib.py", line 995, in __str__
#
    for fpath, lineno in self.occurrences:
#
ValueError: need more than 1 value to unpack 

What version of the product are you using (displayed at the bottom of the
login page)?
flies-python-client-0.7.2-1.fc13.noarch
server side: 1.3SNAPSHOT

Please use labels and text to provide additional information.
RPM1.pot is attached.

Original issue reported on code.google.com by Helen.Ding.UQ@gmail.com on 21 Feb 2011 at 7:12

Attachments:

GoogleCodeExporter commented 9 years ago
For some old version pot file, there is references, such as '#: Acls.xml:8' in 
Acls.pot (you can find it in 
http://svn.fedorahosted.org/svn/Deployment_Guide/community/fc12/pot/). But in 
new version pot file, references seems removed. So when retrieving pot from 
server, the python client should check the references if it is empty. I have 
commit a change, tag 0.7.3, to fix this issues.  

Original comment by kent....@gmail.com on 21 Feb 2011 at 4:10