Friday, September 26, 2014

Discovered and opened docs/tickets/128.

While looking at this problem, I saw that simply adding a models.py module for lino with those choiceliss would not be enough because Django’s loading.get_apps method does not return it when there is no model in it. Installed apps without models, but with choicelists, did not get their entry in rt.models. Until today. That’s clearly odd. I changed that immediately (in rt.startup()) by replacing:

for a in loading.get_apps():
    self.modules.define(a.__name__.split('.')[-2], a)

with:

for p in self.installed_plugins:
    m = loading.load_app(p.app_name, False)
    self.modules.define(p.app_label, m)

I discovered why certain strings in Renamed “Lino Faggio” to “Lino Voga” were not yet translated: because I had switched lino.core.site.Site.languages of lino_faggio.projects.docs to monolingual English. If you do that (have the demo database onl in English) but still support multiple languages, then you must set env.languages in your project’s fabfile.py.

A test case failed (lino.projects.min1.tests) due to the recent changes in ml.countries.EstonianAddressFormatter.