INNER CODE UNIT · Python
filter_stale_customer_issues
microsoft/botframework-sdk · dri/helpers.py:41
def filter_stale_customer_issues(issue, days_old=60):
"""Filter stale customer issues.
Return True if it should filter the issue.
"""
if filter_milestone_label(issue):
return True
return not issue.created_at + timedelta(days=days_old) < datetime.now()
def last_touched_by_microsoft(issue, microsoft_members) -> bool:
comments_paged = issue.get_comments()
comment = [msg for msg in comments_paged][-1]
assert comment
return comment.user.login.strip().lower() in microsoft_members
def get_msorg_members(github, refresh_in_days=5):
"""Get members of the Microsoft github organization.
This is cached in the `members.txt` file.
If it gets stale (over `refresh_in_days` old), then refresh it.