Moodle

It should not be possible to move or remove the modata folder

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Critical Critical
  • Resolution: Fixed
  • Affects Version/s: 1.9.4
  • Fix Version/s: 1.9.5
  • Component/s: Files API
  • Labels:
    None
  • Affected Branches:
    MOODLE_19_STABLE
  • Fixed Branches:
    MOODLE_19_STABLE

Description

Related to MDL-2639..

I'm not sure what the current state is with the new File API in Moodle 2.0, but in 1.9 its possible to move the moddata folder. We should at least try and warn about this to prevent inadvertent dataloss.

Activity

Hide
Adma Lim added a comment -

or, the admin would have the option to hide the moddate folder from the teacher's view.

Show
Adma Lim added a comment - or, the admin would have the option to hide the moddate folder from the teacher's view.
Hide
Elena Ivanova added a comment -

Yes, it would be nice to make that folder read-only or something. It took us some nerves to restore student files, once instructor killed the moddata folder altogether.
Talking about folders, some instructors manage to put real course files into backupdata folder, and then students cannot see those files from the course homepage.
Can we add a little warning text right near the name of the folders? I know that we can add the warning text to the top of the page, but people tend to skip that.
e.g moddata - attn: this is a system folder. Leave it alone!

Show
Elena Ivanova added a comment - Yes, it would be nice to make that folder read-only or something. It took us some nerves to restore student files, once instructor killed the moddata folder altogether. Talking about folders, some instructors manage to put real course files into backupdata folder, and then students cannot see those files from the course homepage. Can we add a little warning text right near the name of the folders? I know that we can add the warning text to the top of the page, but people tend to skip that. e.g moddata - attn: this is a system folder. Leave it alone!
Hide
Anthony Borrow added a comment -

Dan - Well, there is a warning to the user that they are about to delete a bunch of files; however, perhaps for this instance there should be a special warning to the teacher or perhaps even an additional or higher level capability check to make sure it is someone besides the Average Joe/Jane Teacher who says "Hey, I didn't put this here. Maybe it's a virus so I'll delete it." This might be a fun place for one of those funny error messages like "Yo, stupid do you really want to delete all the hard work your students have done this semester?" Thanks for raising this issue! Peace - Anthony

Show
Anthony Borrow added a comment - Dan - Well, there is a warning to the user that they are about to delete a bunch of files; however, perhaps for this instance there should be a special warning to the teacher or perhaps even an additional or higher level capability check to make sure it is someone besides the Average Joe/Jane Teacher who says "Hey, I didn't put this here. Maybe it's a virus so I'll delete it." This might be a fun place for one of those funny error messages like "Yo, stupid do you really want to delete all the hard work your students have done this semester?" Thanks for raising this issue! Peace - Anthony
Hide
Anthony Borrow added a comment -

Despite the warning, I'm going to bump the priority on this because of the potential for serious data loss.

Show
Anthony Borrow added a comment - Despite the warning, I'm going to bump the priority on this because of the potential for serious data loss.
Hide
Anthony Borrow added a comment -

Dan - Have you discussed this on the Moodle.org forums to see how this ought to be handled. Do teachers want to be protected from themselves? Do they want a big red flashing sign telling them they really do not want to do that? Or do folks feel that the existing warning is enough? I think having some discussion about this will help Petr determine what to do. Peace - Anthony

Show
Anthony Borrow added a comment - Dan - Have you discussed this on the Moodle.org forums to see how this ought to be handled. Do teachers want to be protected from themselves? Do they want a big red flashing sign telling them they really do not want to do that? Or do folks feel that the existing warning is enough? I think having some discussion about this will help Petr determine what to do. Peace - Anthony
Hide
Petr Škoda (skodak) added a comment -

done, the UI now does not allow you to select modata for any operation,
please note that it is UI hack only, if you manage to select it somehow you can do the action

I hope this should be enough for 1.9.x - 2.0 will not have this problem any more

thanks for the report

Show
Petr Škoda (skodak) added a comment - done, the UI now does not allow you to select modata for any operation, please note that it is UI hack only, if you manage to select it somehow you can do the action I hope this should be enough for 1.9.x - 2.0 will not have this problem any more thanks for the report
Hide
Sam Hemelryk added a comment -

Confirmed the patch stops the user from being able to delete moddata. Thanks guys

Show
Sam Hemelryk added a comment - Confirmed the patch stops the user from being able to delete moddata. Thanks guys

Dates

  • Created:
    Updated:
    Resolved: