Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  Mohit
 |  Singh Sinsniwal
 Type:  Bug  |   Status:  assigned
Component:   |  Version:  4.2
  Internationalization   |
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Accepted
  internationalization, i18n,|
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * has_patch:  1 => 0


Comment:

 > I want to work on this bug, I think the real problem is in getting the
 language from request. Sending the pull request.

 I don't think think there is an issue. I'd rather suspect
 
[https://github.com/django/django/commit/94e7f471c4edef845a4fe5e3160132997b4cca81
 #diff-00c54c9d11cedfd1135887f3e06ab78d49496812eb5aa2e77b76eba9976c5997R60
 this line].

-- 
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/010701874ff645b4-8ed95a8a-6098-4a44-957a-d3d88b2aea1b-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  Mohit
 |  Singh Sinsniwal
 Type:  Bug  |   Status:  assigned
Component:   |  Version:  4.2
  Internationalization   |
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Accepted
  internationalization, i18n,|
  prefix_default_language|
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mohit Singh Sinsniwal):

 * 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/010701874fd338a3-599ce9d0-d913-4923-af8e-15d4d149f2d2-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  Mohit
 |  Singh Sinsniwal
 Type:  Bug  |   Status:  assigned
Component:   |  Version:  4.2
  Internationalization   |
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Accepted
  internationalization, i18n,|
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mohit Singh Sinsniwal):

 I have created a pull request. Can you please review it?
 https://github.com/django/django/pull/16727


 Replying to [comment:6 Mariusz Felisiak]:
 > Oussama, thanks!
 >
 > Regression in 94e7f471c4edef845a4fe5e3160132997b4cca81.
 > Reproduced at 0e1aae7a5f51408b73c5a29e18bd1803dd030930.

-- 
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/010701874fc66efa-d26b6e44-ba70-4acb-ac99-cf9f65151c39-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  Mohit
 |  Singh Sinsniwal
 Type:  Bug  |   Status:  assigned
Component:   |  Version:  4.2
  Internationalization   |
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Accepted
  internationalization, i18n,|
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mohit Singh Sinsniwal):

 * owner:  nobody => Mohit Singh Sinsniwal
 * status:  new => assigned


Comment:

 I want to work on this bug, I think the real problem is in getting the
 language from request. Sending the pull request.

-- 
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/010701874fa46174-53c6df6e-22dc-4daf-9228-e14adca8a458-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object 
has no
attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  Simon
 |  Charette
 Type:  Bug  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"647920b76694526c6be0375ff22e4d6ee43c9580" 647920b]:
 {{{
 #!CommitTicketReference repository=""
 revision="647920b76694526c6be0375ff22e4d6ee43c9580"
 [4.2.x] Fixed #34458 -- Fixed QuerySet.defer() crash on attribute names.

 Thanks Andrew Cordery for the report.

 Regression in b3db6c8dcb5145f7d45eff517bcd96460475c879.

 Backport of 87c63bd8df0eb0109df333df1264c6a96707d6a4 from main
 }}}

-- 
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/010701874f98b4da-2f64f90f-9be1-44c6-a054-fbf35c926d23-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object 
has no
attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  Simon
 |  Charette
 Type:  Bug  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Release blocker  |   Resolution:  fixed
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak ):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"87c63bd8df0eb0109df333df1264c6a96707d6a4" 87c63bd]:
 {{{
 #!CommitTicketReference repository=""
 revision="87c63bd8df0eb0109df333df1264c6a96707d6a4"
 Fixed #34458 -- Fixed QuerySet.defer() crash on attribute names.

 Thanks Andrew Cordery for the report.

 Regression in b3db6c8dcb5145f7d45eff517bcd96460475c879.
 }}}

-- 
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/010701874f97b482-bd0a78e7-c4f2-44da-8e76-49cb59bf3b84-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object 
has no
attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  Simon
 |  Charette
 Type:  Bug  |   Status:  assigned
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Ready for
 |  checkin
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * stage:  Accepted => Ready for checkin


-- 
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/010701874f807d2a-1c864c7c-5987-4739-86f2-78384bde93b8-00%40eu-central-1.amazonses.com.


Re: [Django] #34459: SearchVector() can return query strings that are unsafe to combine.

2023-04-04 Thread Django
#34459: SearchVector() can return query strings that are unsafe to combine.
--+
 Reporter:  Patryk Zawadzki   |Owner:  (none)
 Type:  Bug   |   Status:  new
Component:  contrib.postgres  |  Version:  4.2
 Severity:  Release blocker   |   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 Simon Charette):

 * cc: Simon Charette (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/010701874f2d809b-5ea16bbc-73aa-4960-81e8-40bc3d85547e-00%40eu-central-1.amazonses.com.


Re: [Django] #21080: collectstatic post-processing fails for references inside comments

2023-04-04 Thread Django
#21080: collectstatic post-processing fails for references inside comments
-+-
 Reporter:  shreyas@…|Owner:  Tomáš
 |  Zigo
 Type:  Bug  |   Status:  assigned
Component:  contrib.staticfiles  |  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:   | Triage Stage:  Accepted
Has patch:  1|  Needs documentation:  0
  Needs tests:  1|  Patch needs improvement:  1
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Jake Bell):

 I'd also like to note that this bug also errors out when processing the
 CSS from Bootstrap 5, as it gets hung up on the SVG data URIs:

 {{{
 ValueError: The file '\"data:image/svg+xml,.
 }}}

 This seems like a pretty significant issue to me, given the popularity of
 Bootstrap. Simply parsing out the comments wouldn't be enough to fix the
 above issue. It seems like what is needed is either a proper CSS parser
 (like in the linked thread about JS files--perhaps
 [https://tinycss.readthedocs.io/]?) or a better regex that can exclude
 `url(data:)` items.

-- 
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/010701874ec3245f-bc9a0421-73f6-4af5-bb4d-3f288ffe105f-00%40eu-central-1.amazonses.com.


Re: [Django] #34459: SearchVector() can return query strings that are unsafe to combine.

2023-04-04 Thread Django
#34459: SearchVector() can return query strings that are unsafe to combine.
--+
 Reporter:  Patryk Zawadzki   |Owner:  (none)
 Type:  Bug   |   Status:  new
Component:  contrib.postgres  |  Version:  4.2
 Severity:  Release blocker   |   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 Patryk Zawadzki):

 David, I’m not sure if it’s “supported” or not, but my project uses
 SearchVector with expressions such as Value instead of column names so I
 see a lot of percent signs passed as the corpus of text, not the config or
 weight. We calculate some of the values we index in Python code and
 combine strings with different weights.

-- 
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/010701874e6e9225-ab59dc1e-fae4-4c56-ba7a-4adbc562de96-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object 
has no
attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  Simon
 |  Charette
 Type:  Bug  |   Status:  assigned
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Release blocker  |   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 Simon Charette):

 * 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/010701874e130397-284b6733-9491-42b8-aa88-a3c8e47d8d1c-00%40eu-central-1.amazonses.com.


Re: [Django] #34459: SearchVector() can return query strings that are unsafe to combine. (was: contrib.postgres.search.SearchVector.as_sql can return query strings that are unsafe to combine)

2023-04-04 Thread Django
#34459: SearchVector() can return query strings that are unsafe to combine.
--+
 Reporter:  Patryk Zawadzki   |Owner:  (none)
 Type:  Bug   |   Status:  new
Component:  contrib.postgres  |  Version:  4.2
 Severity:  Release blocker   |   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):

 * cc: Florian Apolloner, Daniele Varrazzo (added)
 * severity:  Normal => Release blocker


Comment:

 Regression in 09ffc5c1212d4ced58b708cbbf3dfbfb77b782ca.

-- 
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/010701874d66e551-143e49a3-ad16-4a3b-af20-e2c0d0ac274e-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object 
has no
attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  Simon
 |  Charette
 Type:  Bug  |   Status:  assigned
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Release blocker  |   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 Simon Charette):

 * owner:  nobody => Simon Charette
 * 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/010701874d553b46-30429e21-865d-46d6-a7fa-2562be9c1eb7-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object has no attribute 'field' (was: Calling defer('user_id') instead of defer('user') will raise AttributeError: 'F

2023-04-04 Thread Django
#34458: QuerySet.defer('user_id') raises AttributeError: 'ForeignKey' object 
has no
attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 Severity:  Release blocker  |   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):

 * cc: Simon Charette (added)
 * severity:  Normal => Release blocker


Comment:

 Regression in b3db6c8dcb5145f7d45eff517bcd96460475c879.

-- 
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/010701874d545280-ebe40392-7aea-4431-85c8-2f4608ff9902-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:   |  Version:  4.2
  Internationalization   |
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:  Accepted
  internationalization, i18n,|
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * cc: Claude Paroz (added)
 * component:  Core (URLs) => Internationalization
 * stage:  Unreviewed => Accepted


Comment:

 Oussama, thanks!

 Regression in 94e7f471c4edef845a4fe5e3160132997b4cca81.
 Reproduced at 0e1aae7a5f51408b73c5a29e18bd1803dd030930.

-- 
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/010701874d4cd5e1-5792e5a8-f654-4fb3-86b7-4df5986fee99-00%40eu-central-1.amazonses.com.


Re: [Django] #34458: Calling defer('user_id') instead of defer('user') will raise AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: Calling defer('user_id') instead of defer('user') will raise
AttributeError: 'ForeignKey' object has no attribute 'field'
-+-
 Reporter:  Andrew Cordery   |Owner:  nobody
 Type:  Bug  |   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 David Sanders):

 * stage:  Unreviewed => Accepted


Comment:

 Thanks for the report 

 It's at least inconsistent with the behaviour of `only()` which does allow
 the column name.

-- 
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/010701874d395c5b-4509a39d-3dd9-4484-898e-daed61883fe0-00%40eu-central-1.amazonses.com.


Re: [Django] #34456: Add a way to set allow_cascade=True in _fixture_teardown()

2023-04-04 Thread Django
#34456: Add a way to set allow_cascade=True in _fixture_teardown()
---+--
 Reporter:  Howard Cox |Owner:  nobody
 Type:  Uncategorized  |   Status:  closed
Component:  Testing framework  |  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
---+--

Comment (by Howard Cox):

 That's fair, it's been abandoned anyway so we're considering forking it,
 so can just change it.

-- 
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/010701874d32c6a0-89d32063-7714-4797-9956-896947ba6aab-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Core (URLs)  |  Version:  4.2
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:
  internationalization, i18n,|  Unreviewed
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Oussama Jarrousse):

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


Comment:

 I prepared a simple (pytest) test that navigates to a path that should
 return HTTP status_code == 200.
 I prepare a tox.ini file that runs pytest in two different Django
 environments once with Django==4.1.7 and another with Django==4.2.0
 Tox will run the test twice consecutively. The first will pass. the second
 will fail.

 https://github.com/oussjarrousse/djangoproject-ticket-34455

-- 
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/010701874d2c6522-ebc85495-855f-4dd3-a59d-27288af7f639-00%40eu-central-1.amazonses.com.


Re: [Django] #34459: contrib.postgres.search.SearchVector.as_sql can return query strings that are unsafe to combine

2023-04-04 Thread Django
#34459: contrib.postgres.search.SearchVector.as_sql can return query strings 
that
are unsafe to combine
--+
 Reporter:  Patryk Zawadzki   |Owner:  (none)
 Type:  Bug   |   Status:  new
Component:  contrib.postgres  |  Version:  4.2
 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 David Sanders):

 * stage:  Unreviewed => Accepted


Comment:

 Tentatively accepting, I'm seeing errors but only when the args to
 SearchVector are outside that which is documented to accept.

 Felix & Simon will likely be able to clear things up.


 So, to clarify, is this the behaviour you're seeing?

 There's no issue if you filter by the search vector like so:

 {{{
 Foo.objects.annotate(search=SearchVector("text")).filter(search=Value("10%
 off"))
 }}}

 It's when one of the arguments to SearchVector contain a percent that it
 becomes an issue:

 {{{
 Foo.objects.annotate(search=SearchVector("text",
 config="%")).filter(search=Value("10% off"))

 ...

 django/db/models/query.py:373: in __repr__
 data = list(self[: REPR_OUTPUT_SIZE + 1])
 django/db/models/query.py:397: in __iter__
 self._fetch_all()
 django/db/models/query.py:1883: in _fetch_all
 self._result_cache = list(self._iterable_class(self))
 django/db/models/query.py:90: in __iter__
 results = compiler.execute_sql(
 django/db/models/sql/compiler.py:1560: in execute_sql
 cursor.execute(sql, params)
 django/db/backends/utils.py:67: in execute
 return self._execute_with_wrappers(
 django/db/backends/utils.py:80: in _execute_with_wrappers
 return executor(sql, params, many, context)
 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
 _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

 self = 
 sql = 'SELECT "ticket_34459_foo"."id", "ticket_34459_foo"."text",
 to_tsvector(\'%\'::regconfig,
 COALESCE("ticket_34459_foo"tsvector(\'%\'::regconfig,
 COALESCE("ticket_34459_foo"."text", \'\')) @@
 (plainto_tsquery(%s::regconfig, %s)) LIMIT 21'
 params = ('%', '10% off')
 ignored_wrapper_args = (False, {'connection': , 'cursor':
 })

 def _execute(self, sql, params, *ignored_wrapper_args):
 self.db.validate_no_broken_transaction()
 with self.db.wrap_database_errors:
 if params is None:
 # params default might be backend specific.
 print(sql)
 return self.cursor.execute(sql)
 else:
 >   return self.cursor.execute(sql, params)
 E   IndexError: tuple index out of range

 django/db/backends/utils.py:90: IndexError

 }}}

-- 
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/010701874d2bdc7d-d895092c-5d59-4690-9540-84ffac333ef1-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Core (URLs)  |  Version:  4.2
 Severity:  Release blocker  |   Resolution:  needsinfo
 Keywords:   | Triage Stage:
  internationalization, i18n,|  Unreviewed
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-

Comment (by Oussama Jarrousse):

 I will provide the project shortly on github...
 In the meanwhile, I assume you were not able to reproduce the issue
 because you did not include: django.middleware.locale.LocaleMiddleware

 here is MIDDLEWARE list in settings.py

 {{{
 MIDDLEWARE = [
 "django.middleware.security.SecurityMiddleware",
 "django.contrib.sessions.middleware.SessionMiddleware",
 "django.middleware.locale.LocaleMiddleware", # This line is important
 "django.middleware.common.CommonMiddleware",
 "django.middleware.csrf.CsrfViewMiddleware",
 "django.contrib.auth.middleware.AuthenticationMiddleware",
 "django.contrib.messages.middleware.MessageMiddleware",
 "django.middleware.clickjacking.XFrameOptionsMiddleware",
 ]
 }}}

-- 
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/010701874d0a2f8e-3646c442-1ee8-4dbf-a2ae-f313f55d40d7-00%40eu-central-1.amazonses.com.


[Django] #34459: contrib.postgres.search.SearchVector.as_sql can return query strings that are unsafe to combine

2023-04-04 Thread Django
#34459: contrib.postgres.search.SearchVector.as_sql can return query strings 
that
are unsafe to combine
+
   Reporter:  Patryk Zawadzki   |  Owner:  (none)
   Type:  Bug   | Status:  new
  Component:  contrib.postgres  |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 |
+
 As the function specifically calls {{{connection.ops.compose_sql}}}, the
 returned {{{sql}}} will have all parameters inlined.

 An unintended consequence is that if you pass it a value that contains a
 percent sign, like {{{Value("10% OFF")}}}, the resulting {{{sql}}} will
 have the {{{%}}} character inlined. Such values will result in a
 {{{ProgrammingError}}} as soon as you attempt to combine the SearchVector
 with any expression that relies on {{{params}}}.

 Depending on whether you use psycopg2 or psycopg 3, the resulting error
 will tell you that there are not enough params to format the query
 template or that there is an unescaped {{{%}}} in the query.

-- 
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/010701874d04f30c-1889f518-f165-46de-ab0e-dc4a6915c668-00%40eu-central-1.amazonses.com.


[Django] #34458: Calling defer('user_id') instead of defer('user') will raise AttributeError: 'ForeignKey' object has no attribute 'field'

2023-04-04 Thread Django
#34458: Calling defer('user_id') instead of defer('user') will raise
AttributeError: 'ForeignKey' object has no attribute 'field'
-+-
   Reporter:  Andrew |  Owner:  nobody
  Cordery|
   Type:  Bug| Status:  new
  Component:  Database   |Version:  4.2
  layer (models, ORM)|
   Severity:  Normal |   Keywords:
   Triage Stage: |  Has patch:  0
  Unreviewed |
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+-
 Calling defer() with the column name of a foreign key ('user_id') instead
 of the field name ('user') will raise an {{{AttributeError: 'ForeignKey'
 object has no attribute 'field'}}}

 I believe this is either a regression in 4.2 or an undocumented change of
 behavior.  Generally speaking, I'd prefer this new requirement to always
 use the field name as it reduces ambiguity/improves refactoring etc.
 However, it needs documentation and a better error message.


 Here is an example traceback:

 {{{
 In [11]: User.objects.defer('organization_id')
 Out[11]:
 ---
 AttributeErrorTraceback (most recent call
 last)
 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/IPython/core/formatters.py:708, in
 PlainTextFormatter.__call__(self, obj)
 701 stream = StringIO()
 702 printer = pretty.RepresentationPrinter(stream, self.verbose,
 703 self.max_width, self.newline,
 704 max_seq_length=self.max_seq_length,
 705 singleton_pprinters=self.singleton_printers,
 706 type_pprinters=self.type_printers,
 707 deferred_pprinters=self.deferred_printers)
 --> 708 printer.pretty(obj)
 709 printer.flush()
 710 return stream.getvalue()

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/IPython/lib/pretty.py:410, in RepresentationPrinter.pretty(self,
 obj)
 407 return meth(obj, self, cycle)
 408 if cls is not object \
 409 and
 callable(cls.__dict__.get('__repr__')):
 --> 410 return _repr_pprint(obj, self, cycle)
 412 return _default_pprint(obj, self, cycle)
 413 finally:

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/IPython/lib/pretty.py:778, in _repr_pprint(obj, p, cycle)
 776 """A pprint that just redirects to the normal repr function."""
 777 # Find newlines and replace them with p.break_()
 --> 778 output = repr(obj)
 779 lines = output.splitlines()
 780 with p.group():

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/django/db/models/query.py:374, in QuerySet.__repr__(self)
 373 def __repr__(self):
 --> 374 data = list(self[: REPR_OUTPUT_SIZE + 1])
 375 if len(data) > REPR_OUTPUT_SIZE:
 376 data[-1] = "...(remaining elements truncated)..."

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/django/db/models/query.py:398, in QuerySet.__iter__(self)
 383 def __iter__(self):
 384 """
 385 The queryset iterator protocol uses three nested iterators in
 the
 386 default case:
(...)
 396- Responsible for turning the rows into model objects.
 397 """
 --> 398 self._fetch_all()
 399 return iter(self._result_cache)

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/django/db/models/query.py:1881, in QuerySet._fetch_all(self)
1879 def _fetch_all(self):
1880 if self._result_cache is None:
 -> 1881 self._result_cache = list(self._iterable_class(self))
1882 if self._prefetch_related_lookups and not self._prefetch_done:
1883 self._prefetch_related_objects()

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/django/db/models/query.py:91, in ModelIterable.__iter__(self)
  88 compiler = queryset.query.get_compiler(using=db)
  89 # Execute the query. This will also fill compiler.select,
 klass_info,
  90 # and annotations.
 ---> 91 results = compiler.execute_sql(
  92 chunked_fetch=self.chunked_fetch, chunk_size=self.chunk_size
  93 )
  94 select, klass_info, annotation_col_map = (
  95 compiler.select,
  96 compiler.klass_info,
  97 compiler.annotation_col_map,
  98 )
  99 model_cls = klass_info["model"]

 File ~/.local/share/virtualenvs/axi-v3J2FyDc/lib/python3.11/site-
 packages/django/db/models/sql/compiler.py:1547, in
 SQLCompiler.execute_sql(self, 

Re: [Django] #34434: psycopg 3 cursor.execute no longer accepts Python tuple binding

2023-04-04 Thread Django
#34434: psycopg 3 cursor.execute no longer accepts Python tuple binding
-+-
 Reporter:  David Burke  |Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 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
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"272dc386c28a4999b179de8ed57bcddea09676a7" 272dc386]:
 {{{
 #!CommitTicketReference repository=""
 revision="272dc386c28a4999b179de8ed57bcddea09676a7"
 [4.2.x] Refs #34434 -- Added note about breaking changes in psycopg
 version 3 to release notes.

 Backport of ff9ceed32b880733d94190742e45dbcf5927b161 from main
 }}}

-- 
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/010701874ccefa87-ad93d565-1c8e-4c5a-afda-ba01c23a80d3-00%40eu-central-1.amazonses.com.


Re: [Django] #34434: psycopg 3 cursor.execute no longer accepts Python tuple binding

2023-04-04 Thread Django
#34434: psycopg 3 cursor.execute no longer accepts Python tuple binding
-+-
 Reporter:  David Burke  |Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Database layer   |  Version:  4.2
  (models, ORM)  |
 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
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"ff9ceed32b880733d94190742e45dbcf5927b161" ff9ceed3]:
 {{{
 #!CommitTicketReference repository=""
 revision="ff9ceed32b880733d94190742e45dbcf5927b161"
 Refs #34434 -- Added note about breaking changes in psycopg version 3 to
 release notes.
 }}}

-- 
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/010701874cce9f8e-7fdec69a-11cb-424e-9f3f-e9c680b0cea5-00%40eu-central-1.amazonses.com.


Re: [Django] #34457: makemigrations --check no longer prints the changes

2023-04-04 Thread Django
#34457: makemigrations --check no longer prints the changes
-+-
 Reporter:  David Sanders|Owner:  nobody
 Type:   |   Status:  closed
  Cleanup/optimization   |
Component:  Migrations   |  Version:  4.2
 Severity:  Normal   |   Resolution:  wontfix
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * cc: Claude Paroz, Jacob Walls (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/010701874c52-68fcfb50-2e9e-4e62-9068-935d5956066d-00%40eu-central-1.amazonses.com.


Re: [Django] #34457: makemigrations --check no longer prints the changes

2023-04-04 Thread Django
#34457: makemigrations --check no longer prints the changes
-+-
 Reporter:  David Sanders|Owner:  nobody
 Type:   |   Status:  closed
  Cleanup/optimization   |
Component:  Migrations   |  Version:  4.2
 Severity:  Normal   |   Resolution:  wontfix
 Keywords:   | Triage Stage:
 |  Unreviewed
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * status:  new => closed
 * type:  Uncategorized => Cleanup/optimization
 * resolution:   => wontfix


Comment:

 Thanks for the ticket, however I don't think it's worth the inconsistency.
 You could re-run `makemigrations` when `makemigrations --check` exists
 with 1, e.g.
 {{{
 RESULT=`makemigrations --check`
 if [ "$RESULT" -gt 0 ]; then
 makemigrations --dry-run
 fi;
 exit $RESULT
 }}}

-- 
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/010701874cac2b2f-cc1fb39c-6652-4a2e-af76-797deefebaae-00%40eu-central-1.amazonses.com.


Re: [Django] #34456: Add a way to set allow_cascade=True in _fixture_teardown()

2023-04-04 Thread Django
#34456: Add a way to set allow_cascade=True in _fixture_teardown()
---+--
 Reporter:  Howard Cox |Owner:  nobody
 Type:  Uncategorized  |   Status:  closed
Component:  Testing framework  |  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):

 * resolution:  needsinfo => invalid


-- 
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/010701874ca74207-bcc0b75b-4c14-4b39-80e5-78531998684e-00%40eu-central-1.amazonses.com.


Re: [Django] #34451: Incorrect exception handling within the django exception handler

2023-04-04 Thread Django
#34451: Incorrect exception handling within the django exception handler
-+
 Reporter:  Michael Galler   |Owner:  Akshat verma
 Type:  Bug  |   Status:  assigned
Component:  Error reporting  |  Version:  4.1
 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 Akshat verma):

 * owner:  nobody => Akshat verma
 * 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/010701874c860a60-112399ef-2a8e-4f43-8ed8-186ac455387d-00%40eu-central-1.amazonses.com.


Re: [Django] #34456: Add a way to set allow_cascade=True in _fixture_teardown()

2023-04-04 Thread Django
#34456: Add a way to set allow_cascade=True in _fixture_teardown()
---+--
 Reporter:  devanubis  |Owner:  nobody
 Type:  Uncategorized  |   Status:  closed
Component:  Testing framework  |  Version:  4.2
 Severity:  Normal |   Resolution:  needsinfo
 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:   => needsinfo


Comment:

 As far as I'm aware, it's an issue in `timescaledb`, they could override
 `ops.sql_flush()` and add flushing "chunks".

-- 
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/010701874c7f5708-2c551bfd-3037-4536-b37c-f40f298eb970-00%40eu-central-1.amazonses.com.


Re: [Django] #34457: makemigrations --check no longer prints the changes

2023-04-04 Thread Django
#34457: makemigrations --check no longer prints the changes
---+--
 Reporter:  David Sanders  |Owner:  nobody
 Type:  Uncategorized  |   Status:  new
Component:  Migrations |  Version:  4.2
 Severity:  Normal |   Resolution:
 Keywords: | Triage Stage:  Unreviewed
Has patch:  1  |  Needs documentation:  0
  Needs tests:  0  |  Patch needs improvement:  0
Easy pickings:  0  |UI/UX:  0
---+--

Comment (by David Sanders):

 PR: https://github.com/django/django/pull/16723

-- 
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/010701874c5bf353-6c192f46-8753-4ad1-8bf0-0552f39e2579-00%40eu-central-1.amazonses.com.


[Django] #34457: makemigrations --check no longer prints the changes

2023-04-04 Thread Django
#34457: makemigrations --check no longer prints the changes
-+
   Reporter:  David Sanders  |  Owner:  nobody
   Type:  Uncategorized  | Status:  new
  Component:  Migrations |Version:  4.2
   Severity:  Normal |   Keywords:
   Triage Stage:  Unreviewed |  Has patch:  1
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+
 As a result of #34051 the `--check` flag on makemigrations simply exits 1
 without writing any changes.

 This makes sense as it's consistent with other uses of `--check`.

 However one consequence of this change is that my CI server no longer
 prints the changes it thinks I need to make – and this makes the
 situations where the local dev & CI are different, harder to debug.

 I'd like to propose reverting this change and instead forcing `--dry-run`
 to be set if `--check` is supplied. This way makemigrations goes through
 the motions of what it needs to write, outputting those changes to the log
 but the dry flag prevents any migrations from being written.

-- 
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/010701874c557872-9c2a8f48-3008-4fb3-b83f-1d187b28bb4a-00%40eu-central-1.amazonses.com.


Re: [Django] #34456: Add a way to set allow_cascade=True in _fixture_teardown()

2023-04-04 Thread Django
#34456: Add a way to set allow_cascade=True in _fixture_teardown()
---+--
 Reporter:  devanubis  |Owner:  nobody
 Type:  Uncategorized  |   Status:  new
Component:  Testing framework  |  Version:  4.2
 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
---+--
Description changed by devanubis:

Old description:

> We use [django-timescaledb](https://github.com/schlunsen/django-
> timescaledb) as our database backend and ran into a problem with some of
> our tests for django migrations on tables using timescale compression.
>
> I [wrote up our problem on `django-timescaledb` back in
> October](https://github.com/schlunsen/django-timescaledb/issues/40), but
> it essentially boils down to:
>
> * `django.test.testcases.TransactionTestCase._fixture_teardown()` calls
> `django.db.backends.postgresql.operations.sql_flush()` and truncates
> every table at the end of tests.
> * In timescaledb, compressed hypertables create "chunks" as tables with a
> subset of the hypertable's data.
> * Because we have foreign keys in some of our hypertables, the chunk
> tables also get that foreign-key rule.
> * Those chunk tables are transparent to Django, and so are not in the
> list to be truncated.
> * And so, the truncation fails, because the chunk tables still reference
> some of the data being truncated.
>
> The easiest solution seems to be to allow `_fixture_teardown()` to opt-in
> to setting `allow_cascade=True` when truncating.
>
> We're happy to submit a PR if this proposal gets accepted.

New description:

 We use https://github.com/schlunsen/django-timescaledb as our database
 backend and ran into a problem with some of our tests for django
 migrations on tables using timescale compression.

 I [wrote up our problem on `django-timescaledb` back in October
 (https://github.com/schlunsen/django-timescaledb/issues/40) but it
 essentially boils down to:

 * `django.test.testcases.TransactionTestCase._fixture_teardown()` calls
 `django.db.backends.postgresql.operations.sql_flush()` and truncates every
 table at the end of tests.
 * In timescaledb, compressed hypertables create "chunks" as tables with a
 subset of the hypertable's data.
 * Because we have foreign keys in some of our hypertables, the chunk
 tables also get that foreign-key rule.
 * Those chunk tables are transparent to Django, and so are not in the list
 to be truncated.
 * And so, the truncation fails, because the chunk tables still reference
 some of the data being truncated.

 The easiest solution seems to be to allow `_fixture_teardown()` to opt-in
 to setting `allow_cascade=True` when truncating.

 We're happy to submit a PR if this proposal gets 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/010701874c492511-dd5ab238-99c5-4ea3-888f-c888f36ec55e-00%40eu-central-1.amazonses.com.


[Django] #34456: Add a way to set allow_cascade=True in _fixture_teardown()

2023-04-04 Thread Django
#34456: Add a way to set allow_cascade=True in _fixture_teardown()
-+
   Reporter:  devanubis  |  Owner:  nobody
   Type:  Uncategorized  | Status:  new
  Component:  Testing framework  |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  |
-+
 We use [django-timescaledb](https://github.com/schlunsen/django-
 timescaledb) as our database backend and ran into a problem with some of
 our tests for django migrations on tables using timescale compression.

 I [wrote up our problem on `django-timescaledb` back in
 October](https://github.com/schlunsen/django-timescaledb/issues/40), but
 it essentially boils down to:

 * `django.test.testcases.TransactionTestCase._fixture_teardown()` calls
 `django.db.backends.postgresql.operations.sql_flush()` and truncates every
 table at the end of tests.
 * In timescaledb, compressed hypertables create "chunks" as tables with a
 subset of the hypertable's data.
 * Because we have foreign keys in some of our hypertables, the chunk
 tables also get that foreign-key rule.
 * Those chunk tables are transparent to Django, and so are not in the list
 to be truncated.
 * And so, the truncation fails, because the chunk tables still reference
 some of the data being truncated.

 The easiest solution seems to be to allow `_fixture_teardown()` to opt-in
 to setting `allow_cascade=True` when truncating.

 We're happy to submit a PR if this proposal gets 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/010701874c479c3c-63974aa6-6e3f-4de9-bb4b-c3a99a01cbae-00%40eu-central-1.amazonses.com.


Re: [Django] #34450: Lookup expressions across foreign keys introduce extra joins

2023-04-04 Thread Django
#34450: Lookup expressions across foreign keys introduce extra joins
-+-
 Reporter:  Roman Odaisky|Owner:  Simon
 |  Charette
 Type:  Bug  |   Status:  closed
Component:  Database layer   |  Version:  4.1
  (models, ORM)  |
 Severity:  Normal   |   Resolution:  fixed
 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 Mariusz Felisiak ):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"0e1aae7a5f51408b73c5a29e18bd1803dd030930" 0e1aae7a]:
 {{{
 #!CommitTicketReference repository=""
 revision="0e1aae7a5f51408b73c5a29e18bd1803dd030930"
 Fixed #34450 -- Fixed multi-valued JOIN reuse when filtering by
 expressions.

 Thanks Roman Odaisky for the report.
 }}}

-- 
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/010701874c44b564-a1be6e60-49f3-4a3a-a367-da0a2b05669b-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  Oussama Jarrousse|Owner:  nobody
 Type:  Bug  |   Status:  closed
Component:  Core (URLs)  |  Version:  4.2
 Severity:  Release blocker  |   Resolution:  needsinfo
 Keywords:   | Triage Stage:
  internationalization, i18n,|  Unreviewed
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by Mariusz Felisiak):

 * cc: sergioisidoro (added)
 * status:  new => closed
 * resolution:   => needsinfo


Comment:

 Thanks for the ticket, however I'm not able to reproduce this issue. Can
 you provide a small sample project that reproduces this? (it seems to be
 related with 94e7f471c4edef845a4fe5e3160132997b4cca81.)

-- 
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/010701874c126efb-cec10edf-c4b1-4b4d-8956-2c8325350cbb-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  oussjarrousse|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Core (URLs)  |  Version:  4.2
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:
  internationalization, i18n,|  Unreviewed
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Description changed by oussjarrousse:

Old description:

> In my django project urls.py file I have the following setup:
>
> ```
> from django.conf.urls.i18n import i18n_patterns
> from django.contrib import admin
> from django.urls import include
> from django.urls import path
>
> urlpatterns = []
>
> # as an example... include the admin.site.urls
> urlpatterns += i18n_patterns(
> path("admin/", admin.site.urls), prefix_default_language=False
> )
> ```
>
> In versions Django==4.1.7 (or prior), I was able to navigating to /admin/
> without having to add the language prefix.
> Django==4.2.0, navigating to /admin/ will cause a HTTP 302 and only
> /en/admin/ works... although **prefix_default_language=False** is
> explicitly defined.
>
> This change broke my API upon backend packages upgrade from 4.1.7 to
> 4.2.0

New description:

 In my django project urls.py file I have the following setup:


 {{{
 from django.conf.urls.i18n import i18n_patterns
 from django.contrib import admin
 from django.urls import include
 from django.urls import path

 urlpatterns = []

 # as an example... include the admin.site.urls
 urlpatterns += i18n_patterns(
 path("admin/", admin.site.urls), prefix_default_language=False
 )
 }}}

 In versions Django==4.1.7 (or prior), I was able to navigating to /admin/
 without having to add the language prefix.
 Django==4.2.0, navigating to /admin/ will cause a HTTP 302 and only
 /en/admin/ works... although **prefix_default_language=False** is
 explicitly defined.

 This change broke my API upon backend packages upgrade from 4.1.7 to 4.2.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/010701874bf7fb9e-f497a81a-6700-4cbe-8392-f9073eb86dfa-00%40eu-central-1.amazonses.com.


Re: [Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
 Reporter:  oussjarrousse|Owner:  nobody
 Type:  Bug  |   Status:  new
Component:  Core (URLs)  |  Version:  4.2
 Severity:  Release blocker  |   Resolution:
 Keywords:   | Triage Stage:
  internationalization, i18n,|  Unreviewed
  prefix_default_language|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Description changed by oussjarrousse:

Old description:

> In my django project urls.py file I have the following setup:
>
> from django.conf.urls.i18n import i18n_patterns
> from django.contrib import admin
> from django.urls import include
> from django.urls import path
>
> urlpatterns = []
>
> # as an example... include the admin.site.urls
> urlpatterns += i18n_patterns(
> path("admin/", admin.site.urls), prefix_default_language=False
> )
>
> In versions Django==4.1.7 (or prior), I was able to navigating to /admin/
> without having to add the language prefix.
> Django==4.2.0, navigating to /admin/ will cause a HTTP 302 and only
> /en/admin/ works... although **prefix_default_language=False** is
> explicitly defined.
>
> This change broke my API upon backend packages upgrade from 4.1.7 to
> 4.2.0

New description:

 In my django project urls.py file I have the following setup:

 ```
 from django.conf.urls.i18n import i18n_patterns
 from django.contrib import admin
 from django.urls import include
 from django.urls import path

 urlpatterns = []

 # as an example... include the admin.site.urls
 urlpatterns += i18n_patterns(
 path("admin/", admin.site.urls), prefix_default_language=False
 )
 ```

 In versions Django==4.1.7 (or prior), I was able to navigating to /admin/
 without having to add the language prefix.
 Django==4.2.0, navigating to /admin/ will cause a HTTP 302 and only
 /en/admin/ works... although **prefix_default_language=False** is
 explicitly defined.

 This change broke my API upon backend packages upgrade from 4.1.7 to 4.2.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/010701874bf7803a-183d84bc-67f6-4932-a29f-356814fc5374-00%40eu-central-1.amazonses.com.


[Django] #34455: i18n_patterns() not respecting prefix_default_language=False

2023-04-04 Thread Django
#34455: i18n_patterns() not respecting prefix_default_language=False
-+-
   Reporter: |  Owner:  nobody
  oussjarrousse  |
   Type:  Bug| Status:  new
  Component:  Core   |Version:  4.2
  (URLs) |   Keywords:
   Severity:  Release|  internationalization, i18n,
  blocker|  prefix_default_language
   Triage Stage: |  Has patch:  0
  Unreviewed |
Needs documentation:  0  |Needs tests:  0
Patch needs improvement:  0  |  Easy pickings:  0
  UI/UX:  0  |
-+-
 In my django project urls.py file I have the following setup:

 from django.conf.urls.i18n import i18n_patterns
 from django.contrib import admin
 from django.urls import include
 from django.urls import path

 urlpatterns = []

 # as an example... include the admin.site.urls
 urlpatterns += i18n_patterns(
 path("admin/", admin.site.urls), prefix_default_language=False
 )

 In versions Django==4.1.7 (or prior), I was able to navigating to /admin/
 without having to add the language prefix.
 Django==4.2.0, navigating to /admin/ will cause a HTTP 302 and only
 /en/admin/ works... although **prefix_default_language=False** is
 explicitly defined.

 This change broke my API upon backend packages upgrade from 4.1.7 to 4.2.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/010701874bf72438-1894e34c-1fe6-452c-95dc-8e60375f3ac3-00%40eu-central-1.amazonses.com.


Re: [Django] #32847: Adjust models.E025 system check for updated field descriptor setting.

2023-04-04 Thread Django
#32847: Adjust models.E025 system check for updated field descriptor setting.
-+-
 Reporter:  Carlton Gibson   |Owner:  nobody
 Type:   |   Status:  new
  Cleanup/optimization   |
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):

 * cc: Natalia Bidart (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/010701874bb699c6-30be6de5-dbf5-4d89-b711-8742ecf07477-00%40eu-central-1.amazonses.com.


Re: [Django] #34039: Admin search bar is too small to use on small screens

2023-04-04 Thread Django
#34039: Admin search bar is too small to use on small screens
-+-
 Reporter:  Thibaud Colas|Owner:  Ayush
 |  Bisht
 Type:  Bug  |   Status:  closed
Component:  contrib.admin|  Version:  4.0
 Severity:  Normal   |   Resolution:  fixed
 Keywords:  mobile, cross-   | Triage Stage:  Accepted
  browser|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  1|UI/UX:  1
-+-
Changes (by Mariusz Felisiak):

 * status:  assigned => closed
 * needs_better_patch:  1 => 0
 * has_patch:  1 => 0
 * resolution:   => fixed


Comment:

 I cannot reproduce it anymore. Closing as fixed, unless someone can
 provide a reproducible scenario.

-- 
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/010701874afab004-f03182f7-64b9-48ef-8c98-b8d57f11db54-00%40eu-central-1.amazonses.com.


Re: [Django] #34039: Admin search bar is too small to use on small screens

2023-04-04 Thread Django
#34039: Admin search bar is too small to use on small screens
-+-
 Reporter:  Thibaud Colas|Owner:  Ayush
 |  Bisht
 Type:  Bug  |   Status:  assigned
Component:  contrib.admin|  Version:  4.0
 Severity:  Normal   |   Resolution:
 Keywords:  mobile, cross-   | Triage Stage:  Accepted
  browser|
Has patch:  1|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  1
Easy pickings:  1|UI/UX:  1
-+-

Comment (by grey.fenrir):

 Chrome 111.0.5563.146, Firefox 111.0.1 work like a charm for 800 & 1024.
 Shouldn't we close the ticket?

-- 
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/010701874ae5ab79-c95352a8-ba49-4b10-bc90-1953e48952af-00%40eu-central-1.amazonses.com.