#35336: Adding GeneratedField fails with ProgrammingError when using When on CharField -------------------------------------+------------------------------------- Reporter: Adrian Garcia | Owner: Simon | Charette Type: Bug | Status: closed Component: Database layer | Version: 5.0 (models, ORM) | Severity: Release blocker | Resolution: fixed Keywords: postgres, | Triage Stage: Ready for generatedfield, contains | checkin Has patch: 1 | Needs documentation: 0 Needs tests: 0 | Patch needs improvement: 0 Easy pickings: 0 | UI/UX: 0 -------------------------------------+------------------------------------- Comment (by Sarah Boyce <42296566+sarahboyce@…>):
In [changeset:"5d95a1c35ef1375a7badcb217c36c5974d1e57ee" 5d95a1c]: {{{#!CommitTicketReference repository="" revision="5d95a1c35ef1375a7badcb217c36c5974d1e57ee" [5.0.x] Refs #35194 -- Adjusted a generated field test to work on Postgres 15.6+. Postgres >= 12.18, 13.14, 14.11, 15.6, 16.2 changed the way the immutability of generated and default expressions is detected in postgres/postgres@743ddaf. The adjusted test semantic is presereved by switching from __icontains to __contains as both make use of a `%` literal which requires proper escaping. Refs #35336. Thanks bcail for the report. Backport of 73b62a21265c4a417004d64d13a896469e2558f3 from main. }}} -- Ticket URL: <https://code.djangoproject.com/ticket/35336#comment:14> Django <https://code.djangoproject.com/> 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/0107018ed265d787-3335be85-617a-46ce-b820-16e8b883abc4-000000%40eu-central-1.amazonses.com.