Re: [Django] #16752: Multi-db without a 'default' database

2023-12-31 Thread Django
#16752: Multi-db without a 'default' database
-+-
 Reporter:  Jeremy Dunck |Owner:  Ryan
 |  Cheley
 Type:  Bug  |   Status:  assigned
Component:  Database layer   |  Version:  1.3
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Ryan Cheley):

 * owner:  nobody => Ryan Cheley
 * status:  new => assigned


Comment:

 The docs no longer have the statement mentioned in the ticket (it seems to
 be have removed in
 [https://github.com/django/django/blob/stable/1.5.x/docs/topics/db/multi-
 db.txt Django 1.5] but was in
 [https://github.com/django/django/blob/stable/1.4.x/docs/topics/db/multi-
 db.txt Django 1.4]).

 Django 1.4 was the last time this seems to have been in the docs, and
 Django 1.4 had and end to extended support in October 1, 2015

 Given that, I'm wondering if this can be marked as closed.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0e51ed6-eb2eee6f-cf6d-4359-a909-f3750ea7ea51-00%40eu-central-1.amazonses.com.


Re: [Django] #14831: Django Template Style Guide

2023-12-31 Thread Django
#14831: Django Template Style Guide
-+-
 Reporter:  Simon Meers  |Owner:  Ryan
 |  Cheley
 Type:  New feature  |   Status:  assigned
Component:  Documentation|  Version:  1.2
 Severity:  Normal   |   Resolution:
 Keywords:  template, style, | Triage Stage:  Accepted
  format |
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Ryan Cheley):

 * owner:  nobody => Ryan Cheley
 * status:  new => assigned


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0d814f5-6c63a2ea-449a-462c-b005-10206e2085a9-00%40eu-central-1.amazonses.com.


Re: [Django] #14831: Django Template Style Guide

2023-12-31 Thread Django
#14831: Django Template Style Guide
-+-
 Reporter:  Simon Meers  |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Documentation|  Version:  1.2
 Severity:  Normal   |   Resolution:
 Keywords:  template, style, | Triage Stage:  Accepted
  format |
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Ryan Cheley):

 * cc: Ryan Cheley (added)


Comment:

 It looks like there hasn't been much movement on this ticket for a while,
 and the docs located
 [https://docs.djangoproject.com/en/dev/internals/contributing/writing-code
 /coding-style/#template-style here] haven't made any changes to the
 Template Section. I'm wondering if this is actually something that is
 still needed or not?

 If it is, I'm happy to try and gather consensus on what the docs should
 recommend.

 If not, perhaps we just mark the ticket as closed?

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0d7f831-e8e32a2c-9efc-45e9-b657-e1419251bc04-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy objects inside dictionaries when saving JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 |  Walls
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Jacob Walls):

 * has_patch:  0 => 1


Comment:

 [https://github.com/django/django/pull/17668 PR]

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0d589b8-98563fbc-618f-4d51-a762-046a6f6dac68-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy objects inside dictionaries when saving JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 |  Walls
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Jacob Walls):

 I guess it would still be nice to separate this concern (resolving the
 promise) from the choice of serializer.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0bf188c-7cba7861-3f26-419e-8f2f-fc2395c8e904-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy objects inside dictionaries when saving JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 |  Walls
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Jacob Walls):

 So I have something sort of ready to go here, but then I noticed that what
 I should probably be doing is using `DjangoJSONEncoder` in the `encoder`
 arg of `JSONField`, which solves my use case. Is that enough? Should that
 be the default?

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0bab338-011f106b-fb52-4e0c-8b37-e079f08e18b4-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy objects inside dictionaries when saving JSONFields (was: Resolve lazy translation objects inside dictionaries when saving JSONFields)

2023-12-31 Thread Django
#35071: Resolve lazy objects inside dictionaries when saving JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 |  Walls
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc0a0fc56-2db5fc1b-c07c-4c0a-8f15-2be54b498fbd-00%40eu-central-1.amazonses.com.


Re: [Django] #35060: Make Model.save() arguments keyword-only

2023-12-31 Thread Django
#35060: Make Model.save() arguments keyword-only
-+-
 Reporter:  Jacob Walls  |Owner:  Salvo
 Type:   |  Polizzi
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Jacob Walls):

 * owner:  Jacob Walls => Salvo Polizzi
 * needs_better_patch:  0 => 1


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc05d36c7-a07b1493-2da9-4897-8e2d-5b2a0f3eee39-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy translation objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy translation objects inside dictionaries when saving 
JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 |  Walls
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * owner:  nobody => Jacob Walls
 * status:  new => assigned
 * version:  4.2 => dev


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc054af35-28e8abd6-eec5-4ad6-9b14-88381a116a42-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy translation objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy translation objects inside dictionaries when saving 
JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  nobody
 Type:  New feature  |   Status:  new
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * status:  closed => new
 * resolution:  wontfix =>
 * stage:  Unreviewed => Accepted


Comment:

 Tentatively accepted.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc054518c-89524fc7-a993-4a79-90e3-0f4894656a10-00%40eu-central-1.amazonses.com.


Re: [Django] #35076: improvement to the doc of ModelAdmin.view_on_site

2023-12-31 Thread Django
#35076: improvement to the doc of ModelAdmin.view_on_site
-+-
 Reporter:  redstoneleo  |Owner:  nobody
 Type:   |   Status:  closed
  Cleanup/optimization   |
Component:  Documentation|  Version:  4.2
 Severity:  Normal   |   Resolution:  invalid
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * status:  new => closed
 * resolution:   => invalid


Old description:

> Whether get_absolute_url() is defined determines the visible state of
> the “View on site” button, I suggest to change [the
> doc](https://docs.djangoproject.com/en/4.2/ref/contrib/admin/#django.contrib.admin.ModelAdmin.view_on_site)
> to the following to emphasize this(Note I have read the official doc on
> contributing to the doc, but it is hard for me to do that, so I posted my
> suggestion here ).
>

> If the object’s
> [`get_absolute_url()`](https://docs.djangoproject.com/en/4.2/ref/models/instances/#django.db.models.Model.get_absolute_url
> "django.db.models.Model.get_absolute_url")  method is defined, then  set
> `view_on_site`  to control whether or not to display the “View on site”
> link. This link should bring you to a URL where you can display the saved
> object. Otherwise, no effect.
>
> This value can be either a boolean flag or a callable. If  `True`  (the
> default), the object’s
> [`get_absolute_url()`](https://docs.djangoproject.com/en/4.2/ref/models/instances/#django.db.models.Model.get_absolute_url
> "django.db.models.Model.get_absolute_url")  method will be used to
> generate the url.

New description:

 Whether get_absolute_url() is defined determines the visible state of  the
 “View on site” button, I suggest to change
 
[https://docs.djangoproject.com/en/4.2/ref/contrib/admin/#django.contrib.admin.ModelAdmin.view_on_site
 the doc] to the following to emphasize this(Note I have read the official
 doc on contributing to the doc, but it is hard for me to do that, so I
 posted my suggestion here ).


 If the object’s
 
[https://docs.djangoproject.com/en/4.2/ref/models/instances/#django.db.models.Model.get_absolute_url
 "django.db.models.Model.get_absolute_url" get_absolute_url()]  method is
 defined, then  set `view_on_site`  to control whether or not to display
 the “View on site” link. This link should bring you to a URL where you can
 display the saved object. Otherwise, no effect.

 This value can be either a boolean flag or a callable. If  `True`  (the
 default), the object’s
 
[https://docs.djangoproject.com/en/4.2/ref/models/instances/#django.db.models.Model.get_absolute_url
 get_absolute_url()]("django.db.models.Model.get_absolute_url")  method
 will be used to generate the url.

--

Comment:

 Thanks for the ticket, however, the current wording is clear enough (IMO).

 > If `True` (the default), the object’s `get_absolute_url()` method will
 be used to generate the url.

 It clearly indicates that it won't do anything if you model doesn't have a
 `get_absolute_url()`. It's also followed by a sentence when it's
 explicitly stated:

 > **If your model has a** get_absolute_url() method but you don’t want the
 “View on site” button to appear, you only need to set view_on_site to
 False:

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc05294c3-ccb251da-7039-47ac-9e1b-9e5a49f77da2-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy translation objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy translation objects inside dictionaries when saving 
JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  nobody
 Type:  New feature  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Normal   |   Resolution:  wontfix
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Jacob Walls):

 Yeah, I hadn't yet looked into whether lazy translation objects get
 resolved when USE_I18N = False. Looks like they do, so I should remove the
 guard.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc044e672-3bc09e49-d513-486d-9c6b-4e61825fc52b-00%40eu-central-1.amazonses.com.


Re: [Django] #35060: Make Model.save() arguments keyword-only

2023-12-31 Thread Django
#35060: Make Model.save() arguments keyword-only
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 Type:   |  Walls
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Salvo Polizzi):

 * needs_better_patch:  1 => 0


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc03eb9ed-37935c7c-9849-4c97-87c2-011424f2d103-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy translation objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy translation objects inside dictionaries when saving 
JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  nobody
 Type:  New feature  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Normal   |   Resolution:  wontfix
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mariusz Felisiak):

 Why do you want to put it behind the `USE_I18N`?

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc03aa37f-7ba869ff-7e7e-4064-9ad4-ac501bfc2401-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy translation objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy translation objects inside dictionaries when saving 
JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  nobody
 Type:  New feature  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Normal   |   Resolution:  wontfix
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Jacob Walls):

 I was thinking of something like this:

 {{{#!diff
 diff --git a/django/db/models/fields/json.py
 b/django/db/models/fields/json.py
 index 7b9b2ae6b2..2df4f8ee12 100644
 --- a/django/db/models/fields/json.py
 +++ b/django/db/models/fields/json.py
 @@ -1,6 +1,8 @@
 +from collections.abc import Container
  import json

  from django import forms
 +from django.conf import settings
  from django.core import checks, exceptions
  from django.db import NotSupportedError, connections, router
  from django.db.models import expressions, lookups
 @@ -11,6 +13,7 @@ from django.db.models.lookups import (
  PostgresOperatorLookup,
  Transform,
  )
 +from django.utils.functional import Promise
  from django.utils.translation import gettext_lazy as _

  from . import Field
 @@ -96,6 +99,21 @@ class JSONField(CheckFieldDefaultMixin, Field):
  def get_internal_type(self):
  return "JSONField"

 +def get_prep_value(self, value):
 +if settings.USE_I18N:
 +match value:
 +case dict():
 +value = {
 +self.get_prep_value(k): self.get_prep_value(v)
 +for k, v in value.items()
 +}
 +case str() | Promise():
 +pass
 +case Container():
 +value = value.__class__(self.get_prep_value(v) for v
 in value)
 +
 +return super().get_prep_value(value)
 +
  def get_db_prep_value(self, value, connection, prepared=False):
  if not prepared:
  value = self.get_prep_value(value)

 }}}

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc027d6ec-7a6e4fb1-7fd2-49d2-9e22-d949d171e24c-00%40eu-central-1.amazonses.com.


[Django] #35076: improvement to the doc of ModelAdmin.view_on_site

2023-12-31 Thread Django
#35076: improvement to the doc of ModelAdmin.view_on_site
+
   Reporter:  redstoneleo   |  Owner:  nobody
   Type:  Cleanup/optimization  | Status:  new
  Component:  Documentation |Version:  4.2
   Severity:  Normal|   Keywords:
   Triage Stage:  Unreviewed|  Has patch:  0
Needs documentation:  0 |Needs tests:  0
Patch needs improvement:  0 |  Easy pickings:  0
  UI/UX:  0 |
+
 Whether get_absolute_url() is defined determines the visible state of  the
 “View on site” button, I suggest to change [the
 
doc](https://docs.djangoproject.com/en/4.2/ref/contrib/admin/#django.contrib.admin.ModelAdmin.view_on_site)
 to the following to emphasize this(Note I have read the official doc on
 contributing to the doc, but it is hard for me to do that, so I posted my
 suggestion here ).


 If the object’s
 
[`get_absolute_url()`](https://docs.djangoproject.com/en/4.2/ref/models/instances/#django.db.models.Model.get_absolute_url
 "django.db.models.Model.get_absolute_url")  method is defined, then  set
 `view_on_site`  to control whether or not to display the “View on site”
 link. This link should bring you to a URL where you can display the saved
 object. Otherwise, no effect.

 This value can be either a boolean flag or a callable. If  `True`  (the
 default), the object’s
 
[`get_absolute_url()`](https://docs.djangoproject.com/en/4.2/ref/models/instances/#django.db.models.Model.get_absolute_url
 "django.db.models.Model.get_absolute_url")  method will be used to
 generate the url.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cc00bbe88-2a6ca2aa-e0e1-4489-9ad5-976161643f00-00%40eu-central-1.amazonses.com.


Re: [Django] #31700: Highlight destructive operations in makemigrations output

2023-12-31 Thread Django
#31700: Highlight destructive operations in makemigrations output
-+---
 Reporter:  Tom Forbes   |Owner:  Amir Karimi
 Type:  New feature  |   Status:  assigned
Component:  Migrations   |  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+---
Changes (by David Wobrock):

 * cc: David Wobrock (added)


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbfab0902-b7473d12-d315-43cb-84f9-6daf4bec19d3-00%40eu-central-1.amazonses.com.


Re: [Django] #35060: Make Model.save() arguments keyword-only

2023-12-31 Thread Django
#35060: Make Model.save() arguments keyword-only
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 Type:   |  Walls
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-
Changes (by David Wobrock):

 * cc: David Wobrock (added)
 * needs_better_patch:  0 => 1


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbfaa85b8-35aa40ce-98fd-454a-a3ce-c9c1d04fedbd-00%40eu-central-1.amazonses.com.


Re: [Django] #35060: Make Model.save() arguments keyword-only

2023-12-31 Thread Django
#35060: Make Model.save() arguments keyword-only
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 Type:   |  Walls
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Salvo Polizzi):

 * has_patch:  0 => 1


Comment:

 Replying to [comment:8 Salvo Polizzi]:
 > I'm sorry but some tests do not work, so I temporarily closed PR. I will
 fix them

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbf8e08d7-13ba5dfa-9b11-4c05-9e2a-2c963ec19370-00%40eu-central-1.amazonses.com.


Re: [Django] #35060: Make Model.save() arguments keyword-only

2023-12-31 Thread Django
#35060: Make Model.save() arguments keyword-only
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 Type:   |  Walls
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Salvo Polizzi):

 * has_patch:  1 => 0


Comment:

 I'm sorry but some tests do not work, so I temporarily closed PR. I will
 fix them

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbf4f08a2-c81e3211-dc61-438e-8da3-35c2a941ac7c-00%40eu-central-1.amazonses.com.


Re: [Django] #35060: Make Model.save() arguments keyword-only

2023-12-31 Thread Django
#35060: Make Model.save() arguments keyword-only
-+-
 Reporter:  Jacob Walls  |Owner:  Jacob
 Type:   |  Walls
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Salvo Polizzi):

 * has_patch:  0 => 1


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbf45f08e-037f6c11-9050-4d6c-83c2-c11f6477b082-00%40eu-central-1.amazonses.com.


Re: [Django] #35073: New behavior of ForeignKey with on_delete=models.SET (Django 4.2 and 5.0)

2023-12-31 Thread Django
#35073: New behavior of ForeignKey with on_delete=models.SET (Django 4.2 and 
5.0)
-+-
 Reporter:  Fabio Sangiovanni|Owner:  O'ktamjon
 Type:  Uncategorized|   Status:  assigned
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by O'ktamjon):

 * owner:  nobody => O'ktamjon
 * status:  new => assigned


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbf33d003-cf595874-6272-4e7d-a0bd-f472c49191c8-00%40eu-central-1.amazonses.com.


Re: [Django] #35071: Resolve lazy translation objects inside dictionaries when saving JSONFields

2023-12-31 Thread Django
#35071: Resolve lazy translation objects inside dictionaries when saving 
JSONFields
-+-
 Reporter:  Jacob Walls  |Owner:  nobody
 Type:  New feature  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Normal   |   Resolution:  wontfix
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * status:  new => closed
 * resolution:   => wontfix


Comment:

 It's easier to resolve a type for string-based fields, however,
 `JSONField`'s values can contain different types of data. I don't think
 it's worth adding extra guess-like complexity for this. We can reconsider
 this decision if you provide a PoC.

-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbefdbc65-4bc97f95-7e77-4a14-8013-eac25e157d4c-00%40eu-central-1.amazonses.com.


Re: [Django] #35072: Model docs Field.choices inconsistency between reference and topic guide

2023-12-31 Thread Django
#35072: Model docs Field.choices inconsistency between reference and topic guide
-+-
 Reporter:  Zowie Beha   |Owner:  Zowie
 Type:   |  Beha
  Cleanup/optimization   |   Status:  assigned
Component:  Documentation|  Version:  5.0
 Severity:  Normal   |   Resolution:
 Keywords:  documentation,   | Triage Stage:  Accepted
  model, field   |
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  1|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * needs_better_patch:  0 => 1
 * stage:  Unreviewed => Accepted


-- 
Ticket URL: 
Django 
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/0107018cbef48578-ff43fca1-2362-449d-9b77-9c0c710ff273-00%40eu-central-1.amazonses.com.