#24525: AssertionError at `Query.change_aliases`
-------------------------------------+-------------------------------------
     Reporter:  coolRR               |                    Owner:  nobody
         Type:  Bug                  |                   Status:  new
    Component:  Database layer       |                  Version:  1.7
  (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 timgraham):

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


Comment:

 Reporter provided the SQL from the queries that are being ANDed. Maybe
 this is enough to be helpful to an ORM expert; reopening on that basis.

 {{{
 SELECT "soufle_app_stack"."id", "soufle_app_stack"."datetime_created",
 "soufle_app_stack"."datetime_updated", "soufle_app_stack"."_name",
 "soufle_app_stack"."owner_id", "soufle_app_stack"."is_public_reading",
 "soufle_app_stack"."is_discussion_stack",
 "soufle_app_stack"."datetime_canceled" FROM "soufle_app_stack" LEFT OUTER
 JOIN "soufle_app_stack__readers" ON ( "soufle_app_stack"."id" =
 "soufle_app_stack__readers"."stack_id" ) LEFT OUTER JOIN
 "soufle_app_stack__writers" ON ( "soufle_app_stack"."id" =
 "soufle_app_stack__writers"."stack_id" ) WHERE
 ("soufle_app_stack"."datetime_canceled" IS NULL AND
 ("soufle_app_stack"."is_public_reading" = True OR
 "soufle_app_stack__readers"."user_id" = 147 OR
 "soufle_app_stack__writers"."user_id" = 147 OR
 "soufle_app_stack"."owner_id" = 147)) ORDER BY
 "soufle_app_stack"."datetime_created" DESC

 SELECT "soufle_app_stack"."id", "soufle_app_stack"."datetime_created",
 "soufle_app_stack"."datetime_updated", "soufle_app_stack"."_name",
 "soufle_app_stack"."owner_id", "soufle_app_stack"."is_public_reading",
 "soufle_app_stack"."is_discussion_stack",
 "soufle_app_stack"."datetime_canceled" FROM "soufle_app_stack" LEFT OUTER
 JOIN "soufle_app_stack__readers" ON ( "soufle_app_stack"."id" =
 "soufle_app_stack__readers"."stack_id" ) LEFT OUTER JOIN
 "soufle_app_stack__writers" ON ( "soufle_app_stack"."id" =
 "soufle_app_stack__writers"."stack_id" ) INNER JOIN "soufle_app_follow" ON
 ( "soufle_app_stack"."id" = "soufle_app_follow"."stack_id" ) WHERE
 ("soufle_app_stack"."datetime_canceled" IS NULL AND
 ("soufle_app_stack"."is_public_reading" = True OR
 "soufle_app_stack__readers"."user_id" = 147 OR
 "soufle_app_stack__writers"."user_id" = 147 OR
 "soufle_app_stack"."owner_id" = 147) AND NOT ("soufle_app_stack"."id" IN
 (SELECT U1."private_stack_id" AS "private_stack_id" FROM "soufle_app_user"
 U1 WHERE (U1."id" = 147 AND U1."private_stack_id" IS NOT NULL))) AND NOT
 ("soufle_app_stack"."id" IN (SELECT U1."public_stack_id" AS
 "public_stack_id" FROM "soufle_app_user" U1 WHERE (U1."id" = 147 AND
 U1."public_stack_id" IS NOT NULL))) AND "soufle_app_follow"."user_id" =
 147) ORDER BY "soufle_app_stack"."datetime_created" DESC
 }}}

--
Ticket URL: <https://code.djangoproject.com/ticket/24525#comment:5>
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 [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/064.5d80feece274716c0e970f604115b046%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to