forked from cockpit-project/bots
-
Notifications
You must be signed in to change notification settings - Fork 0
/
issues-review
executable file
·92 lines (74 loc) · 3.31 KB
/
issues-review
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
#!/usr/bin/env python3
import argparse
import time
from task import github
bug_msg = """
This issue is closed due to inactivity.
If you are still able to reproduce it, please comment here and provide us with
an updated reproducer.
"""
rfe_msg = """
This issue is closed due to inactivity.
We are sorry, but we won't be able to address this in any time soon.
If you are interested in helping us with the implementation, please comment here.
"""
general_msg = """
This issue is closed due to inactivity.
If this issue is a bug report and you are still able to reproduce it, please
comment here and provide us with an updated reproducer.
If this issue is a request for a new feature, we are sorry, but we won't be able
to address this in any time soon. If you are interested in helping us with
the implementation, please comment here.
"""
def issues_review(api, opts):
now = time.time()
treshold = opts.age * 86400
count = 100
page = 1
while count == 100:
issues = api.get("issues?filter=all&page=%i&per_page=%i" % (pag