Iv'e started to work on this ticket [1] today and here [2] is my work so
far. I'd appreciate some feedback on the implementation.
There are a couple ways to handle the database type length.

1) Separate types one with a length spec and one without (as mentioned
by Ben Davis in the ticket)
2) Some interface to get the type length specs (the approach I took)

The second option more generic, and provides an interface for any type to
specify a length or scale precision.

[1] https://code.djangoproject.com/ticket/14094
[2]
https://github.com/django/django/compare/master...ar45:max_length_optional

On Thu, Jul 30, 2015 at 5:15 AM, Aymeric Augustin <
aymeric.augustin.2...@polytechnique.org> wrote:

> > Le 29 juil. 2015 à 18:25, Podrigal, Aron <ar...@guaranteedplus.com> a
> écrit :
> >
> > I see models as what defines the database ddl and and not a
> representation from a  end users perspective.
>
> Django models do a bit more than this: see the `validators` argument,
> EmailField, etc.
> > And I see the tight coupling between the 2 improper.
>
> I understand your perspective; it's a trade-off between purity and
> convenience and the optimal answer depends on each project.
> > For me I rarely use the builtin generated widgets, I use restframework
> so all I'm interested in a model is for db definition in a highly
> customizable way.
>
> Please make sure your proposals also account for the various way Django
> can be and has been used :-)
>
> --
> Aymeric.
>
> --
> 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 http://groups.google.com/group/django-developers.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/2A451482-2DDD-42CE-895B-55E1FF1026D3%40polytechnique.org
> .
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Aron Podrigal
-
'1000001', '1110010', '1101111', '1101110'   '1010000', '1101111',
'1100100', '1110010', '1101001', '1100111', '1100001', '1101100'

P: '2b', '31', '33', '34', '37', '34', '35', '38', '36', '30', '39', '39'

-- 
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 http://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CANJp-yhpwRu2iwRU5TDf3NGbvVAYEnJPorjn3tAON0CHuTPEOg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
  • Making... Podrigal, Aron
    • R... Loïc Bistuer
      • ... Tim Graham
        • ... Podrigal, Aron
          • ... Aymeric Augustin
            • ... Podrigal, Aron
    • R... Paulo Maciel
      • ... 'Tom Evans' via Django developers (Contributions to Django itself)
        • ... Christophe Pettus
          • ... Podrigal, Aron
            • ... Christophe Pettus
              • ... Podrigal, Aron
                • ... Christophe Pettus
                • ... Podrigal, Aron
                • ... Christophe Pettus
                • ... Podrigal, Aron

Reply via email to