--- Begin Message ---
Package: translate-toolkit
Version: 1.7.0-0.1
Severity: important
When installed along with the python-xapian package, which is a recommended
package, the test suite for indexers fails with the following message:
debian:~# python /usr/share/pyshared/translate/search/indexing/test_indexers.py
************ running tests for 'XapianIndexer' *****************
Traceback (most recent call last):
File "/usr/share/pyshared/translate/search/indexing/test_indexers.py", line
470, in <module>
test_partial_text_matching()
File "/usr/share/pyshared/translate/search/indexing/test_indexers.py", line
143, in test_partial_text_matching
r_plain_partial1 =
new_db.get_query_result(q_plain_partial1).get_matches(0,10)
File "/usr/share/pyshared/translate/search/indexing/XapianIndexer.py", line
409, in get_matches
elem["rank"] = match[xapian.MSET_RANK]
TypeError: 'MSetItem' object does not support indexing
This makes a default installation of the web-based translation tool Pootle
unusable on squeeze: submitting a string for translation gets the PootleServer
in a infinite loop. Interrupting the server with Ctrl-C gives the following
trace :
Environment:
Request Method: POST
Request URL:
http://localhost:8080/fr/test/translate.html?match_names=check-isfuzzy%2Cuntranslated&view_mode=translate
Django Version: 1.2.3
Python Version: 2.6.6
Installed Applications:
['django.contrib.sessions',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sites',
'django.contrib.admin',
'pootle_app',
'pootle_misc',
'pootle_store',
'pootle_notifications',
'pootle_autonotices',
'registration',
'profiles',
'djblets.siteconfig',
'djblets.util']
Installed Middleware:
('pootle_misc.middleware.baseurl.BaseUrlMiddleware',
'django.middleware.transaction.TransactionMiddleware',
'pootle_misc.middleware.siteconfig.SiteConfigMiddleware',
'django.middleware.cache.UpdateCacheMiddleware',
'django.middleware.http.ConditionalGetMiddleware',
'django.middleware.gzip.GZipMiddleware',
'django.contrib.csrf.middleware.CsrfMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.middleware.locale.LocaleMiddleware',
'pootle_misc.middleware.errorpages.ErrorPagesMiddleware',
'django.middleware.common.CommonMiddleware',
'pootle.middleware.check_cookies.CheckCookieMiddleware',
'pootle.middleware.captcha.CaptchaMiddleware',
'django.middleware.cache.FetchFromCacheMiddleware')
Traceback:
File "/usr/lib/pymodules/python2.6/django/core/handlers/base.py" in get_response
100. response = callback(request, *callback_args,
**callback_kwargs)
File "/usr/lib/python2.6/dist-packages/pootle_app/views/language/view.py" in
decorated_f
56. return f(request, translation_project, *args, **kwargs)
File "/usr/lib/python2.6/dist-packages/pootle_app/views/language/view.py" in
decorated_f
66. return f(request, translation_project, *args, **kwargs)
File "/usr/lib/python2.6/dist-packages/pootle_app/views/language/view.py" in
translate_page
97. return find_and_display(request, directory, next_store_item,
prev_store_item)
File
"/usr/lib/python2.6/dist-packages/pootle_app/views/language/translate_page.py"
in find_and_display
845. store, item = get_position(request, next_store_item,
prev_store_item)
File
"/usr/lib/python2.6/dist-packages/pootle_app/views/language/translate_page.py"
in get_position
827. return process_post_main(store_name, item, request,
next_store_item, prev_store_item)
File
"/usr/lib/python2.6/dist-packages/pootle_app/views/language/translate_page.py"
in process_post_main
809. prev_item, next_item = process_post(request, store)
File
"/usr/lib/python2.6/dist-packages/pootle_app/views/language/translate_page.py"
in process_post
803. last_item = handle_submits(last_item, request, store, submits,
skips, translations, comments, fuzzies)
File
"/usr/lib/python2.6/dist-packages/pootle_app/views/language/translate_page.py"
in handle_submits
743. unit_update.update_translation(store, item, newvalues, request)
File "/usr/lib/python2.6/dist-packages/pootle_app/unit_update.py" in
update_translation
76. translation_project.update_index(translation_project.indexer, store,
[item])
File
"/usr/lib/python2.6/dist-packages/pootle_app/models/translation_project.py" in
update_index
394. indexer.delete_doc([pofilenamequery, itemsquery])
File
"/usr/lib/python2.6/dist-packages/translate/search/indexing/CommonIndexer.py"
in delete_doc
464. self._walk_matches(query, add_docid_to_list)
File
"/usr/lib/python2.6/dist-packages/translate/search/indexing/CommonIndexer.py"
in _walk_matches
491. (size, avail, matches) = enquire.get_matches(start, steps)
File
"/usr/lib/python2.6/dist-packages/translate/search/indexing/XapianIndexer.py"
in get_matches
405. matches = self.enquire.get_mset(start, number)
Exception Type: KeyboardInterrupt at /fr/test/translate.html
Exception Value:
A workaround is to uninstall the python-xapian package and leave Pootle without
an indexing engine.
-- System Information:
Debian Release: squeeze/sid
APT prefers testing
APT policy: (500, 'testing')
Architecture: i386 (i686)
Kernel: Linux 2.6.32-5-686 (SMP w/1 CPU core)
Locale: LANG=es_ES.UTF-8, LC_CTYPE=es_ES.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages translate-toolkit depends on:
ii gettext 0.18.1.1-3 GNU Internationalization utilities
ii python 2.6.6-3+squeeze1 interactive high-level object-orie
ii python-central 0.6.16+nmu1 register and build utility for Pyt
Versions of packages translate-toolkit recommends:
ii gaupol 0.17-1 subtitle editor for text-based sub
ii iso-codes 3.21-1 ISO language, territory, currency,
ii python-enchant 1.5.3-2 spellchecking library for Python
ii python-iniparse 0.3.2-1 Module to access and modify config
ii python-levenshtein 0.10.1-1.1 extension for computing string sim
ii python-lxml 2.2.8-2 pythonic binding for the libxml2 a
ii python-simplejson 2.1.1-1 simple, fast, extensible JSON enco
ii python-utidylib 0.2-6 Python wrapper for TidyLib
ii python-vobject 0.8.1c-3 parse iCalendar and VCards in Pyth
Versions of packages translate-toolkit suggests:
pn translate-toolkit-dev-doc <none> (no description available)
-- no debconf information
--- End Message ---