Commit graph

63 commits

Author SHA1 Message Date
Iacopo Spalletti
a73e7edc8e Add search in msgctxt 2018-11-20 10:21:15 +01:00
Marco Bonetti
caa4806e42 PEP8 fix and version pre-bump 2018-08-24 14:21:47 +02:00
Claude Paroz
c7bbf68cf3 Removed old compatibility code for Django < 1.11 2018-08-24 10:11:14 +02:00
Marco Bonetti
9cd7fd9b27 0.9.0 release 2018-08-24 09:11:26 +02:00
Marco Bonetti
00f7e5a432 Why we can't use override_settings… 2018-08-17 16:21:44 +02:00
Marco Bonetti
dd4d653a84 Fixes #203: ROSETTA_REQUIRES_AUTH not being respected 2018-08-17 16:05:03 +02:00
Marco Bonetti
0e77a93552 Adds a test for Azure translation 2018-08-07 08:28:21 +02:00
Yavor Atov
6375cb4109 Avoid UnicodeEncodeError when quering strings
In Python 2 if you query for text with unicode symbols,
an UnicodeEncodeError is raised.
It's because urlencode is called on unicode string.
urlencode should be called on encode strings in Python 2.
The fix is to use Django's force_bytes unility function
to pass encoded string (bytestring in Python 3) to urlencode.
2018-03-01 14:12:50 +02:00
Jon Baldivieso
a701097073 Allow searching of plural strings (source & translation). Closes #186. 2018-01-10 12:03:01 -08:00
Marco Bonetti
a43d369387 Check PEP8 while running tests
Use polib >= 1.1.0
Rosetta version bump and changelog
2018-01-10 12:44:24 +01:00
Jon Baldivieso
d797b76a10 Rewrite urls to be RESTful & views to be class-based & less cache-heavy
Previously, state was extensively persisted in the cache. This
large-scale rewrite uses the cache only to persist changes to the
catalog file when it is read-only. State is now conveyed through the url
structure and through query string arguments.

The primary downside to this new approach is that there's no explicit
way of purging a cached catalog from memory, or refreshing it from
what's on disk. The user is forced (untransparently!) to wait until
the cached file falls out of the cache (untransparently!), which
is currently 24 hours after the last save (or after if the session
ends). Addressing this would require some design considerations,
and probably some new text that would require its own translation.
2018-01-09 10:45:37 -08:00
Marco Bonetti
0bd2f6e3dc Tests passing on Django 2.0a1 2017-09-23 21:16:16 +02:00
Marco Bonetti
67285f2174 use AdminSite.index_template instead of overriding the default AdminSite 2016-12-13 11:26:09 +01:00
Marco Bonetti
ba44f3bf6b Test against Django 1.10b1 and dropped support for goslate and the Google translate API 2016-06-24 12:24:29 +02:00
Neal Todd
bdaf06ef50 Remove 2dp float formatting of integer percent translated
pofile.percent_translated returns an int so the floatformat:2 filter
only ever renders as X.00, so tidier just to show X% rather than X.00%
2016-05-19 11:51:40 +01:00
Marco Bonetti
2dce7f9a77 fixes tests 2016-03-22 09:15:08 +01:00
Marco Bonetti
d1cb2455c4 Merge branch 'develop' into pr/60 2016-03-22 09:09:55 +01:00
Marco Bonetti
89660325fc updates changelog 2016-03-22 08:45:08 +01:00
Neal Todd
1e3c832eec Make MO file compilation optional, issue #155 2016-03-21 23:16:52 +00:00
Neal Todd
c20f1706cb Fix an invalid page get parameter by falling back to page 1 2016-03-21 16:20:22 +00:00
Marco Bonetti
786b67e810 adds an explicit test to detect zh_Hans (for #161) 2016-03-08 09:50:22 +01:00
Leo Zhou
5969b598d7 Fix issue #133: Support discovering locale directories like zh_Hans(xx_Xxxx) 2016-02-03 21:07:45 +08:00
Marco Bonetti
1ceea0d17b preparing for 0.7.7 release, and mock the google translate API call 2015-11-30 13:00:38 +01:00
Marco Bonetti
237c36f0d2 massive cleanup, only test against supported django versions 2015-09-24 11:20:09 +02:00
Marco Bonetti
83b65717f2 Added support for composite locales 2015-09-14 10:19:45 +02:00
Marco Bonetti
85c2eca379 adds a test for Issue #135 and PR # 136 2015-08-04 16:12:00 +02:00
Marco Bonetti
6d474d74d4 Fix for issue 113 and issue 125. Discovery of catalogs in apps defined by their AppConfig 2015-02-25 15:43:52 +01:00
Marco Bonetti
6b59b42ba1 Added support for the Free Google Translate API (PR #117, thanks @cuchac) 2015-02-18 13:32:03 +01:00
Marco Bonetti
81c94d7f95 0.7.5 2015-02-10 09:58:29 +01:00
Virgil Dupras
e4fd03f7d8 Re-introduced reflang test which was log in the previous merge
Also, fixed the reflang feature, because the tests didn't pass anymore.

references #60
2014-08-07 11:33:57 -04:00
Virgil Dupras
90432b0eeb Merge remote-tracking branch 'mbi/develop' into reflang
Conflicts:
	rosetta/conf/settings.py
	rosetta/tests/__init__.py
	rosetta/urls.py
	rosetta/views.py
2014-08-07 11:01:34 -04:00
Marco Bonetti
6c638bcc3f Removed microsofttranslator as a shipped dependency, now that Python3 support has landed upstream 2014-06-02 09:32:29 +02:00
Marco Bonetti
e963ca69f1 Added docs, tests and fine tuned ROSETTA_LANGUAGE_GROUPS setting 2014-05-02 12:04:41 +02:00
Marco Bonetti
7b84c42016 Changelog, tests and docs for ROSETTA_EXCLUDE_PATHS 2014-05-02 11:37:39 +02:00
Marco Bonetti
78224d7f7c Merged PR #44, wrote a test 2014-01-15 17:22:38 +01:00
Marco Bonetti
5304595cd7 include the translator tests 2013-12-26 14:46:07 +01:00
Marco Bonetti
a5ea8cc35e Small refactoring of tests 2013-09-18 14:38:48 +02:00
Marco Bonetti
76e8387f8c Removed support for the signed_cookies SESSION_ENGINE + SessionRosettaStorage in Django 1.6 2013-09-09 10:57:28 +02:00
Marco Bonetti
860e69a686 clear the django apps cache key prior to testing 2013-09-05 14:49:37 +02:00
Marco Bonetti
bf0b253dec Fixes issue 87, missing context variable in catalog list 2013-08-07 13:23:17 +02:00
Marco Bonetti
f891399d52 WIP tests against Django 1.6b1, some tests failing with Python3 2013-06-29 08:57:42 +02:00
Marco Bonetti
4ac54ff679 Fixes issue #81 - settings are poisoned during tests 2013-06-26 09:51:23 +02:00
Marco Bonetti
44b3314fd4 Accept languages as 'fr_FR.utf8' in lang_sel url. Fixes Issue #71 2013-04-30 14:57:16 +02:00
Virgil Dupras
2b2c5772c4 Added a testcase for the reflang feature. 2013-04-19 09:11:50 -04:00
Mathieu Comandon
5ca9eb8234 Add test for pull request #71 2013-04-16 13:57:17 +02:00
David Winterbottom
718f9430ad Allow access control function to be replaced
The current access control function `can_translate` is not always
sufficient.  For instance, some projects require access to translation
to be controlled using a permission rather than using groups.

This change introduces a new setting `ROSETTA_ACCESS_CONTROL_FUNCTION`
that allows an alternative predicate to be specified.  The default is to
use the current function so this change is backwards compatible.
2013-04-16 11:42:44 +01:00
Marco Bonetti
0e1f21e88b release 0.7.1 -- missing value in context 2013-03-01 11:33:07 +01:00
Marco Bonetti
6ac75be721 wip cleanup 2013-02-28 12:18:08 +01:00
Marco Bonetti
16d1a49515 all tests pass 2013-02-27 21:01:00 +01:00
Marco Bonetti
08569f23ce wip python 3 support 2013-02-27 18:24:53 +01:00