Ah yes third party apps would be tricky.

An AppConfig setting would make sense, although I don't believe there's any
precedent. It could also be done by making DEFAULT_AUTOFIELD take a
dictionary mapping app labels to field names.

On Fri, 10 Apr 2020 at 08:29, Nick Pope <nickpope1...@gmail.com> wrote:

> Ah. I hadn't thought about that - only got as far as being able to define
> a new default value in DEFAULT_AUTOFIELD in the start project template so
> that existing projects are not suddenly forced to migrate.
>
> An alternative is to have something on the AppConfig. I'm sure for most
> people the large tables that may need this will be in their own, rather
> than third-party, apps. People can also choose to set this for a
> third-party app by subclassing the AppConfig, but as you say, they'd then
> be forced to handle migrations manually - is this even avoidable? I'm not
> sure how this would look for moving to a new default though.
>
> --
> 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 view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/dfb45121-8ce6-4d6b-8505-5831778e4c3f%40googlegroups.com
> .
>


-- 
Adam

-- 
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CAMyDDM2X_XJP6m2SLN8rAOrzBCcyYEEaqkcSLZaHjz3oOMXWkQ%40mail.gmail.com.
  • Add... Caio Ariede
    • ... Adam Johnson
      • ... Jure Erznožnik
        • ... Adam Johnson
          • ... Collin Anderson
            • ... Tim Graham
              • ... Nick Pope
                • ... Adam Johnson
                • ... Caio Ariede
                • ... Jure Erznožnik
                • ... Caio Ariede
                • ... אורי
                • ... Tom Forbes
                • ... 'Adam Johnson' via Django developers (Contributions to Django itself)
                • ... Florian Apolloner
                • ... 'Adam Johnson' via Django developers (Contributions to Django itself)

Reply via email to