Skip to content

Add ability to schedule approval queue settings changes #818

@julianweng

Description

@julianweng

Currently, admins have to manually open / close the approval and reapproval queues, which is inconvenient on its own. It's also not well integrated with the deactivate command, which allows (and forces) the admin to specify a specific date in which the queue would be opened as a parameter. However, there is nothing enforcing the queue to be open at this date. The queues are also supposed to be closed after a certain point in the school year, which existing and prospective club leaders don't have an easy way to check.

We had previously discussed hardcoded cronjobs for this kind of automation, but this (imo) shifts too much responsibility onto us as a platform, lacks visibility for admin users, and is hard to maintain.

Some kind of singleton setting, e.g. date_of_next_flip, should be maintained similarly to that of the current open/closed status of the two queues (where the direction of the flip can hopefully be insinuated from the current status). For the actual changing of the status, some options are busy-waiting using a cron (probably the simplest but also not very elegant), using a dedicated library such as Celery to schedule the change asynchronously, or something algorithmically clever like converting the 2 open/closed boolean states to 4 date variables such as "approval_queue_off_latest_set", where the open/closed states can be backed out by taking the latest of, say, "approval_queue_off_latest_set" and "approval_queue_on_latest_set" that is still in the past.

This kind of setting should be easily visible to both club leaders and admins, changeable by admins, and integrate with the deactivation and renewal processes (including club notification).

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions