microsoft / microsoft/simplechat
Consider making approval expiration background task configurable by admins
Open
Nobody has claimed this yet.
enhancement
- Dominant language
- Python
- Stars
- 152
- Forks
- 116
- Avg merge
- 7h 7m
- Merged PRs (30d)
- 122
Description
There is a background task that periodically checks for expired approval requests and automatically denies them.
# Background task to check for expired approval requests
def check_expired_approvals():
"""Background task that checks for expired approval requests and auto-denies them"""
while True:
try:
from functions_approvals import auto_deny_expired_approvals
denied_count = auto_deny_expired_approvals()
if denied_count > 0:
print(f"Auto-denied {denied_count} expired approval request(s).")
except Exception as e:
print(f"Error in approval expiration check: {e}")
# Check every 6 hours (21600 seconds)
time.sleep(21600)
The check interval and behavior are currently fixed in code.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the background task and the functions_approvals.auto_deny_expired_approvals entry point. Determine how administrators could control the six-hour interval and expiration behavior, then verify that both settings are honored by the approval-expiration task.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100