mahara-contributors team mailing list archive
-
mahara-contributors team
-
Mailing list archive
-
Message #01028
[Bug 619074] Re: adding collection description shows site unavailabel
I think that this bug may be in lib/collection.php->commit() rather than a missing field in the pieform.
We may need to think about this for similar commit() function within Mahara.
Here's the related IRC transcript:
16:44 < dobedobedoh> re that bug, I'm wondering whether the bug is actually in lib/collection.php->commit().
16:45 * lamiette looks
16:45 < dobedobedoh> I wonder whether it should only try and update fields which have been changed
16:46 < dobedobedoh> At present it tries to set a value for every possible key, but not all keys are set before commit is called
16:47 < dobedobedoh> Since update_record only changes fields which are specified, checking !is_null($v) on that array may be better
16:47 < dobedobedoh> e.g. http://gist.github.com/530492
16:48 < lamiette> yeah, I've just caught up with what you mean
16:48 < lamiette> had to have another look at update_record
16:48 < dobedobedoh> The only reason that's causing an exception is because navigation is defined with NOT_NULL
16:49 < dobedobedoh> So commit() could be causing other data to be loss if it's not specified on the page I think...
16:49 < dobedobedoh> Or could feasibly in the future - I can't see any evidence of it doing so at present
16:50 < lamiette> no, I wouldnt' think so at the moment, but it's not future proof ... hang on, just looking at things
16:53 < lamiette> knowing that it was based on existing commit functions in Mahara and that they all operate in a similar way
16:54 < lamiette> it might be a discussion that involves a few more commit functions
16:54 < lamiette> and not specific to collection
16:54 < dobedobedoh> Possibly...
16:55 < dobedobedoh> I'm going home shortly. Shall I add this transcript to the bug and unassign myself for now?
16:55 < lamiette> I totally get where you're coming from though :) just wondering if instead of giving collection preferential treatment we should future proof for all :D
16:56 < dobedobedoh> yeah I wonder the same. I had a quick look at views and see what you mean
16:56 < lamiette> I know I copied that (Views) so yeah :P
16:56 < lamiette> add this to transcript, god idea
16:56 < lamiette> *good idea
16:56 < lamiette> patch might suit for initial fix and bigger picture moved to a new bug
16:57 < dobedobedoh> I suspect that the patch I gisthubbed may not work for creating a new collection because navigation may not be set
--
adding collection description shows site unavailabel
https://bugs.launchpad.net/bugs/619074
You received this bug notification because you are a member of Mahara
Contributors, which is subscribed to Mahara.
Status in Mahara ePortfolio: New
Bug description:
I tried to edit a existing collction and added a Collection description
and see
Mahara: Master Branch: Site unavailable
A nonrecoverable error occured. This probably means you have encountered a bug in the system
References