Skip to content

Commit

Permalink
feat: make lease expiration times configurable
Browse files Browse the repository at this point in the history
  • Loading branch information
0x29a committed Oct 18, 2024
1 parent a8d0136 commit 55b3bf1
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion openassessment/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
Initialization Information for Open Assessment Module
"""

__version__ = '6.12.1'
__version__ = '6.12.2'
3 changes: 2 additions & 1 deletion openassessment/assessment/models/peer.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
import logging
import random

from django.conf import settings
from django.db import DatabaseError, models
from django.utils.timezone import now

Expand Down Expand Up @@ -108,7 +109,7 @@ class PeerWorkflow(models.Model):
"""
# Amount of time before a lease on a submission expires
TIME_LIMIT = timedelta(hours=8)
TIME_LIMIT = timedelta(hours=getattr(settings, "ORA_PEER_LEASE_EXPIRATION_HOURS", 8))

student_id = models.CharField(max_length=40, db_index=True)
item_id = models.CharField(max_length=255, db_index=True)
Expand Down
3 changes: 2 additions & 1 deletion openassessment/assessment/models/staff.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from datetime import timedelta
import logging

from django.conf import settings
from django.db import DatabaseError, models
from django.utils.timezone import now

Expand All @@ -28,7 +29,7 @@ class StaffWorkflow(models.Model):
"""
# Amount of time before a lease on a submission expires
TIME_LIMIT = timedelta(hours=8)
TIME_LIMIT = timedelta(hours=getattr(settings, "ORA_STAFF_LEASE_EXPIRATION_HOURS", 8))

scorer_id = models.CharField(max_length=40, db_index=True, blank=True)
course_id = models.CharField(max_length=255, db_index=True)
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "edx-ora2",
"version": "6.12.1",
"version": "6.12.2",
"repository": "https://github.com/openedx/edx-ora2.git",
"dependencies": {
"@edx/frontend-build": "8.0.6",
Expand Down

0 comments on commit 55b3bf1

Please sign in to comment.