mumuki / mumuki-domain

💡 Mumuki's domain model
GNU Affero General Public License v3.0
1 stars 0 forks source link

Feature prevent manual content #176

Closed flbulgarelli closed 3 years ago

flbulgarelli commented 3 years ago

:dart: Goal

To allow content with manual_evaluation to be used in organizations than don't have teachers and thus no one is going to evaluate the submissions.

:memo: Details

This PR introduces the prevent_manual_evaluation_content flag for organizations that won't manually evaluate submission. When enabled, exercises with manual_evaluation are simply wiped locally.

This PR relies on default_scope. Yes, I know that using it is largely discouraged (eg here and here). However, I think this is a case where it still applies, and using named scopes would require a huge refactor to the whole platform.

Actually, I think it is good to completely ignore manual exercises in such contexts, like it were a soft delete. I can't think of a scenario where unscoped would be actually necessary, since you don't edit guides from an organization - you are either in a organization-less script or implicitly using base.

:soon: Future work

This feature may be subsumed by adaptive paths in the future, since it also deals with skipping exercises in some sense.

:back: Backward compatibility

This PR is completely backwards compatible.

:warning: Warnings