What is the standard (ISO 639-1, IETF BCP 47, another) used in get_language?

2016-09-23 Thread Fabio C. Barrionuevo da Luz
Hello. What is the standard (ISO 639-1, ISO 639-2, IETF BCP47, another)
used by django in get_language and to_locale functions?

I could not find in the documentation or on the source code, that explain
exact what the standard is used

https://docs.djangoproject.com/en/1.10/topics/i18n/

the closest I came to discover the standard used was:

https://github.com/django/django/blob/master/django/utils/translation/trans_real.py#L35-L36


I found this topic, but as it's been more than 10 years, I'm not sure if
anything has changed:

https://groups.google.com/d/msg/django-developers/aiIty0s5eLg/HC1HtqT_3w0J


https://www.w3.org/TR/html5/dom.html#the-lang-and-xml:lang-attributes


all this is because I'm trying to solve this problem:
https://github.com/yourlabs/django-autocomplete-light/pull/746

select2 js uses a another standard (who have not figured out what is) to
define name the language js files.

I'm trying to figure out a way to make a table of equivalence from django
language_code vs select2 language files



-- 
Fábio C. Barrionuevo da Luz
Palmas - Tocantins - Brasil - América do Sul

http://pythonclub.com.br/

Blog colaborativo sobre Python e tecnologias Relacionadas, mantido
totalmente no https://github.com/pythonclub/pythonclub.github.io .

Todos são livres para publicar. É só fazer fork, escrever sua postagem e
mandar o pull-request. Leia mais sobre como publicar em README.md e
contributing.md.
Regra básica de postagem:
"Você" acha interessante? É útil para "você"? Pode ser utilizado com Python
ou é útil para quem usa Python? Está esperando o que? Publica logo, que
estou louco para ler...

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAPVjvMZ1gO%2BOyLncprb9G%2B2S4tN528MgGVRf08ENyU1LJe63YA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


inspectdb and non "public" schema in postgresql

2014-05-19 Thread Fabio C. Barrionuevo da Luz
Hello Django core developers.
Sorry if this is not the correct place to handle this.

I have a legacy database in PostgreSQL, which is still in production.
I want to migrate it to Django.
I tried to do the reverse engineering of the database to generate models
classes

I set my settings like this:

DATABASES = {
# this read/write into "public" postgresql schema
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'neweposse',
'USER': 'neweposse_user',
'PASSWORD': 'neweposse_user',
'HOST': '127.0.0.1',
'PORT': '5432',
},
# legacy database
'eposse': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'eposse',
'USER': 'eposse_user',
'PASSWORD': 'eposse_user',
'HOST': '127.0.0.1',
'PORT': '5432',
}
}


in terminal:

(django1.7a5)sutransdev@sutransdev:~/webdocpy$ python manage.py inspectdb
...
from __future__ import unicode_literals

from django.db import models

(django1.7a5)sutransdev@sutransdev:~/webdocpy$ python manage.py inspectdb
--database=eposse
...
from __future__ import unicode_literals

from django.db import models



inspectdb not identify the tables in the database and does not generate the
model classes


The question is?

1) Am I doing something wrong. Currently there any way he could get Django
to recognize a schema different from the "public" database schema?

2) This is really a bug, and I need to create a ticket for this?

3) or Django does not currently support different database schema, but this
feature will be added when Marc Tamlyn add enhanced features to postgresql,
as described here:
https://www.kickstarter.com/projects/mjtamlyn/improved-postgresql-support-in-django?



Thanks for the hard work to maintain this great framework



-- 
Fábio C. Barrionuevo da Luz
Acadêmico de Sistemas de Informação na Faculdade Católica do Tocantins -
FACTO
Palmas - Tocantins - Brasil - América do Sul

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAPVjvMbBtYVosVxxU39PvxEmAuz5ociyPbHSecH%2Bcn777RuQKg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.