Re: [Django] #32339: Accessibility issues with Django forms as_table, as_ul, as_p rendering helpers

2021-12-22 Thread Django
#32339: Accessibility issues with Django forms as_table, as_ul, as_p rendering
helpers
-+-
 Reporter:  Thibaud Colas|Owner:  David
 |  Smith
 Type:  Bug  |   Status:  assigned
Component:  Forms|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:  accessibility,   | Triage Stage:  Accepted
  forms, wcag|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  1
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"cb82ded4b26f514c11349c9d13287bb3fb9268c9" cb82ded4]:
 {{{
 #!CommitTicketReference repository=""
 revision="cb82ded4b26f514c11349c9d13287bb3fb9268c9"
 Refs #32339 -- Added rendering tests for forms with CheckboxSelectMultiple
 and SelectMultiple widgets.
 }}}

-- 
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/070.e5854541079756a5317f858fbb1330d7%40djangoproject.com.


Re: [Django] #33355: Optimize SQLite backend connection functions

2021-12-22 Thread Django
#33355: Optimize SQLite backend connection functions
-+-
 Reporter:  Adam Johnson |Owner:  Adam
 Type:   |  Johnson
  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
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"fa4b2c15f27edf8d6b8c88b451e23824ddec928c" fa4b2c15]:
 {{{
 #!CommitTicketReference repository=""
 revision="fa4b2c15f27edf8d6b8c88b451e23824ddec928c"
 Refs #33355 -- Optimized LPad() database function on SQLite.

 Co-Authored-By: Nick Pope 
 }}}

-- 
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/068.0f752d1e71958efed5fe1340f5dbcb67%40djangoproject.com.


[Django] #33382: Different count and len result for a distinct QuerySet

2021-12-22 Thread Django
#33382: Different count and len result for a distinct QuerySet
-+
   Reporter:  826541814  |  Owner:  nobody
   Type:  Uncategorized  | Status:  new
  Component:  Uncategorized  |Version:  3.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  |
-+
 The problem arises when I use the len method on a distinct queryset. The
 object obtained by the len method seems to be not distinct , But the query
 did not change during this time.

 I found what looks like the same Ticket ,But I'm not sure it's the same
 reason [https://code.djangoproject.com/ticket/30655]


 Here is a simple example that shows the contrary.

 Models:

 {{{
 class Exam(models.Model):
 paper = models.ForeignKey(ExamPaper, related_name='paper_exam',
 on_delete=models.CASCADE, blank=True, null=True)

 class StudentPaper(models.Model):
 user = models.ForeignKey(User, related_name='user_exam_paper',
 on_delete=models.CASCADE)
 exam = models.ForeignKey(Exam, related_name='exam_student_paper',
 on_delete=models.CASCADE)
 }}}

 Shell Output:

 {{{
 >>> from ExamManage.models import*
 >>> exam = Exam.objects.first()
 >>> exam.exam_student_paper.filter(is_pass=True).values('user_id').count()
 521
 >>> support_pass_userids =
 exam.exam_student_paper.filter(is_pass=True).values('user_id').distinct()
 >>> support_pass_userids.count()
 484
 >>> print(support_pass_userids.query)
 SELECT DISTINCT `ExamManage_studentpaper`.`user_id`,
 `ExamManage_studentpaper`.`id` FROM `ExamManage_studentpaper` WHERE
 (`ExamManage_studentpaper`.`exam_id` = 5 AND
 `ExamManage_studentpaper`.`is_pass`) ORDER BY
 `ExamManage_studentpaper`.`id` DESC
 >>> len(support_pass_userids)
 521
 >>> support_pass_userids.count()
 521
 >>> print(support_pass_userids.query)
 SELECT DISTINCT `ExamManage_studentpaper`.`user_id`,
 `ExamManage_studentpaper`.`id` FROM `ExamManage_studentpaper` WHERE
 (`ExamManage_studentpaper`.`exam_id` = 5 AND
 `ExamManage_studentpaper`.`is_pass`) ORDER BY
 `ExamManage_studentpaper`.`id` DESC
 }}}

-- 
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/052.1723e2711a6969da62967228c9c67d0d%40djangoproject.com.


Re: [Django] #32355: Drop support for Python 3.6 & 3.7.

2021-12-22 Thread Django
#32355: Drop support for Python 3.6 & 3.7.
-+-
 Reporter:  Mariusz Felisiak |Owner:  Mariusz
 Type:   |  Felisiak
  Cleanup/optimization   |   Status:  closed
Component:  Core (Other) |  Version:  4.0
 Severity:  Normal   |   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:"b5f60ef5a74a86bf8d7fbebf2000284bffb61aac" b5f60ef5]:
 {{{
 #!CommitTicketReference repository=""
 revision="b5f60ef5a74a86bf8d7fbebf2000284bffb61aac"
 [4.0.x] Refs #32355 -- Bumped required psycopg2 version to 2.8.4.

 psycopg2 2.8.4 is the first release to support Python 3.8.
 Backport of ca04659b4b3f042c1bc7e557c25ed91e3c56c745 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/065.a5e149d0de9c189ef54ac78d55db764a%40djangoproject.com.


Re: [Django] #32355: Drop support for Python 3.6 & 3.7.

2021-12-22 Thread Django
#32355: Drop support for Python 3.6 & 3.7.
-+-
 Reporter:  Mariusz Felisiak |Owner:  Mariusz
 Type:   |  Felisiak
  Cleanup/optimization   |   Status:  closed
Component:  Core (Other) |  Version:  4.0
 Severity:  Normal   |   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 GitHub ):

 In [changeset:"ca04659b4b3f042c1bc7e557c25ed91e3c56c745" ca04659]:
 {{{
 #!CommitTicketReference repository=""
 revision="ca04659b4b3f042c1bc7e557c25ed91e3c56c745"
 Refs #32355 -- Bumped required psycopg2 version to 2.8.4.

 psycopg2 2.8.4 is the first release to support Python 3.8.
 }}}

-- 
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/065.3666acdccbf5a70255b945bc3ca8f42a%40djangoproject.com.


Re: [Django] #29294: ModelAdmin.raw_id_fields should be included in select_related() by change_view and used by raw id widget

2021-12-22 Thread Django
#29294: ModelAdmin.raw_id_fields should be included in select_related() by
change_view and used by raw id widget
-+-
 Reporter:  Yurii Zolot'ko   |Owner:  nobody
 Type:   |   Status:  new
  Cleanup/optimization   |
Component:  contrib.admin|  Version:  1.11
 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 Jurrian Tromp):

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


Comment:

 You are right, I am sorry. I left out the `BoundField` part which is
 indeed elemental. See the attachment for a working example,
 `ModelChoiceField` and `RawIdWidgetAdminMixin` are just there to patch it
 to make it work in my project, they are not part of this.

 The way I see it there is just one way to have the `value` supplied to
 `label_and_url_for_value` to be a model instance:

 {{{
 class BoundField(boundfield.BoundField):
 def value(self):
 if type(self.field.widget) == ForeignKeyRawIdWidget:
 try:
 return getattr(self.form.instance, self.name)
 except AttributeError:
 pass
 ...
 }}}

 However this feels hacky to me, although I can not find another way to get
 the model instance except for from the form. When being rendered, the
 `ForeignKeyRawIdWidget` has no access to the form anymore, so it seems the
 only place where we can pass it on is in the `BoundField`.
 What do you think?

-- 
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/064.19250664531b30d1cff4b41fc53ea9e4%40djangoproject.com.


Re: [Django] #29294: ModelAdmin.raw_id_fields should be included in select_related() by change_view and used by raw id widget

2021-12-22 Thread Django
#29294: ModelAdmin.raw_id_fields should be included in select_related() by
change_view and used by raw id widget
-+-
 Reporter:  Yurii Zolot'ko   |Owner:  nobody
 Type:   |   Status:  closed
  Cleanup/optimization   |
Component:  contrib.admin|  Version:  1.11
 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 Jurrian Tromp):

 * Attachment "raw_id_widget.py" 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/064.6a97eee24f54eaac91f27f13977632c8%40djangoproject.com.


Re: [Django] #2259: Primary keys should be readonly by default in admin

2021-12-22 Thread Django
#2259: Primary keys should be readonly by default in admin
-+-
 Reporter:  ed@… |Owner:
 |  siddhartha-star-dev
 Type:  Bug  |   Status:  assigned
Component:  contrib.admin|  Version:  dev
 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 siddhartha-star-dev):

 Replying to [comment:42 Mariusz Felisiak]:
 > Have you seen [https://code.djangoproject.com/ticket/2259#comment:27
 Anssi's proposition]? We don't want to allow for editing primary keys in
 admin. They should not be allowed in the `ModelAdmin.list_editable` and
 become read-only when editing.

 I have seen [https://code.djangoproject.com/ticket/2259#comment:27 Anssi's
 proposition] , and I only put out those ways in reference to the 3 point
 in the proposition (That editable should be an opt-in),  if we are ok in
 always having them non-editable, we should be good, I will start working
 on that for now, we can visit the 3 point later

-- 
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/072.c29588d17ff48f73579b537bcb354a7e%40djangoproject.com.


Re: [Django] #33355: Optimize SQLite backend connection functions

2021-12-22 Thread Django
#33355: Optimize SQLite backend connection functions
-+-
 Reporter:  Adam Johnson |Owner:  Adam
 Type:   |  Johnson
  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 Mariusz Felisiak):

 * needs_better_patch:  0 => 1
 * stage:  Ready for checkin => 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/068.0c65ee83485cb4d31fd493d40011bd15%40djangoproject.com.


Re: [Django] #33355: Optimize SQLite backend connection functions

2021-12-22 Thread Django
#33355: Optimize SQLite backend connection functions
-+-
 Reporter:  Adam Johnson |Owner:  Adam
 Type:   |  Johnson
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   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
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"c4328c2f4e958c13dbe1ff47368f06982dfa59b2" c4328c2f]:
 {{{
 #!CommitTicketReference repository=""
 revision="c4328c2f4e958c13dbe1ff47368f06982dfa59b2"
 Refs #33355 -- Optimized Trunc() on SQLite by using f-strings.

 Co-Authored-By: Nick Pope 
 }}}

-- 
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/068.c8ac4af1f86d5adf7930a691af3160ac%40djangoproject.com.


Re: [Django] #33355: Optimize SQLite backend connection functions

2021-12-22 Thread Django
#33355: Optimize SQLite backend connection functions
-+-
 Reporter:  Adam Johnson |Owner:  Adam
 Type:   |  Johnson
  Cleanup/optimization   |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   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
-+-

Comment (by Mariusz Felisiak ):

 In [changeset:"a8fa3e5cd77416b9e4a5b28b216fb3e19609a37d" a8fa3e5c]:
 {{{
 #!CommitTicketReference repository=""
 revision="a8fa3e5cd77416b9e4a5b28b216fb3e19609a37d"
 Refs #33355 -- Added missing tests for database functions and expression
 on null values.
 }}}

-- 
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/068.79b8ca491120f6613303ff96b1625c6e%40djangoproject.com.


Re: [Django] #32339: Accessibility issues with Django forms as_table, as_ul, as_p rendering helpers

2021-12-22 Thread Django
#32339: Accessibility issues with Django forms as_table, as_ul, as_p rendering
helpers
-+-
 Reporter:  Thibaud Colas|Owner:  David
 |  Smith
 Type:  Bug  |   Status:  assigned
Component:  Forms|  Version:  dev
 Severity:  Normal   |   Resolution:
 Keywords:  accessibility,   | Triage Stage:  Accepted
  forms, wcag|
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  1
-+-
Changes (by David Smith):

 * owner:  nobody => David Smith
 * 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/070.383f35bb41e2944ef5338943ac95a3ce%40djangoproject.com.


Re: [Django] #373: Add support for multiple-column primary keys

2021-12-22 Thread Django
#373: Add support for multiple-column primary keys
-+-
 Reporter:  Jacob|Owner:  raydeal
 Type:  New feature  |   Status:  assigned
Component:  Database layer   |  Version:  dev
  (models, ORM)  |
 Severity:  Normal   |   Resolution:
 Keywords:  database | Triage Stage:  Accepted
Has patch:  0|  Needs documentation:  0
  Needs tests:  0|  Patch needs improvement:  0
Easy pickings:  0|UI/UX:  0
-+-
Changes (by raydeal):

 * cc: raydeal (added)
 * owner:  (none) => raydeal
 * status:  new => assigned


Comment:

 I would like to dive into this issue and see how can I help.

-- 
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/063.834e50d5ca4532fd5cd9c5c9eae78067%40djangoproject.com.


Re: [Django] #19580: Unify reverse foreign key and m2m unsaved model querying

2021-12-22 Thread Django
#19580: Unify reverse foreign key and m2m unsaved model querying
-+-
 Reporter:  Anssi Kääriäinen |Owner:  raydeal
 Type:   |   Status:  assigned
  Cleanup/optimization   |
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:  1|UI/UX:  0
-+-
Changes (by raydeal):

 * owner:  (none) => raydeal


Comment:

 I would like to look at code and try to improve the patch.

-- 
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/066.c446bea8a1acd7a843a0fb35e4f190f9%40djangoproject.com.