@intentius/sql-yodeler 0.7.0 → 0.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +10 -2
- package/dist/apply-steps/index.d.ts +73 -21
- package/dist/apply-steps/index.js +171 -49
- package/dist/apply-steps/index.js.map +1 -1
- package/dist/ci/render.d.ts +11 -2
- package/dist/ci/render.js +21 -6
- package/dist/ci/render.js.map +1 -1
- package/dist/cli.js +1 -1
- package/dist/cli.js.map +1 -1
- package/dist/commands/apply.js +173 -64
- package/dist/commands/apply.js.map +1 -1
- package/dist/commands/drift.js +8 -8
- package/dist/commands/drift.js.map +1 -1
- package/dist/commands/lint.js +10 -7
- package/dist/commands/lint.js.map +1 -1
- package/dist/commands/override.js +46 -22
- package/dist/commands/override.js.map +1 -1
- package/dist/commands/plan.js +19 -19
- package/dist/commands/plan.js.map +1 -1
- package/dist/commands/revert.js +3 -2
- package/dist/commands/revert.js.map +1 -1
- package/dist/config/define.d.ts +12 -7
- package/dist/config/define.js.map +1 -1
- package/dist/lint/check.d.ts +3 -0
- package/dist/lint/check.js +3 -2
- package/dist/lint/check.js.map +1 -1
- package/dist/lint/policies.d.ts +22 -0
- package/dist/lint/policies.js +47 -0
- package/dist/lint/policies.js.map +1 -0
- package/dist/lint/schema-checks.d.ts +14 -3
- package/dist/lint/schema-checks.js +11 -5
- package/dist/lint/schema-checks.js.map +1 -1
- package/dist/mcp/tools.d.ts +1 -1
- package/dist/mcp/tools.js +6 -4
- package/dist/mcp/tools.js.map +1 -1
- package/dist/notify/index.d.ts +30 -97
- package/dist/notify/index.js +50 -154
- package/dist/notify/index.js.map +1 -1
- package/dist/notify/verify.d.ts +17 -31
- package/dist/notify/verify.js +16 -47
- package/dist/notify/verify.js.map +1 -1
- package/dist/pr/forge.d.ts +33 -38
- package/dist/pr/forge.js +74 -97
- package/dist/pr/forge.js.map +1 -1
- package/dist/pr/issue.d.ts +16 -33
- package/dist/pr/issue.js +17 -88
- package/dist/pr/issue.js.map +1 -1
- package/dist/pr/model.js +7 -2
- package/dist/pr/model.js.map +1 -1
- package/dist/pr/render.js +2 -2
- package/dist/pr/render.js.map +1 -1
- package/dist/release/index.d.ts +63 -0
- package/dist/release/index.js +122 -0
- package/dist/release/index.js.map +1 -0
- package/dist/report/audit.d.ts +18 -19
- package/dist/report/audit.js +57 -27
- package/dist/report/audit.js.map +1 -1
- package/dist/report/model.js +18 -5
- package/dist/report/model.js.map +1 -1
- package/dist/tenants/wave.d.ts +6 -2
- package/dist/tenants/wave.js +1 -3
- package/dist/tenants/wave.js.map +1 -1
- package/dist/versioned/policy.d.ts +44 -24
- package/dist/versioned/policy.js +70 -37
- package/dist/versioned/policy.js.map +1 -1
- package/dist/waves/index.d.ts +4 -10
- package/dist/waves/index.js +8 -33
- package/dist/waves/index.js.map +1 -1
- package/package.json +19 -8
- package/schemas/event.schema.json +218 -26
- package/dist/pr/comment.d.ts +0 -32
- package/dist/pr/comment.js +0 -99
- package/dist/pr/comment.js.map +0 -1
|
@@ -1,37 +1,229 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
3
|
"$id": "https://intentius.io/sql-yodeler/schemas/v1/event.schema.json",
|
|
4
|
-
"title": "a yodel webhook event",
|
|
5
|
-
"description": "Version 1. The body yodel apply, yodel plan and yodel drift post to the webhook yodel.config.ts notify names,
|
|
4
|
+
"title": "a yodel webhook event (chant.notify/v1)",
|
|
5
|
+
"description": "Version 1. The body yodel apply, yodel plan and yodel drift post to the webhook yodel.config.ts notify names: chant's chant.notify/v1 event (https://intentius.io/chant/schemas/notify/v1/notify.schema.json), with source sql-yodeler and the command that sent it in detail.command. Signed with HMAC-SHA256 over '<x-yodel-timestamp>.<body>' in the x-yodel-signature header. A field is only ever added within a version; a receiver ignores fields it does not know.",
|
|
6
6
|
"type": "object",
|
|
7
|
-
"
|
|
8
|
-
|
|
7
|
+
"required": [
|
|
8
|
+
"schema",
|
|
9
|
+
"id",
|
|
10
|
+
"event",
|
|
11
|
+
"at",
|
|
12
|
+
"source",
|
|
13
|
+
"project",
|
|
14
|
+
"summary",
|
|
15
|
+
"targets",
|
|
16
|
+
"environment",
|
|
17
|
+
"detail"
|
|
18
|
+
],
|
|
9
19
|
"properties": {
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
"
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
"
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
"schema": {
|
|
21
|
+
"const": "chant.notify/v1"
|
|
22
|
+
},
|
|
23
|
+
"id": {
|
|
24
|
+
"type": "string",
|
|
25
|
+
"minLength": 1,
|
|
26
|
+
"description": "The same for every send of one event about one digest (else drift fingerprint, else commit), so a receiver can drop a repeat; random when there is none. The delivery header carries it too."
|
|
27
|
+
},
|
|
28
|
+
"event": {
|
|
29
|
+
"enum": [
|
|
30
|
+
"waiting",
|
|
31
|
+
"refused",
|
|
32
|
+
"failed",
|
|
33
|
+
"drift"
|
|
34
|
+
]
|
|
35
|
+
},
|
|
36
|
+
"at": {
|
|
37
|
+
"type": "string",
|
|
38
|
+
"description": "When it was sent, ISO 8601 UTC."
|
|
39
|
+
},
|
|
40
|
+
"source": {
|
|
41
|
+
"const": "sql-yodeler"
|
|
42
|
+
},
|
|
43
|
+
"project": {
|
|
44
|
+
"type": "string",
|
|
45
|
+
"description": "What the run belongs to: the repository, or a name the product gives."
|
|
46
|
+
},
|
|
47
|
+
"summary": {
|
|
48
|
+
"type": "string",
|
|
49
|
+
"description": "One line a person can read."
|
|
50
|
+
},
|
|
51
|
+
"wave": {
|
|
52
|
+
"type": "object",
|
|
53
|
+
"required": [
|
|
54
|
+
"number"
|
|
55
|
+
],
|
|
56
|
+
"properties": {
|
|
57
|
+
"number": {
|
|
58
|
+
"type": "integer",
|
|
59
|
+
"minimum": 1
|
|
60
|
+
},
|
|
61
|
+
"name": {
|
|
62
|
+
"type": "string"
|
|
63
|
+
},
|
|
64
|
+
"gate": {
|
|
65
|
+
"type": "string",
|
|
66
|
+
"description": "The gate the wave waits on."
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"environment": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"description": "The environment the run is for."
|
|
73
|
+
},
|
|
74
|
+
"targets": {
|
|
75
|
+
"type": "array",
|
|
76
|
+
"items": {
|
|
77
|
+
"type": "string"
|
|
78
|
+
},
|
|
79
|
+
"description": "The migrations concerned: the pending ones for apply and plan; empty for drift."
|
|
80
|
+
},
|
|
81
|
+
"digest": {
|
|
82
|
+
"type": "string",
|
|
83
|
+
"description": "The plan digest an approval binds."
|
|
84
|
+
},
|
|
85
|
+
"approve": {
|
|
86
|
+
"type": "object",
|
|
87
|
+
"description": "On waiting: how a person approves it.",
|
|
88
|
+
"required": [
|
|
89
|
+
"command"
|
|
90
|
+
],
|
|
91
|
+
"properties": {
|
|
92
|
+
"command": {
|
|
93
|
+
"type": "string",
|
|
94
|
+
"description": "The command to run, as the product prints it."
|
|
95
|
+
},
|
|
96
|
+
"chant": {
|
|
97
|
+
"type": "string",
|
|
98
|
+
"description": "chant's own command for the same approval, when the product's differs."
|
|
99
|
+
},
|
|
100
|
+
"review": {
|
|
101
|
+
"type": "object",
|
|
102
|
+
"description": "Under pr-review: the pull request whose approving review would approve it.",
|
|
103
|
+
"required": [
|
|
104
|
+
"pr",
|
|
105
|
+
"url"
|
|
106
|
+
],
|
|
107
|
+
"properties": {
|
|
108
|
+
"pr": {
|
|
109
|
+
"type": "integer"
|
|
110
|
+
},
|
|
111
|
+
"url": {
|
|
112
|
+
"type": "string"
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
"status": {
|
|
119
|
+
"type": "string",
|
|
120
|
+
"description": "The command's own word for the outcome: gated, refused, denied, failed, incomplete, drifted."
|
|
121
|
+
},
|
|
122
|
+
"reason": {
|
|
123
|
+
"type": "string",
|
|
124
|
+
"description": "On refused and failed: why."
|
|
125
|
+
},
|
|
126
|
+
"exitCode": {
|
|
127
|
+
"type": "integer"
|
|
128
|
+
},
|
|
23
129
|
"drift": {
|
|
24
130
|
"type": "object",
|
|
25
|
-
"
|
|
26
|
-
|
|
131
|
+
"required": [
|
|
132
|
+
"changed"
|
|
133
|
+
],
|
|
27
134
|
"properties": {
|
|
28
|
-
"changed": {
|
|
29
|
-
|
|
30
|
-
|
|
135
|
+
"changed": {
|
|
136
|
+
"type": "array",
|
|
137
|
+
"items": {
|
|
138
|
+
"type": "string"
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
"missing": {
|
|
142
|
+
"type": "array",
|
|
143
|
+
"items": {
|
|
144
|
+
"type": "string"
|
|
145
|
+
}
|
|
146
|
+
},
|
|
147
|
+
"failed": {
|
|
148
|
+
"type": "array",
|
|
149
|
+
"items": {
|
|
150
|
+
"type": "string"
|
|
151
|
+
},
|
|
152
|
+
"description": "What could not be checked."
|
|
153
|
+
},
|
|
154
|
+
"fingerprint": {
|
|
155
|
+
"type": "string",
|
|
156
|
+
"description": "The same drift has the same fingerprint, run after run."
|
|
157
|
+
}
|
|
31
158
|
}
|
|
32
159
|
},
|
|
33
|
-
"
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
160
|
+
"run": {
|
|
161
|
+
"type": "object",
|
|
162
|
+
"properties": {
|
|
163
|
+
"url": {
|
|
164
|
+
"type": "string",
|
|
165
|
+
"description": "The CI run's page (GitHub, Forgejo) or job's page (GitLab)."
|
|
166
|
+
},
|
|
167
|
+
"forge": {
|
|
168
|
+
"enum": [
|
|
169
|
+
"github",
|
|
170
|
+
"gitlab",
|
|
171
|
+
"forgejo"
|
|
172
|
+
]
|
|
173
|
+
},
|
|
174
|
+
"repository": {
|
|
175
|
+
"type": "string"
|
|
176
|
+
},
|
|
177
|
+
"commit": {
|
|
178
|
+
"type": "string"
|
|
179
|
+
},
|
|
180
|
+
"pr": {
|
|
181
|
+
"type": "integer"
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
},
|
|
185
|
+
"reportUrl": {
|
|
186
|
+
"type": "string"
|
|
187
|
+
},
|
|
188
|
+
"detail": {
|
|
189
|
+
"type": "object",
|
|
190
|
+
"required": [
|
|
191
|
+
"command"
|
|
192
|
+
],
|
|
193
|
+
"properties": {
|
|
194
|
+
"command": {
|
|
195
|
+
"enum": [
|
|
196
|
+
"apply",
|
|
197
|
+
"plan",
|
|
198
|
+
"drift"
|
|
199
|
+
],
|
|
200
|
+
"description": "The yodel command that sent it."
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
"allOf": [
|
|
206
|
+
{
|
|
207
|
+
"if": {
|
|
208
|
+
"required": [
|
|
209
|
+
"event"
|
|
210
|
+
],
|
|
211
|
+
"properties": {
|
|
212
|
+
"event": {
|
|
213
|
+
"const": "drift"
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
},
|
|
217
|
+
"then": {
|
|
218
|
+
"required": [
|
|
219
|
+
"drift"
|
|
220
|
+
],
|
|
221
|
+
"properties": {
|
|
222
|
+
"drift": {
|
|
223
|
+
"type": "object"
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
]
|
|
37
229
|
}
|
package/dist/pr/comment.d.ts
DELETED
|
@@ -1,32 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* One comment per environment on the pull request: found by its marker and
|
|
3
|
-
* updated, else created. The three forges' REST APIs:
|
|
4
|
-
*
|
|
5
|
-
* GitHub GET/POST {api}/repos/{owner}/{repo}/issues/{n}/comments
|
|
6
|
-
* PATCH {api}/repos/{owner}/{repo}/issues/comments/{id}
|
|
7
|
-
* GitLab GET/POST {api}/projects/{id}/merge_requests/{iid}/notes
|
|
8
|
-
* PUT {api}/projects/{id}/merge_requests/{iid}/notes/{note_id}
|
|
9
|
-
* Forgejo GET/POST {api}/repos/{owner}/{repo}/issues/{n}/comments (Gitea's API, /api/v1)
|
|
10
|
-
* PATCH {api}/repos/{owner}/{repo}/issues/comments/{id}
|
|
11
|
-
*/
|
|
12
|
-
import type { ForgeTarget } from "./forge.js";
|
|
13
|
-
export interface ForgeComment {
|
|
14
|
-
id: number;
|
|
15
|
-
body: string;
|
|
16
|
-
url?: string | undefined;
|
|
17
|
-
}
|
|
18
|
-
export interface CommentClient {
|
|
19
|
-
list(): Promise<ForgeComment[]>;
|
|
20
|
-
create(body: string): Promise<ForgeComment>;
|
|
21
|
-
update(id: number, body: string): Promise<ForgeComment>;
|
|
22
|
-
}
|
|
23
|
-
type Fetch = typeof fetch;
|
|
24
|
-
export declare function commentClient(t: ForgeTarget, f?: Fetch): CommentClient;
|
|
25
|
-
/** The comment carrying `marker`, the newest when several do. */
|
|
26
|
-
export declare function findComment(c: CommentClient, marker: string): Promise<ForgeComment | undefined>;
|
|
27
|
-
/** Updates the comment carrying `marker`, or creates one. */
|
|
28
|
-
export declare function upsertComment(c: CommentClient, marker: string, body: string, existing?: ForgeComment): Promise<{
|
|
29
|
-
action: "created" | "updated" | "unchanged";
|
|
30
|
-
comment: ForgeComment;
|
|
31
|
-
}>;
|
|
32
|
-
export {};
|
package/dist/pr/comment.js
DELETED
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* One comment per environment on the pull request: found by its marker and
|
|
3
|
-
* updated, else created. The three forges' REST APIs:
|
|
4
|
-
*
|
|
5
|
-
* GitHub GET/POST {api}/repos/{owner}/{repo}/issues/{n}/comments
|
|
6
|
-
* PATCH {api}/repos/{owner}/{repo}/issues/comments/{id}
|
|
7
|
-
* GitLab GET/POST {api}/projects/{id}/merge_requests/{iid}/notes
|
|
8
|
-
* PUT {api}/projects/{id}/merge_requests/{iid}/notes/{note_id}
|
|
9
|
-
* Forgejo GET/POST {api}/repos/{owner}/{repo}/issues/{n}/comments (Gitea's API, /api/v1)
|
|
10
|
-
* PATCH {api}/repos/{owner}/{repo}/issues/comments/{id}
|
|
11
|
-
*/
|
|
12
|
-
import { YodelError } from "../project.js";
|
|
13
|
-
const PAGE = 100;
|
|
14
|
-
const MAX_PAGES = 50;
|
|
15
|
-
function client(t, f, shape) {
|
|
16
|
-
const call = async (method, url, body) => {
|
|
17
|
-
let res;
|
|
18
|
-
try {
|
|
19
|
-
res = await f(url, { method, headers: { ...shape.headers, ...(body ? { "Content-Type": "application/json" } : {}) }, ...(body ? { body: JSON.stringify(body) } : {}) });
|
|
20
|
-
}
|
|
21
|
-
catch (e) {
|
|
22
|
-
throw new YodelError(`${t.forge}: ${method} ${url} failed: ${e instanceof Error ? e.message : String(e)}`);
|
|
23
|
-
}
|
|
24
|
-
const text = await res.text();
|
|
25
|
-
if (!res.ok)
|
|
26
|
-
throw new YodelError(`${t.forge}: ${method} ${url} answered ${String(res.status)}: ${text.slice(0, 300).replaceAll(t.token, "[token]")}`);
|
|
27
|
-
return text ? JSON.parse(text) : {};
|
|
28
|
-
};
|
|
29
|
-
const toComment = (c) => ({ id: Number(c.id), body: typeof c.body === "string" ? c.body : "", url: shape.webUrl?.(c) ?? (typeof c.html_url === "string" ? c.html_url : undefined) });
|
|
30
|
-
return {
|
|
31
|
-
async list() {
|
|
32
|
-
const all = [];
|
|
33
|
-
for (let page = 1; page <= MAX_PAGES; page++) {
|
|
34
|
-
const got = (await call("GET", shape.list(page)));
|
|
35
|
-
if (!Array.isArray(got))
|
|
36
|
-
throw new YodelError(`${t.forge}: listing comments did not return a list`);
|
|
37
|
-
all.push(...got.filter((c) => shape.keep?.(c) ?? true).map(toComment));
|
|
38
|
-
if (got.length < PAGE)
|
|
39
|
-
break;
|
|
40
|
-
}
|
|
41
|
-
return all;
|
|
42
|
-
},
|
|
43
|
-
async create(body) {
|
|
44
|
-
return toComment((await call("POST", shape.create, { body })));
|
|
45
|
-
},
|
|
46
|
-
async update(id, body) {
|
|
47
|
-
return toComment((await call(shape.updateMethod, shape.update(id), { body })));
|
|
48
|
-
},
|
|
49
|
-
};
|
|
50
|
-
}
|
|
51
|
-
const repoPath = (repo) => repo.split("/").map(encodeURIComponent).join("/");
|
|
52
|
-
export function commentClient(t, f = fetch) {
|
|
53
|
-
if (t.forge === "gitlab") {
|
|
54
|
-
const base = `${t.apiUrl}/projects/${encodeURIComponent(t.repo)}/merge_requests/${String(t.pr)}/notes`;
|
|
55
|
-
return client(t, f, {
|
|
56
|
-
headers: { "PRIVATE-TOKEN": t.token, Accept: "application/json" },
|
|
57
|
-
list: (page) => `${base}?per_page=${String(PAGE)}&page=${String(page)}&sort=asc&order_by=created_at`,
|
|
58
|
-
create: base,
|
|
59
|
-
update: (id) => `${base}/${String(id)}`,
|
|
60
|
-
updateMethod: "PUT",
|
|
61
|
-
// System notes ("added 1 commit") are the forge's own, never ours.
|
|
62
|
-
keep: (c) => c.system !== true,
|
|
63
|
-
});
|
|
64
|
-
}
|
|
65
|
-
if (t.forge === "forgejo") {
|
|
66
|
-
const base = `${t.apiUrl}/repos/${repoPath(t.repo)}/issues`;
|
|
67
|
-
return client(t, f, {
|
|
68
|
-
headers: { Authorization: `token ${t.token}`, Accept: "application/json" },
|
|
69
|
-
list: (page) => `${base}/${String(t.pr)}/comments?limit=${String(PAGE)}&page=${String(page)}`,
|
|
70
|
-
create: `${base}/${String(t.pr)}/comments`,
|
|
71
|
-
update: (id) => `${base}/comments/${String(id)}`,
|
|
72
|
-
updateMethod: "PATCH",
|
|
73
|
-
});
|
|
74
|
-
}
|
|
75
|
-
const base = `${t.apiUrl}/repos/${repoPath(t.repo)}/issues`;
|
|
76
|
-
return client(t, f, {
|
|
77
|
-
headers: { Authorization: `Bearer ${t.token}`, Accept: "application/vnd.github+json", "X-GitHub-Api-Version": "2022-11-28" },
|
|
78
|
-
list: (page) => `${base}/${String(t.pr)}/comments?per_page=${String(PAGE)}&page=${String(page)}`,
|
|
79
|
-
create: `${base}/${String(t.pr)}/comments`,
|
|
80
|
-
update: (id) => `${base}/comments/${String(id)}`,
|
|
81
|
-
updateMethod: "PATCH",
|
|
82
|
-
});
|
|
83
|
-
}
|
|
84
|
-
/** The comment carrying `marker`, the newest when several do. */
|
|
85
|
-
export async function findComment(c, marker) {
|
|
86
|
-
return (await c.list()).filter((x) => x.body.includes(marker)).at(-1);
|
|
87
|
-
}
|
|
88
|
-
/** Updates the comment carrying `marker`, or creates one. */
|
|
89
|
-
export async function upsertComment(c, marker, body, existing) {
|
|
90
|
-
if (!body.includes(marker))
|
|
91
|
-
throw new YodelError("the comment body has no marker; it could never be found again to update");
|
|
92
|
-
const found = existing ?? (await findComment(c, marker));
|
|
93
|
-
if (!found)
|
|
94
|
-
return { action: "created", comment: await c.create(body) };
|
|
95
|
-
if (found.body === body)
|
|
96
|
-
return { action: "unchanged", comment: found };
|
|
97
|
-
return { action: "updated", comment: await c.update(found.id, body) };
|
|
98
|
-
}
|
|
99
|
-
//# sourceMappingURL=comment.js.map
|
package/dist/pr/comment.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"comment.js","sourceRoot":"","sources":["../../src/pr/comment.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAwB3C,MAAM,IAAI,GAAG,GAAG,CAAC;AACjB,MAAM,SAAS,GAAG,EAAE,CAAC;AAErB,SAAS,MAAM,CAAC,CAAc,EAAE,CAAQ,EAAE,KAQzC;IACC,MAAM,IAAI,GAAG,KAAK,EAAE,MAAc,EAAE,GAAW,EAAE,IAAc,EAAoB,EAAE;QACnF,IAAI,GAAa,CAAC;QAClB,IAAI,CAAC;YACH,GAAG,GAAG,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE,GAAG,KAAK,CAAC,OAAO,EAAE,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,cAAc,EA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