Error when deleting an institution whose auth method is in use

Bug #917873 reported by Richard Mansfield
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Mahara
Fix Released
Low
Richard Mansfield

Bug Description

When you delete an institution, and one of the institution's authinstances is still in use by some users, you get an sql error and a nonrecoverable error screen. (This can only happen when the users still using the authinstance are not institution members, because there is already a check to stop deletion of institutions with members).

tags: added: auth institutions
Revision history for this message
François Marier (fmarier) wrote :
Revision history for this message
Mahara Bot (dev-mahara) wrote : A change has been merged

Reviewed: https://reviews.mahara.org/995
Committed: http://gitorious.org/mahara/mahara/commit/d1310840778f167cecc13971194ab0a156785afc
Submitter: Richard Mansfield (<email address hidden>)
Branch: master

commit d1310840778f167cecc13971194ab0a156785afc
Author: Richard Mansfield <email address hidden>
Date: Wed Jan 18 09:52:52 2012 +1300

    Check for authinstances in use when deleting institutions (bug #917873)

    When you delete an institution, and one of the institution's
    authinstances is still in use by some users, you get an sql error and
    a nonrecoverable error screen. (This can only happen when the users
    still using the authinstance are not institution members, because
    there is already a check to stop deletion of institutions with
    members).

    This patch allows the institution to be deleted anyway, reassigning
    the offending users to a 'default' authinstance. If we can't find a
    sensible default authinstance, it will at least display a more helpful
    error message.

    Also, when attempting to delete an institution with members, set an
    error on the form rather than throwing a ConfigException.

    Change-Id: I9c85a3c8c80411e3cf526767b9142efb12907e5c
    Signed-off-by: Richard Mansfield <email address hidden>

Changed in mahara:
status: In Progress → Fix Committed
Revision history for this message
Melissa Draper (melissa) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

status: fixreleased
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBAgAGBQJPjqbSAAoJECXBtiziiXdc9lQH/ihyu7QAsQTauz6R0kgBF2og
xGfwoCzflrqvhr0M52SR9mS/oVvb0ZerWl6CL2aJ8Aq5dTGNZ2+dHsDZTTYGQzF0
qLheaMcgjVQyCasJQzFwP4eVhxP5d7PUvHTPoB2SfQOMrzb6LdbF3ZuaPk11bImk
zjRhyzLIDuqPGCvkm/RSr3RlyuLlQD6/mSXfHLXRMKuG6ZXZQdgwvAgbRVrqCukJ
HeAfb9i1gVLgMoKO1OGur+sCYD155g6GtykNolwC1vXGI2lwL5yko4rBq47m1zTJ
iEMJngvutbkLqfkLye2DrqEGfPdJSD28cn0yTrGo4r8c8v+VErQG2fw28Do62AQ=
=PEOy
-----END PGP SIGNATURE-----

Revision history for this message
Melissa Draper (melissa) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

status fixreleased
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBAgAGBQJPjrKtAAoJECXBtiziiXdcUwoH/2T7TneDztExyzwY3jqJTs/Y
RyZ+uApeCE5D2ICXyJjXwQa5J4hwSnVwXWB6W0BGUspaTlHk5DU2uHMV7tJ6GnyK
+Z/jxi99+oRi3ejXk21hpZou9c1uPTtHHzNw8l/y8S3yOBwo+kWE9UNjrpYHNGZc
BRtQyh447e+4x4ocrR5ldieyEo5gYiFztVAtxNKSx00iCTpGXEiGmLKQ+8RhABMc
b/yOYWmLrgcBrvbC8xuQWZoXYgiZvsC0pjZnMHVW1SDrXHLbxsdcE1D/T1Vm+U7q
f0tHry8pHQnJQlbd8hm6vlOQR8Zo3wEB8knRCR0euQFr9oC32PBHaVLHZ75Dx+4=
=NY/1
-----END PGP SIGNATURE-----

Revision history for this message
Melissa Draper (melissa) wrote :

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

 status fixreleased
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQEcBAEBAgAGBQJPjrT9AAoJECXBtiziiXdcoRgIAI6WEF/A3ND2GQDSpnq5f/tC
dX+/FeJZVxYHJpRv9z3v9pQ47AuNacrcWJkRdDsc7A+/XEP++DWUU5lvYy65941s
gekqH765BpnPqOU3QAWzhhQqQAJo/aSk94H+YZCoJTtw4tA4sOWxITkItb1SAt33
Q8bnKihJZYHtgfKtEv7gzd2oyk5Jk1xAJjE8fpcJpjXdkpF2Gda82JOpR2hrFnfo
k/nH5VLwHELKBMmLhFjTasfe2R5/LjBaDQp4r93ZdZBl5qer00yUQoEIgInJg+LK
Rs5onHkg5YWn5ezTrMkRBAp/goHyrcYaunC4sJ4cazP1+YtC10oJq8fnuv1Xq9A=
=fz6e
-----END PGP SIGNATURE-----

Changed in mahara:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.