@babamba2/abap-mcp-adt-powerup 4.6.0 → 4.7.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/dist/handlers/common/high/handleActivateObjects.d.ts +81 -0
- package/dist/handlers/common/high/handleActivateObjects.d.ts.map +1 -0
- package/dist/handlers/common/high/handleActivateObjects.js +123 -0
- package/dist/handlers/common/high/handleActivateObjects.js.map +1 -0
- package/dist/handlers/common/low/handleActivateObject.d.ts.map +1 -1
- package/dist/handlers/common/low/handleActivateObject.js +30 -27
- package/dist/handlers/common/low/handleActivateObject.js.map +1 -1
- package/dist/handlers/gui_status/high/handlePatchGuiStatus.d.ts +57 -0
- package/dist/handlers/gui_status/high/handlePatchGuiStatus.d.ts.map +1 -0
- package/dist/handlers/gui_status/high/handlePatchGuiStatus.js +216 -0
- package/dist/handlers/gui_status/high/handlePatchGuiStatus.js.map +1 -0
- package/dist/handlers/gui_status/high/handleUpdateGuiStatus.d.ts +11 -3
- package/dist/handlers/gui_status/high/handleUpdateGuiStatus.d.ts.map +1 -1
- package/dist/handlers/gui_status/high/handleUpdateGuiStatus.js +39 -6
- package/dist/handlers/gui_status/high/handleUpdateGuiStatus.js.map +1 -1
- package/dist/handlers/include/high/handleCreateInclude.d.ts +13 -1
- package/dist/handlers/include/high/handleCreateInclude.d.ts.map +1 -1
- package/dist/handlers/include/high/handleCreateInclude.js +127 -29
- package/dist/handlers/include/high/handleCreateInclude.js.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.d.ts +8 -1
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.js +72 -8
- package/dist/handlers/system/readonly/handleRuntimeGetDumpById.js.map +1 -1
- package/dist/handlers/system/readonly/handleRuntimeGetGatewayErrorLog.d.ts +48 -0
- package/dist/handlers/system/readonly/handleRuntimeGetGatewayErrorLog.d.ts.map +1 -0
- package/dist/handlers/system/readonly/handleRuntimeGetGatewayErrorLog.js +81 -0
- package/dist/handlers/system/readonly/handleRuntimeGetGatewayErrorLog.js.map +1 -0
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.d.ts +50 -0
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.d.ts.map +1 -0
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.js +104 -0
- package/dist/handlers/system/readonly/handleRuntimeListFeeds.js.map +1 -0
- package/dist/handlers/system/readonly/handleRuntimeListSystemMessages.d.ts +43 -0
- package/dist/handlers/system/readonly/handleRuntimeListSystemMessages.d.ts.map +1 -0
- package/dist/handlers/system/readonly/handleRuntimeListSystemMessages.js +61 -0
- package/dist/handlers/system/readonly/handleRuntimeListSystemMessages.js.map +1 -0
- package/dist/handlers/system/readonly/runtimeFeedsHelper.d.ts +165 -0
- package/dist/handlers/system/readonly/runtimeFeedsHelper.d.ts.map +1 -0
- package/dist/handlers/system/readonly/runtimeFeedsHelper.js +399 -0
- package/dist/handlers/system/readonly/runtimeFeedsHelper.js.map +1 -0
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.d.ts +41 -0
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.d.ts.map +1 -0
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.js +104 -0
- package/dist/handlers/text_element/high/handleReadTextElementsBulk.js.map +1 -0
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.d.ts +87 -0
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.d.ts.map +1 -0
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.js +210 -0
- package/dist/handlers/text_element/high/handleWriteTextElementsBulk.js.map +1 -0
- package/dist/lib/cuaSchema.d.ts +113 -0
- package/dist/lib/cuaSchema.d.ts.map +1 -0
- package/dist/lib/cuaSchema.js +208 -0
- package/dist/lib/cuaSchema.js.map +1 -0
- package/dist/lib/gatewayRfc.d.ts +1 -1
- package/dist/lib/gatewayRfc.d.ts.map +1 -1
- package/dist/lib/gatewayRfc.js.map +1 -1
- package/dist/lib/handlers/groups/HighLevelHandlersGroup.d.ts.map +1 -1
- package/dist/lib/handlers/groups/HighLevelHandlersGroup.js +20 -0
- package/dist/lib/handlers/groups/HighLevelHandlersGroup.js.map +1 -1
- package/dist/lib/handlers/groups/SystemHandlersGroup.d.ts.map +1 -1
- package/dist/lib/handlers/groups/SystemHandlersGroup.js +15 -0
- package/dist/lib/handlers/groups/SystemHandlersGroup.js.map +1 -1
- package/dist/lib/localGroupActivation.d.ts +88 -0
- package/dist/lib/localGroupActivation.d.ts.map +1 -0
- package/dist/lib/localGroupActivation.js +271 -0
- package/dist/lib/localGroupActivation.js.map +1 -0
- package/dist/lib/nativeRfc.d.ts +1 -1
- package/dist/lib/nativeRfc.d.ts.map +1 -1
- package/dist/lib/nativeRfc.js.map +1 -1
- package/dist/lib/odataRfc.d.ts +1 -1
- package/dist/lib/odataRfc.d.ts.map +1 -1
- package/dist/lib/odataRfc.js.map +1 -1
- package/dist/lib/resolveAdtUri.d.ts +35 -0
- package/dist/lib/resolveAdtUri.d.ts.map +1 -0
- package/dist/lib/resolveAdtUri.js +121 -0
- package/dist/lib/resolveAdtUri.js.map +1 -0
- package/dist/lib/soapRfc.d.ts +5 -2
- package/dist/lib/soapRfc.d.ts.map +1 -1
- package/dist/lib/soapRfc.js +4 -1
- package/dist/lib/soapRfc.js.map +1 -1
- package/dist/lib/textElementsSource.d.ts +81 -0
- package/dist/lib/textElementsSource.d.ts.map +1 -0
- package/dist/lib/textElementsSource.js +184 -0
- package/dist/lib/textElementsSource.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ActivateObjects — High-level mass activation for a set of ABAP objects.
|
|
3
|
+
*
|
|
4
|
+
* Hits `/sap/bc/adt/activation/runs` exactly once for the entire batch,
|
|
5
|
+
* regardless of object count. Designed for scenarios where objects carry
|
|
6
|
+
* cyclic references (e.g. 5 includes referencing each other's TYPES/FORMs)
|
|
7
|
+
* that cannot be activated one-by-one because each individual activation
|
|
8
|
+
* would fail on unresolved references to still-inactive siblings.
|
|
9
|
+
*
|
|
10
|
+
* Falls back to the legacy sync `/sap/bc/adt/activation` endpoint on
|
|
11
|
+
* NetWeaver systems where `/runs` is unavailable.
|
|
12
|
+
*
|
|
13
|
+
* This is additive — the existing `ActivateObjectLow` and per-handler
|
|
14
|
+
* inline activation paths are untouched.
|
|
15
|
+
*/
|
|
16
|
+
import type { HandlerContext } from '../../../lib/handlers/interfaces';
|
|
17
|
+
export declare const TOOL_DEFINITION: {
|
|
18
|
+
readonly name: "ActivateObjects";
|
|
19
|
+
readonly available_in: readonly ["onprem", "cloud", "legacy"];
|
|
20
|
+
readonly description: "[high-level] Activate a set of ABAP objects in a single call. Uses the ADT mass-activation endpoint (/sap/bc/adt/activation/runs) so cyclic references between siblings (e.g. main program + multiple cross-referencing includes) resolve in one compilation scope. Returns per-object status, errors, warnings. Falls back to /sap/bc/adt/activation on legacy systems.";
|
|
21
|
+
readonly inputSchema: {
|
|
22
|
+
readonly type: "object";
|
|
23
|
+
readonly properties: {
|
|
24
|
+
readonly objects: {
|
|
25
|
+
readonly type: "array";
|
|
26
|
+
readonly minItems: 1;
|
|
27
|
+
readonly description: "Objects to activate in one batch. Supply either explicit uri, or name+type (and parent_name for FUGR/FF, FUGR/I).";
|
|
28
|
+
readonly items: {
|
|
29
|
+
readonly type: "object";
|
|
30
|
+
readonly properties: {
|
|
31
|
+
readonly name: {
|
|
32
|
+
readonly type: "string";
|
|
33
|
+
readonly description: "Object name (will be uppercased).";
|
|
34
|
+
};
|
|
35
|
+
readonly type: {
|
|
36
|
+
readonly type: "string";
|
|
37
|
+
readonly description: "ADT object type code, e.g. 'PROG/P' (program), 'PROG/I' (include), 'CLAS/OC' (class), 'FUGR/FF' (function module).";
|
|
38
|
+
};
|
|
39
|
+
readonly uri: {
|
|
40
|
+
readonly type: "string";
|
|
41
|
+
readonly description: "Explicit ADT URI. When provided, overrides name-based URI resolution.";
|
|
42
|
+
};
|
|
43
|
+
readonly parent_name: {
|
|
44
|
+
readonly type: "string";
|
|
45
|
+
readonly description: "Parent name — required for FUGR/FF (function group) and FUGR/I (function-group include).";
|
|
46
|
+
};
|
|
47
|
+
};
|
|
48
|
+
readonly required: readonly ["name"];
|
|
49
|
+
};
|
|
50
|
+
};
|
|
51
|
+
readonly preaudit: {
|
|
52
|
+
readonly type: "boolean";
|
|
53
|
+
readonly description: "Request pre-audit before activation. Default true.";
|
|
54
|
+
};
|
|
55
|
+
readonly run_timeout_ms: {
|
|
56
|
+
readonly type: "number";
|
|
57
|
+
readonly description: "Max time to wait for the activation run to finish (runs endpoint only). Default 120000.";
|
|
58
|
+
};
|
|
59
|
+
};
|
|
60
|
+
readonly required: readonly ["objects"];
|
|
61
|
+
};
|
|
62
|
+
};
|
|
63
|
+
interface ActivateObjectsArgs {
|
|
64
|
+
objects: Array<{
|
|
65
|
+
name: string;
|
|
66
|
+
type?: string;
|
|
67
|
+
uri?: string;
|
|
68
|
+
parent_name?: string;
|
|
69
|
+
}>;
|
|
70
|
+
preaudit?: boolean;
|
|
71
|
+
run_timeout_ms?: number;
|
|
72
|
+
}
|
|
73
|
+
export declare function handleActivateObjects(context: HandlerContext, args: ActivateObjectsArgs): Promise<{
|
|
74
|
+
isError: boolean;
|
|
75
|
+
content: {
|
|
76
|
+
type: string;
|
|
77
|
+
text: any;
|
|
78
|
+
}[];
|
|
79
|
+
}>;
|
|
80
|
+
export {};
|
|
81
|
+
//# sourceMappingURL=handleActivateObjects.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handleActivateObjects.d.ts","sourceRoot":"","sources":["../../../../src/handlers/common/high/handleActivateObjects.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAOvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAmDlB,CAAC;AAEX,UAAU,mBAAmB;IAC3B,OAAO,EAAE,KAAK,CAAC;QACb,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,CAAC,EAAE,MAAM,CAAC;QACd,GAAG,CAAC,EAAE,MAAM,CAAC;QACb,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC,CAAC;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,wBAAsB,qBAAqB,CACzC,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,mBAAmB;;;;;;GAsE1B"}
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* ActivateObjects — High-level mass activation for a set of ABAP objects.
|
|
4
|
+
*
|
|
5
|
+
* Hits `/sap/bc/adt/activation/runs` exactly once for the entire batch,
|
|
6
|
+
* regardless of object count. Designed for scenarios where objects carry
|
|
7
|
+
* cyclic references (e.g. 5 includes referencing each other's TYPES/FORMs)
|
|
8
|
+
* that cannot be activated one-by-one because each individual activation
|
|
9
|
+
* would fail on unresolved references to still-inactive siblings.
|
|
10
|
+
*
|
|
11
|
+
* Falls back to the legacy sync `/sap/bc/adt/activation` endpoint on
|
|
12
|
+
* NetWeaver systems where `/runs` is unavailable.
|
|
13
|
+
*
|
|
14
|
+
* This is additive — the existing `ActivateObjectLow` and per-handler
|
|
15
|
+
* inline activation paths are untouched.
|
|
16
|
+
*/
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.TOOL_DEFINITION = void 0;
|
|
19
|
+
exports.handleActivateObjects = handleActivateObjects;
|
|
20
|
+
const localGroupActivation_1 = require("../../../lib/localGroupActivation");
|
|
21
|
+
const utils_1 = require("../../../lib/utils");
|
|
22
|
+
exports.TOOL_DEFINITION = {
|
|
23
|
+
name: 'ActivateObjects',
|
|
24
|
+
available_in: ['onprem', 'cloud', 'legacy'],
|
|
25
|
+
description: '[high-level] Activate a set of ABAP objects in a single call. Uses the ADT mass-activation endpoint (/sap/bc/adt/activation/runs) so cyclic references between siblings (e.g. main program + multiple cross-referencing includes) resolve in one compilation scope. Returns per-object status, errors, warnings. Falls back to /sap/bc/adt/activation on legacy systems.',
|
|
26
|
+
inputSchema: {
|
|
27
|
+
type: 'object',
|
|
28
|
+
properties: {
|
|
29
|
+
objects: {
|
|
30
|
+
type: 'array',
|
|
31
|
+
minItems: 1,
|
|
32
|
+
description: 'Objects to activate in one batch. Supply either explicit uri, or name+type (and parent_name for FUGR/FF, FUGR/I).',
|
|
33
|
+
items: {
|
|
34
|
+
type: 'object',
|
|
35
|
+
properties: {
|
|
36
|
+
name: {
|
|
37
|
+
type: 'string',
|
|
38
|
+
description: 'Object name (will be uppercased).',
|
|
39
|
+
},
|
|
40
|
+
type: {
|
|
41
|
+
type: 'string',
|
|
42
|
+
description: "ADT object type code, e.g. 'PROG/P' (program), 'PROG/I' (include), 'CLAS/OC' (class), 'FUGR/FF' (function module).",
|
|
43
|
+
},
|
|
44
|
+
uri: {
|
|
45
|
+
type: 'string',
|
|
46
|
+
description: 'Explicit ADT URI. When provided, overrides name-based URI resolution.',
|
|
47
|
+
},
|
|
48
|
+
parent_name: {
|
|
49
|
+
type: 'string',
|
|
50
|
+
description: 'Parent name — required for FUGR/FF (function group) and FUGR/I (function-group include).',
|
|
51
|
+
},
|
|
52
|
+
},
|
|
53
|
+
required: ['name'],
|
|
54
|
+
},
|
|
55
|
+
},
|
|
56
|
+
preaudit: {
|
|
57
|
+
type: 'boolean',
|
|
58
|
+
description: 'Request pre-audit before activation. Default true.',
|
|
59
|
+
},
|
|
60
|
+
run_timeout_ms: {
|
|
61
|
+
type: 'number',
|
|
62
|
+
description: 'Max time to wait for the activation run to finish (runs endpoint only). Default 120000.',
|
|
63
|
+
},
|
|
64
|
+
},
|
|
65
|
+
required: ['objects'],
|
|
66
|
+
},
|
|
67
|
+
};
|
|
68
|
+
async function handleActivateObjects(context, args) {
|
|
69
|
+
const { connection, logger } = context;
|
|
70
|
+
try {
|
|
71
|
+
if (!args?.objects ||
|
|
72
|
+
!Array.isArray(args.objects) ||
|
|
73
|
+
args.objects.length === 0) {
|
|
74
|
+
return (0, utils_1.return_error)(new Error('Missing required parameter: objects (must be a non-empty array)'));
|
|
75
|
+
}
|
|
76
|
+
for (const obj of args.objects) {
|
|
77
|
+
if (!obj?.name && !obj?.uri) {
|
|
78
|
+
return (0, utils_1.return_error)(new Error('Each object must carry at least "name" (or "uri")'));
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
const inputs = args.objects.map((o) => ({
|
|
82
|
+
name: o.name,
|
|
83
|
+
type: o.type ?? '',
|
|
84
|
+
uri: o.uri,
|
|
85
|
+
parent_name: o.parent_name,
|
|
86
|
+
}));
|
|
87
|
+
logger?.info(`ActivateObjects: ${inputs.length} object(s) → /sap/bc/adt/activation/runs`);
|
|
88
|
+
const result = await (0, localGroupActivation_1.activateObjectsLocal)(connection, inputs, {
|
|
89
|
+
preauditRequested: args.preaudit !== false,
|
|
90
|
+
runTimeoutMs: args.run_timeout_ms,
|
|
91
|
+
});
|
|
92
|
+
const failed = result.objects.filter((o) => o.status === 'failed').length;
|
|
93
|
+
const summary = {
|
|
94
|
+
success: result.success,
|
|
95
|
+
endpoint: result.endpoint,
|
|
96
|
+
run_id: result.run_id,
|
|
97
|
+
activated: result.activated,
|
|
98
|
+
checked: result.checked,
|
|
99
|
+
generated: result.generated,
|
|
100
|
+
objects_count: result.objects.length,
|
|
101
|
+
failed_count: failed,
|
|
102
|
+
objects: result.objects,
|
|
103
|
+
errors: result.errors,
|
|
104
|
+
warnings: result.warnings,
|
|
105
|
+
message: result.success
|
|
106
|
+
? `Activated ${result.objects.length} object(s) via ${result.endpoint} endpoint`
|
|
107
|
+
: `Activation finished with ${result.errors.length} error(s) across ${failed} object(s)`,
|
|
108
|
+
};
|
|
109
|
+
return (0, utils_1.return_response)({
|
|
110
|
+
data: JSON.stringify(summary, null, 2),
|
|
111
|
+
status: 200,
|
|
112
|
+
statusText: 'OK',
|
|
113
|
+
headers: {},
|
|
114
|
+
config: {},
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
catch (error) {
|
|
118
|
+
const message = error?.message || String(error);
|
|
119
|
+
logger?.error(`ActivateObjects failed: ${message}`);
|
|
120
|
+
return (0, utils_1.return_error)(new Error(`ActivateObjects failed: ${message}`));
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
//# sourceMappingURL=handleActivateObjects.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handleActivateObjects.js","sourceRoot":"","sources":["../../../../src/handlers/common/high/handleActivateObjects.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;GAcG;;;AAyEH,sDAwEC;AA9ID,4EAG2C;AAC3C,8CAAmE;AAEtD,QAAA,eAAe,GAAG;IAC7B,IAAI,EAAE,iBAAiB;IACvB,YAAY,EAAE,CAAC,QAAQ,EAAE,OAAO,EAAE,QAAQ,CAAU;IACpD,WAAW,EACT,0WAA0W;IAC5W,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,OAAO,EAAE;gBACP,IAAI,EAAE,OAAO;gBACb,QAAQ,EAAE,CAAC;gBACX,WAAW,EACT,mHAAmH;gBACrH,KAAK,EAAE;oBACL,IAAI,EAAE,QAAQ;oBACd,UAAU,EAAE;wBACV,IAAI,EAAE;4BACJ,IAAI,EAAE,QAAQ;4BACd,WAAW,EAAE,mCAAmC;yBACjD;wBACD,IAAI,EAAE;4BACJ,IAAI,EAAE,QAAQ;4BACd,WAAW,EACT,oHAAoH;yBACvH;wBACD,GAAG,EAAE;4BACH,IAAI,EAAE,QAAQ;4BACd,WAAW,EACT,uEAAuE;yBAC1E;wBACD,WAAW,EAAE;4BACX,IAAI,EAAE,QAAQ;4BACd,WAAW,EACT,0FAA0F;yBAC7F;qBACF;o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,MAAM,OAAO,GAAG,KAAK,EAAE,OAAO,IAAI,MAAM,CAAC,KAAK,CAAC,CAAC;QAChD,MAAM,EAAE,KAAK,CAAC,2BAA2B,OAAO,EAAE,CAAC,CAAC;QACpD,OAAO,IAAA,oBAAY,EAAC,IAAI,KAAK,CAAC,2BAA2B,OAAO,EAAE,CAAC,CAAC,CAAC;IACvE,CAAC;AACH,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"handleActivateObject.d.ts","sourceRoot":"","sources":["../../../../src/handlers/common/low/handleActivateObject.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;
|
|
1
|
+
{"version":3,"file":"handleActivateObject.d.ts","sourceRoot":"","sources":["../../../../src/handlers/common/low/handleActivateObject.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AACjE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAIvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiClB,CAAC;AAEX,UAAU,gBAAiB,SAAQ,eAAe;IAChD,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED,UAAU,kBAAkB;IAC1B,OAAO,EAAE,gBAAgB,EAAE,CAAC;IAC5B,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,wBAAsB,oBAAoB,CACxC,OAAO,EAAE,cAAc,EACvB,MAAM,EAAE,kBAAkB;;;;;;GAoG3B"}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.TOOL_DEFINITION = void 0;
|
|
7
7
|
exports.handleActivateObject = handleActivateObject;
|
|
8
|
-
const
|
|
8
|
+
const localGroupActivation_1 = require("../../../lib/localGroupActivation");
|
|
9
9
|
const utils_1 = require("../../../lib/utils");
|
|
10
10
|
exports.TOOL_DEFINITION = {
|
|
11
11
|
name: 'ActivateObjectLow',
|
|
@@ -48,41 +48,44 @@ async function handleActivateObject(context, params) {
|
|
|
48
48
|
return (0, utils_1.return_error)(new Error('Missing required parameter: objects (must be non-empty array)'));
|
|
49
49
|
}
|
|
50
50
|
const preaudit = args.preaudit !== false; // default true
|
|
51
|
-
const client = (0, clients_1.createAdtClient)(connection, logger);
|
|
52
51
|
logger?.info(`Starting activation of ${args.objects.length} object(s)`);
|
|
53
52
|
try {
|
|
54
|
-
|
|
53
|
+
// Route through the local mass-activation helper so an explicit
|
|
54
|
+
// `uri` on the input object is honored (upstream adt-clients
|
|
55
|
+
// v3.10.2 drops it) and so types like PROG/I resolve correctly.
|
|
56
|
+
const inputs = args.objects.map((obj) => ({
|
|
57
|
+
name: obj.name,
|
|
55
58
|
type: obj.type,
|
|
56
|
-
|
|
59
|
+
uri: obj.uri,
|
|
57
60
|
}));
|
|
58
|
-
logger?.debug(`Activating objects: ${
|
|
59
|
-
const
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
logger?.debug(`Activation response status: ${response.status}`);
|
|
63
|
-
const activationResult = (0, utils_1.parseActivationResponse)(response.data);
|
|
64
|
-
const success = activationResult.activated && activationResult.checked;
|
|
61
|
+
logger?.debug(`Activating objects: ${inputs.map((o) => o.name).join(', ')}`);
|
|
62
|
+
const grp = await (0, localGroupActivation_1.activateObjectsLocal)(connection, inputs, {
|
|
63
|
+
preauditRequested: preaudit,
|
|
64
|
+
});
|
|
65
65
|
const result = {
|
|
66
|
-
success,
|
|
67
|
-
objects_count:
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
66
|
+
success: grp.success,
|
|
67
|
+
objects_count: grp.objects.length,
|
|
68
|
+
endpoint: grp.endpoint,
|
|
69
|
+
run_id: grp.run_id,
|
|
70
|
+
objects: grp.objects.map((o) => ({
|
|
71
|
+
name: o.name,
|
|
72
|
+
uri: o.uri,
|
|
73
|
+
type: o.type,
|
|
74
|
+
status: o.status,
|
|
72
75
|
})),
|
|
73
76
|
activation: {
|
|
74
|
-
activated:
|
|
75
|
-
checked:
|
|
76
|
-
generated:
|
|
77
|
+
activated: grp.activated,
|
|
78
|
+
checked: grp.checked,
|
|
79
|
+
generated: grp.generated,
|
|
77
80
|
},
|
|
78
|
-
messages:
|
|
79
|
-
warnings:
|
|
80
|
-
errors:
|
|
81
|
-
message: success
|
|
82
|
-
? `Successfully activated ${
|
|
83
|
-
: `Activation completed with ${
|
|
81
|
+
messages: [...grp.errors, ...grp.warnings],
|
|
82
|
+
warnings: grp.warnings,
|
|
83
|
+
errors: grp.errors,
|
|
84
|
+
message: grp.success
|
|
85
|
+
? `Successfully activated ${grp.objects.length} object(s)`
|
|
86
|
+
: `Activation completed with ${grp.errors.length} error(s) and ${grp.warnings.length} warning(s)`,
|
|
84
87
|
};
|
|
85
|
-
logger?.info(`Activation completed: ${success ? 'SUCCESS' : 'WITH ISSUES'}`);
|
|
88
|
+
logger?.info(`Activation completed: ${grp.success ? 'SUCCESS' : 'WITH ISSUES'}`);
|
|
86
89
|
return (0, utils_1.return_response)({
|
|
87
90
|
data: JSON.stringify(result, null, 2),
|
|
88
91
|
status: 200,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"handleActivateObject.js","sourceRoot":"","sources":["../../../../src/handlers/common/low/handleActivateObject.ts"],"names":[],"mappings":";AAAA;;GAEG;;;
|
|
1
|
+
{"version":3,"file":"handleActivateObject.js","sourceRoot":"","sources":["../../../../src/handlers/common/low/handleActivateObject.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAmDH,oDAsGC;AArJD,4EAAyE;AACzE,8CAAmE;AAEtD,QAAA,eAAe,GAAG;IAC7B,IAAI,EAAE,mBAAmB;IACzB,YAAY,EAAE,CAAC,QAAQ,EAAE,OAAO,EAAE,QAAQ,CAAU;IACpD,WAAW,EACT,qIAAqI;IACvI,WAAW,EAAE;QAC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AAC;iBAAM,CAAC;gBACN,YAAY,GAAG,KAAK,CAAC,OAAO,IAAI,MAAM,CAAC,KAAK,CAAC,CAAC;YAChD,CAAC;YAED,OAAO,IAAA,oBAAY,EACjB,IAAI,KAAK,CAAC,+BAA+B,YAAY,EAAE,CAAC,CACzD,CAAC;QACJ,CAAC;IACH,CAAC;IAAC,OAAO,KAAU,EAAE,CAAC;QACpB,OAAO,IAAA,oBAAY,EAAC,KAAK,CAAC,CAAC;IAC7B,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* PatchGuiStatus — safer alternative to UpdateGuiStatus.
|
|
3
|
+
*
|
|
4
|
+
* Fetches the current active CUA for the program, row-level merges the
|
|
5
|
+
* caller-supplied `changes` into it, and writes the merged result back.
|
|
6
|
+
* Rows and fields the caller didn't touch are preserved verbatim — so
|
|
7
|
+
* sending `{ FUN: [{ CODE: 'BACK', ICON_ID: '@03@' }] }` only updates the
|
|
8
|
+
* BACK function's icon and leaves everything else intact.
|
|
9
|
+
*
|
|
10
|
+
* This is the footgun-proof equivalent of UpdateGuiStatus for targeted
|
|
11
|
+
* edits. UpdateGuiStatus remains available for callers that genuinely
|
|
12
|
+
* need full-replace semantics.
|
|
13
|
+
*/
|
|
14
|
+
import type { HandlerContext } from '../../../lib/handlers/interfaces';
|
|
15
|
+
export declare const TOOL_DEFINITION: {
|
|
16
|
+
readonly name: "PatchGuiStatus";
|
|
17
|
+
readonly available_in: readonly ["onprem", "legacy"];
|
|
18
|
+
readonly description: "Row-level merge into an existing ABAP GUI Status definition. Fetches current CUA → merges the caller-supplied changes (by natural key) → writes merged result back. Rows / fields you omit are preserved. Safer default for targeted edits; use UpdateGuiStatus only when you truly want to replace the whole CUA.\n\nMerge keys per table:\n STA=CODE, FUN=CODE, PFK=CODE+PFNO, BUT=PFK_CODE+CODE+NO, TIT=CODE,\n MEN=CODE+NO, MTX=CODE, ACT=CODE+NO, SET=STATUS+FUNCTION,\n DOC=OBJ_TYPE+OBJ_CODE, BIV=CODE+POS.";
|
|
19
|
+
readonly inputSchema: {
|
|
20
|
+
readonly type: "object";
|
|
21
|
+
readonly properties: {
|
|
22
|
+
readonly program_name: {
|
|
23
|
+
readonly type: "string";
|
|
24
|
+
readonly description: "Parent program name.";
|
|
25
|
+
};
|
|
26
|
+
readonly changes: {
|
|
27
|
+
readonly description: "Partial CUA data to merge into the current definition. Same shape as cua_data (ADM / STA / FUN / MEN / MTX / ACT / BUT / PFK / SET / DOC / TIT / BIV). Accepts JSON string or object. Rows matched by natural key are field-merged (changes win). New rows are appended. Omitted tables are left untouched.";
|
|
28
|
+
readonly oneOf: readonly [{
|
|
29
|
+
readonly type: "string";
|
|
30
|
+
}, {
|
|
31
|
+
readonly type: "object";
|
|
32
|
+
}];
|
|
33
|
+
};
|
|
34
|
+
readonly transport_request: {
|
|
35
|
+
readonly type: "string";
|
|
36
|
+
readonly description: "Transport request number.";
|
|
37
|
+
};
|
|
38
|
+
readonly activate: {
|
|
39
|
+
readonly type: "boolean";
|
|
40
|
+
readonly description: "Activate after patch. Default: false.";
|
|
41
|
+
};
|
|
42
|
+
readonly skip_validation: {
|
|
43
|
+
readonly type: "boolean";
|
|
44
|
+
readonly description: "Skip client-side validation of the merged result. Default: false.";
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
readonly required: readonly ["program_name", "changes"];
|
|
48
|
+
};
|
|
49
|
+
};
|
|
50
|
+
export declare function handlePatchGuiStatus(context: HandlerContext, params: any): Promise<{
|
|
51
|
+
isError: boolean;
|
|
52
|
+
content: {
|
|
53
|
+
type: string;
|
|
54
|
+
text: any;
|
|
55
|
+
}[];
|
|
56
|
+
}>;
|
|
57
|
+
//# sourceMappingURL=handlePatchGuiStatus.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handlePatchGuiStatus.d.ts","sourceRoot":"","sources":["../../../../src/handlers/gui_status/high/handlePatchGuiStatus.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAUH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAcvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiClB,CAAC;AA8BX,wBAAsB,oBAAoB,CACxC,OAAO,EAAE,cAAc,EACvB,MAAM,EAAE,GAAG;;;;;;GA2MZ"}
|
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* PatchGuiStatus — safer alternative to UpdateGuiStatus.
|
|
4
|
+
*
|
|
5
|
+
* Fetches the current active CUA for the program, row-level merges the
|
|
6
|
+
* caller-supplied `changes` into it, and writes the merged result back.
|
|
7
|
+
* Rows and fields the caller didn't touch are preserved verbatim — so
|
|
8
|
+
* sending `{ FUN: [{ CODE: 'BACK', ICON_ID: '@03@' }] }` only updates the
|
|
9
|
+
* BACK function's icon and leaves everything else intact.
|
|
10
|
+
*
|
|
11
|
+
* This is the footgun-proof equivalent of UpdateGuiStatus for targeted
|
|
12
|
+
* edits. UpdateGuiStatus remains available for callers that genuinely
|
|
13
|
+
* need full-replace semantics.
|
|
14
|
+
*/
|
|
15
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
+
exports.TOOL_DEFINITION = void 0;
|
|
17
|
+
exports.handlePatchGuiStatus = handlePatchGuiStatus;
|
|
18
|
+
const fast_xml_parser_1 = require("fast-xml-parser");
|
|
19
|
+
const cuaSchema_1 = require("../../../lib/cuaSchema");
|
|
20
|
+
const rfcBackend_1 = require("../../../lib/rfcBackend");
|
|
21
|
+
const utils_1 = require("../../../lib/utils");
|
|
22
|
+
const ACCEPT_LOCK = 'application/vnd.sap.as+xml;charset=UTF-8;dataname=com.sap.adt.lock.result;q=0.8, application/vnd.sap.as+xml;charset=UTF-8;dataname=com.sap.adt.lock.result2;q=0.9';
|
|
23
|
+
exports.TOOL_DEFINITION = {
|
|
24
|
+
name: 'PatchGuiStatus',
|
|
25
|
+
available_in: ['onprem', 'legacy'],
|
|
26
|
+
description: 'Row-level merge into an existing ABAP GUI Status definition. Fetches current CUA → merges the caller-supplied changes (by natural key) → writes merged result back. Rows / fields you omit are preserved. Safer default for targeted edits; use UpdateGuiStatus only when you truly want to replace the whole CUA.\n\nMerge keys per table:\n STA=CODE, FUN=CODE, PFK=CODE+PFNO, BUT=PFK_CODE+CODE+NO, TIT=CODE,\n MEN=CODE+NO, MTX=CODE, ACT=CODE+NO, SET=STATUS+FUNCTION,\n DOC=OBJ_TYPE+OBJ_CODE, BIV=CODE+POS.',
|
|
27
|
+
inputSchema: {
|
|
28
|
+
type: 'object',
|
|
29
|
+
properties: {
|
|
30
|
+
program_name: {
|
|
31
|
+
type: 'string',
|
|
32
|
+
description: 'Parent program name.',
|
|
33
|
+
},
|
|
34
|
+
changes: {
|
|
35
|
+
description: 'Partial CUA data to merge into the current definition. Same shape as cua_data (ADM / STA / FUN / MEN / MTX / ACT / BUT / PFK / SET / DOC / TIT / BIV). Accepts JSON string or object. Rows matched by natural key are field-merged (changes win). New rows are appended. Omitted tables are left untouched.',
|
|
36
|
+
oneOf: [{ type: 'string' }, { type: 'object' }],
|
|
37
|
+
},
|
|
38
|
+
transport_request: {
|
|
39
|
+
type: 'string',
|
|
40
|
+
description: 'Transport request number.',
|
|
41
|
+
},
|
|
42
|
+
activate: {
|
|
43
|
+
type: 'boolean',
|
|
44
|
+
description: 'Activate after patch. Default: false.',
|
|
45
|
+
},
|
|
46
|
+
skip_validation: {
|
|
47
|
+
type: 'boolean',
|
|
48
|
+
description: 'Skip client-side validation of the merged result. Default: false.',
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
required: ['program_name', 'changes'],
|
|
52
|
+
},
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* Normalize the case of keys in a ReadGuiStatus result so merging works.
|
|
56
|
+
* `ReadGuiStatus` returns `{success, program_name, definition: {ADM, STA, ...}}`
|
|
57
|
+
* where the inner keys are already uppercase (ABAP /ui2/cl_json output), so
|
|
58
|
+
* no extra work needed beyond extracting `definition`.
|
|
59
|
+
*/
|
|
60
|
+
function extractCurrentCua(readResponse) {
|
|
61
|
+
const text = readResponse?.content?.find((c) => c.type === 'text')?.text;
|
|
62
|
+
if (!text)
|
|
63
|
+
throw new Error('ReadGuiStatus returned empty body');
|
|
64
|
+
const parsed = JSON.parse(text);
|
|
65
|
+
if (parsed?.success === false) {
|
|
66
|
+
throw new Error(`ReadGuiStatus reported failure: ${parsed?.message ?? ''}`);
|
|
67
|
+
}
|
|
68
|
+
const def = parsed?.definition;
|
|
69
|
+
if (!def || typeof def !== 'object') {
|
|
70
|
+
throw new Error('ReadGuiStatus response missing "definition"');
|
|
71
|
+
}
|
|
72
|
+
return def;
|
|
73
|
+
}
|
|
74
|
+
async function handlePatchGuiStatus(context, params) {
|
|
75
|
+
const { connection, logger } = context;
|
|
76
|
+
const args = params;
|
|
77
|
+
if (!args.program_name ||
|
|
78
|
+
args.changes === undefined ||
|
|
79
|
+
args.changes === null) {
|
|
80
|
+
return (0, utils_1.return_error)(new Error('Missing required parameters: program_name and changes'));
|
|
81
|
+
}
|
|
82
|
+
if ((0, utils_1.isCloudConnection)()) {
|
|
83
|
+
return (0, utils_1.return_error)(new Error('GUI Statuses are not available on cloud systems (ABAP Cloud).'));
|
|
84
|
+
}
|
|
85
|
+
let changes;
|
|
86
|
+
try {
|
|
87
|
+
changes = (0, cuaSchema_1.normalizeCuaInput)(args.changes);
|
|
88
|
+
}
|
|
89
|
+
catch (e) {
|
|
90
|
+
return (0, utils_1.return_error)(new Error(`Invalid changes: ${e?.message || String(e)}`));
|
|
91
|
+
}
|
|
92
|
+
const programName = args.program_name.toUpperCase();
|
|
93
|
+
const encodedProgram = (0, utils_1.encodeSapObjectName)(programName);
|
|
94
|
+
const programUrl = `/sap/bc/adt/programs/programs/${encodedProgram}`;
|
|
95
|
+
const shouldActivate = args.activate === true;
|
|
96
|
+
logger?.info(`Patching GUI status: ${programName}`);
|
|
97
|
+
let lockHandle;
|
|
98
|
+
const stepsCompleted = [];
|
|
99
|
+
try {
|
|
100
|
+
// 1) Fetch current active CUA
|
|
101
|
+
const fetchResp = await (0, rfcBackend_1.callDispatch)(connection, 'CUA_FETCH', {
|
|
102
|
+
program: programName,
|
|
103
|
+
});
|
|
104
|
+
let current;
|
|
105
|
+
try {
|
|
106
|
+
// callDispatch returns { result, subrc, message }; result is already parsed JSON
|
|
107
|
+
const result = fetchResp?.result;
|
|
108
|
+
if (result && typeof result === 'object') {
|
|
109
|
+
current = result;
|
|
110
|
+
}
|
|
111
|
+
else if (typeof result === 'string') {
|
|
112
|
+
current = (0, cuaSchema_1.normalizeCuaInput)(result);
|
|
113
|
+
}
|
|
114
|
+
else {
|
|
115
|
+
current = {};
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
catch (e) {
|
|
119
|
+
throw new Error(`Failed to parse current CUA for ${programName}: ${e?.message || e}`);
|
|
120
|
+
}
|
|
121
|
+
stepsCompleted.push('fetch_current');
|
|
122
|
+
// 2) Row-level merge
|
|
123
|
+
const merged = (0, cuaSchema_1.mergeCuaData)(current, changes);
|
|
124
|
+
stepsCompleted.push('merge');
|
|
125
|
+
// 3) Validate merged result
|
|
126
|
+
if (args.skip_validation !== true) {
|
|
127
|
+
const problems = (0, cuaSchema_1.validateCuaData)(merged);
|
|
128
|
+
const hard = problems.filter((p) => p.field !== 'PFKCODE' && p.field !== 'PFK_CODE');
|
|
129
|
+
if (hard.length > 0) {
|
|
130
|
+
const summary = hard.map((p) => `- ${p.message}`).join('\n');
|
|
131
|
+
throw new Error(`PatchGuiStatus rejected — merged cua has ${hard.length} validation problem(s). Fix changes (or pass skip_validation=true):\n${summary}`);
|
|
132
|
+
}
|
|
133
|
+
if (problems.length > 0) {
|
|
134
|
+
logger?.warn(`Merged cua has ${problems.length} cross-reference warning(s): ${problems
|
|
135
|
+
.map((p) => p.message)
|
|
136
|
+
.join(' | ')}`);
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
// 4) Lock program
|
|
140
|
+
const lockResponse = await (0, utils_1.makeAdtRequestWithTimeout)(connection, `${programUrl}?_action=LOCK&accessMode=MODIFY`, 'POST', 'default', null, undefined, { Accept: ACCEPT_LOCK });
|
|
141
|
+
const parser = new fast_xml_parser_1.XMLParser({
|
|
142
|
+
ignoreAttributes: false,
|
|
143
|
+
attributeNamePrefix: '',
|
|
144
|
+
});
|
|
145
|
+
const parsed = parser.parse(lockResponse.data || '');
|
|
146
|
+
lockHandle =
|
|
147
|
+
parsed?.['asx:abap']?.['asx:values']?.DATA?.LOCK_HANDLE ||
|
|
148
|
+
lockResponse.headers?.['x-sap-adt-lock-handle'];
|
|
149
|
+
if (!lockHandle) {
|
|
150
|
+
throw new Error(`Failed to obtain lock handle for ${programName}`);
|
|
151
|
+
}
|
|
152
|
+
stepsCompleted.push('lock');
|
|
153
|
+
// 5) Write merged CUA
|
|
154
|
+
await (0, rfcBackend_1.callDispatch)(connection, 'CUA_WRITE', {
|
|
155
|
+
program: programName,
|
|
156
|
+
cua_data: (0, cuaSchema_1.serializeCuaForRfc)(merged),
|
|
157
|
+
});
|
|
158
|
+
stepsCompleted.push('write');
|
|
159
|
+
// 6) Unlock
|
|
160
|
+
await (0, utils_1.makeAdtRequestWithTimeout)(connection, `${programUrl}?_action=UNLOCK&lockHandle=${encodeURIComponent(lockHandle)}`, 'POST', 'default');
|
|
161
|
+
lockHandle = undefined;
|
|
162
|
+
stepsCompleted.push('unlock');
|
|
163
|
+
// 7) Optional activate
|
|
164
|
+
if (shouldActivate) {
|
|
165
|
+
const activationXml = `<?xml version="1.0" encoding="utf-8"?><adtcore:objectReferences xmlns:adtcore="http://www.sap.com/adt/core"><adtcore:objectReference adtcore:uri="${programUrl}" adtcore:name="${programName}"/></adtcore:objectReferences>`;
|
|
166
|
+
await (0, utils_1.makeAdtRequestWithTimeout)(connection, '/sap/bc/adt/activation', 'POST', 'long', activationXml, { method: 'activate', preauditRequested: 'true' }, {
|
|
167
|
+
'Content-Type': 'application/vnd.sap.adt.activation.request+xml; charset=utf-8',
|
|
168
|
+
});
|
|
169
|
+
stepsCompleted.push('activate');
|
|
170
|
+
}
|
|
171
|
+
logger?.info(`✅ GUI status patched: ${programName}`);
|
|
172
|
+
const countRows = (arr) => Array.isArray(arr) ? arr.length : 0;
|
|
173
|
+
return (0, utils_1.return_response)({
|
|
174
|
+
data: JSON.stringify({
|
|
175
|
+
success: true,
|
|
176
|
+
program_name: programName,
|
|
177
|
+
type: 'CUAD',
|
|
178
|
+
activated: shouldActivate,
|
|
179
|
+
steps_completed: stepsCompleted,
|
|
180
|
+
summary: {
|
|
181
|
+
sta: countRows(merged.STA),
|
|
182
|
+
fun: countRows(merged.FUN),
|
|
183
|
+
pfk: countRows(merged.PFK),
|
|
184
|
+
but: countRows(merged.BUT),
|
|
185
|
+
tit: countRows(merged.TIT),
|
|
186
|
+
men: countRows(merged.MEN),
|
|
187
|
+
mtx: countRows(merged.MTX),
|
|
188
|
+
act: countRows(merged.ACT),
|
|
189
|
+
set: countRows(merged.SET),
|
|
190
|
+
doc: countRows(merged.DOC),
|
|
191
|
+
},
|
|
192
|
+
message: shouldActivate
|
|
193
|
+
? `GUI Status for ${programName} patched and activated.`
|
|
194
|
+
: `GUI Status for ${programName} patched (not activated).`,
|
|
195
|
+
}, null, 2),
|
|
196
|
+
status: 200,
|
|
197
|
+
statusText: 'OK',
|
|
198
|
+
headers: {},
|
|
199
|
+
config: {},
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
catch (error) {
|
|
203
|
+
if (lockHandle) {
|
|
204
|
+
try {
|
|
205
|
+
await (0, utils_1.makeAdtRequestWithTimeout)(connection, `${programUrl}?_action=UNLOCK&lockHandle=${encodeURIComponent(lockHandle)}`, 'POST', 'default');
|
|
206
|
+
}
|
|
207
|
+
catch {
|
|
208
|
+
/* ignore unlock error */
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
const errorMessage = error instanceof Error ? error.message : String(error);
|
|
212
|
+
logger?.error(`Error patching GUI status: ${errorMessage}`);
|
|
213
|
+
return (0, utils_1.return_error)(new Error(`Failed to patch GUI status: ${errorMessage}`));
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
//# sourceMappingURL=handlePatchGuiStatus.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handlePatchGuiStatus.js","sourceRoot":"","sources":["../../../../src/handlers/gui_status/high/handlePatchGuiStatus.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;GAYG;;;AAuFH,oDA6MC;AAlSD,qDAA4C;AAC5C,sDAMgC;AAEhC,wDAAuD;AACvD,8CAO4B;AAE5B,MAAM,WAAW,GACf,mKAAmK,CAAC;AAEzJ,QAAA,eAAe,GAAG;IAC7B,IAAI,EAAE,gBAAgB;IACtB,YAAY,EAAE,CAAC,QAAQ,EAAE,QAAQ,CAAU;IAC3C,WAAW,EACT,ufAAuf;IACzf,WAAW,EAAE;QACX,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE;YACV,YAAY,EAAE;gBACZ,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,sBAAsB;aACpC;YACD,OAAO,EAAE;gBACP,WAAW,EACT,6SAA6S;gBAC/S,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,CAAC;aAChD;YACD,iBAAiB,EAAE;gBACjB,IAAI,EAAE,QAAQ;gBACd,WAAW,EAAE,2BAA2B;aACzC;YACD,QAAQ,EAAE;gBACR,IAAI,EAAE,SAAS;gBACf,WAAW,EAAE,uCAAuC;aACrD;YACD,eAAe,EAAE;gBACf,IAAI,EAAE,SAAS;gBACf,WAAW,EACT,mEAAmE;aACtE;SACF;QACD,QAAQ,EAAE,CAAC,cAAc,EAAE,SAAS,CAAC;KACtC;CACO,CAAC;AAUX;;;;;GAKG;AACH,SAAS,iBAAiB,CAA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