forked from hiero-ledger/hiero-sdk-python
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconstants.js
More file actions
45 lines (41 loc) · 1.22 KB
/
Copy pathconstants.js
File metadata and controls
45 lines (41 loc) · 1.22 KB
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
// SPDX-License-Identifier: Apache-2.0
//
// helpers/constants.js
//
// Shared constants for the Review Queue Label Sync.
/**
* Safety floor for the GitHub API rate limit.
* The cron job will skip processing if remaining calls fall below this.
*/
const RATE_LIMIT_FLOOR = 200;
/**
* The four mutually exclusive queue labels managed by this bot.
*
* Flow:
* queue:junior-committer → queue:committers → queue:maintainers → status: ready-to-merge
*/
const QUEUE_LABELS = {
JUNIOR: {
name: 'queue:junior-committer',
color: 'e4e669',
description: 'PR awaiting initial quality review',
},
COMMITTERS: {
name: 'queue:committers',
color: '0075ca',
description: 'PR awaiting committer technical review',
},
MAINTAINERS: {
name: 'queue:maintainers',
color: 'd876e3',
description: 'PR awaiting maintainer final review',
},
MERGE: {
name: 'status: ready-to-merge',
color: '0e8a16',
description: 'PR has 1+ maintainer and 2+ total approvals, ready to merge',
},
};
/** All queue label names, used for cleanup operations. */
const ALL_QUEUE_LABEL_NAMES = Object.values(QUEUE_LABELS).map((l) => l.name);
module.exports = { RATE_LIMIT_FLOOR, QUEUE_LABELS, ALL_QUEUE_LABEL_NAMES };