Hi Alaa,

Thanks for the hints for looking in the Apache error log. I did not know 
the traceback was there.

I got past that error looking at the subroutine throwing the exception. 
As you may have guessed, that because I scp'ed the files to Pootle 
server, into the po directory but I was not aware I needed to chown 
apache, and hence Pootle couldn't open the file for writing. But I think 
you may wish to improve the error reporting on that scenario to show 
something more descriptive? I think this may be a common issue ....

Regards,
Bernard Chan.


Bernard Chan 提到:
>
> Hi Alaa,
>
> I found these in the Apache error log.
>
> [Wed Dec 30 13:32:50 2009] [error] Traceback (most recent call last):
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/django/core/handlers/base.py", line 
> 92, in get_response
> [Wed Dec 30 13:32:50 2009] [error] response = callback(request, 
> *callback_args, **callback_kwargs)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/views/language/view.py",
>  
> line 56, in decorated_f
> [Wed Dec 30 13:32:50 2009] [error] return f(request, 
> translation_project, *args, **kwargs)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/views/language/view.py",
>  
> line 66, in decorated_f
> [Wed Dec 30 13:32:50 2009] [error] return f(request, 
> translation_project, *args, **kwargs)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/views/language/view.py",
>  
> line 79, in translation_project_admin_files
> [Wed Dec 30 13:32:50 2009] [error] return tp_admin_files_view(request, 
> translation_project)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/views/admin/util.py", 
> line 48, in decorated_f
> [Wed Dec 30 13:32:50 2009] [error] return f(request, path_obj, *args, 
> **kwargs)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/views/language/admin_files.py",
>  
> line 53, in view
> [Wed Dec 30 13:32:50 2009] [error] 
> project_tree.convert_templates(template_translation_project, 
> translation_project)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/project_tree.py", 
> line 267, in convert_templates
> [Wed Dec 30 13:32:50 2009] [error] convert_template(store.file.path, 
> new_store_path)
> [Wed Dec 30 13:32:50 2009] [error] File 
> "/mnt/admin/pootle/pootle_trunk/local_apps/pootle_app/project_tree.py", 
> line 241, in convert_template
> [Wed Dec 30 13:32:50 2009] [error] output_file.close()
> [Wed Dec 30 13:32:50 2009] [error] UnboundLocalError: local variable 
> 'output_file' referenced before assignment
>
> Thanks for looking into it. By the way, is there any tools or method 
> that I can use to ascertain the syntax validity of PO/POT before 
> publishing to Pootle? I'm not sure if some of my files generated had 
> errors, or if I have carried out any "unsafe" operation.
>
> What I meant to be "half integrated" is that some of the new messages 
> appeared to have been merged to the existing POs, but it stopped 
> somewhere without finishing.
>
> Regards,
> Bernard Chan.
>
>
> Alaa Abd El Fattah 提到:
>> On Wed, 30 Dec 2009 19:41:17 +0800
>> Bernard Chan <[email protected]> wrote:
>>
>>  
>>> Hi Everybody,
>>>
>>> I had a hard time getting Pootle to work for a new set of PO/POT
>>> files integrated to an existing project. Essentially, when I tried to
>>> update from template files as admin, it gives the error.
>>>
>>>
>>>
>>>     Server Error
>>>
>>> An error has occurred. Thank you for your patience.
>>>
>>> local variable 'output_file' referenced before assignment
>>>     
>>
>> sounds like a bug, can you paste the full traceback here (you'll find it
>> in your main apache error log).
>>
>>  
>>> and the message list appeared to be half integrated.
>>>     
>>
>> what do you mean by that?
>>
>>  
>>> Any clues? Also, am I required to add "templates" to the list of 
>>> languages to be able to merge message updates from POT?
>>>     
>>
>> yes a project has to have the templates language and the POT files
>> should be added to that language in order to be able to use the update
>> from templates feature.
>>
>> cheers,
>> Alaa
>>   
>


------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Translate-pootle mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/translate-pootle

Reply via email to