@rage-against-the-pixel/unity-cli 1.8.0 → 1.8.2

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.
@@ -0,0 +1,153 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.Severity = exports.Phase = exports.UTPPlayerBuildInfo = exports.UTPTestStatus = exports.UTPQualitySettings = exports.UTPPlayerSystemInfo = exports.UTPBuildSettings = exports.UTPPlayerSettings = exports.UTPScreenSettings = exports.UTPTestPlan = exports.UTPLogEntry = exports.UTPMemoryLeak = exports.UTPBase = void 0;
4
+ exports.normalizeTelemetryEntry = normalizeTelemetryEntry;
5
+ const logging_1 = require("../logging");
6
+ class UTPBase {
7
+ type;
8
+ version;
9
+ phase;
10
+ time;
11
+ processId;
12
+ severity;
13
+ message;
14
+ stackTrace;
15
+ line;
16
+ lineNumber;
17
+ file;
18
+ fileName;
19
+ name;
20
+ description;
21
+ duration;
22
+ durationMicroseconds;
23
+ errors;
24
+ }
25
+ exports.UTPBase = UTPBase;
26
+ class UTPMemoryLeak extends UTPBase {
27
+ allocatedMemory;
28
+ memoryLabels;
29
+ }
30
+ exports.UTPMemoryLeak = UTPMemoryLeak;
31
+ class UTPLogEntry extends UTPBase {
32
+ }
33
+ exports.UTPLogEntry = UTPLogEntry;
34
+ class UTPTestPlan extends UTPBase {
35
+ tests;
36
+ }
37
+ exports.UTPTestPlan = UTPTestPlan;
38
+ class UTPScreenSettings extends UTPBase {
39
+ ScreenSettings;
40
+ }
41
+ exports.UTPScreenSettings = UTPScreenSettings;
42
+ class UTPPlayerSettings extends UTPBase {
43
+ PlayerSettings;
44
+ }
45
+ exports.UTPPlayerSettings = UTPPlayerSettings;
46
+ class UTPBuildSettings extends UTPBase {
47
+ BuildSettings;
48
+ }
49
+ exports.UTPBuildSettings = UTPBuildSettings;
50
+ class UTPPlayerSystemInfo extends UTPBase {
51
+ PlayerSystemInfo;
52
+ }
53
+ exports.UTPPlayerSystemInfo = UTPPlayerSystemInfo;
54
+ class UTPQualitySettings extends UTPBase {
55
+ QualitySettings;
56
+ }
57
+ exports.UTPQualitySettings = UTPQualitySettings;
58
+ class UTPTestStatus extends UTPBase {
59
+ state;
60
+ iteration;
61
+ }
62
+ exports.UTPTestStatus = UTPTestStatus;
63
+ class UTPPlayerBuildInfo extends UTPBase {
64
+ steps;
65
+ }
66
+ exports.UTPPlayerBuildInfo = UTPPlayerBuildInfo;
67
+ var Phase;
68
+ (function (Phase) {
69
+ Phase["Begin"] = "Begin";
70
+ Phase["End"] = "End";
71
+ Phase["Immediate"] = "Immediate";
72
+ })(Phase || (exports.Phase = Phase = {}));
73
+ var Severity;
74
+ (function (Severity) {
75
+ Severity["Info"] = "Info";
76
+ Severity["Warning"] = "Warning";
77
+ Severity["Error"] = "Error";
78
+ Severity["Exception"] = "Exception";
79
+ Severity["Assert"] = "Assert";
80
+ })(Severity || (exports.Severity = Severity = {}));
81
+ const allowedUtpKeys = new Set([
82
+ 'allocatedMemory',
83
+ 'BuildSettings',
84
+ 'description',
85
+ 'duration',
86
+ 'durationMicroseconds',
87
+ 'errors',
88
+ 'file',
89
+ 'fileName',
90
+ 'iteration',
91
+ 'line',
92
+ 'lineNumber',
93
+ 'memoryLabels',
94
+ 'message',
95
+ 'name',
96
+ 'phase',
97
+ 'PlayerSettings',
98
+ 'PlayerSystemInfo',
99
+ 'processId',
100
+ 'QualitySettings',
101
+ 'ScreenSettings',
102
+ 'severity',
103
+ 'stacktrace',
104
+ 'stackTrace',
105
+ 'state',
106
+ 'steps',
107
+ 'tests',
108
+ 'time',
109
+ 'type',
110
+ 'version',
111
+ ]);
112
+ /**
113
+ * Normalizes UTP telemetry entries to canonical shapes and reports unexpected properties.
114
+ */
115
+ function normalizeTelemetryEntry(entry) {
116
+ if (!entry || typeof entry !== 'object') {
117
+ return entry;
118
+ }
119
+ const utp = entry;
120
+ const record = entry;
121
+ const stackTraceLegacy = record.stacktrace;
122
+ if (utp.stackTrace === undefined && typeof stackTraceLegacy === 'string') {
123
+ utp.stackTrace = stackTraceLegacy;
124
+ }
125
+ const fileNameLegacy = record.fileName;
126
+ if (utp.file === undefined && typeof fileNameLegacy === 'string') {
127
+ utp.file = fileNameLegacy;
128
+ }
129
+ if (utp.fileName === undefined && typeof utp.file === 'string') {
130
+ utp.fileName = utp.file;
131
+ }
132
+ const lineNumberLegacy = record.lineNumber;
133
+ if (utp.line === undefined && typeof lineNumberLegacy === 'number') {
134
+ utp.line = lineNumberLegacy;
135
+ }
136
+ if (utp.lineNumber === undefined && typeof utp.line === 'number') {
137
+ utp.lineNumber = utp.line;
138
+ }
139
+ if (!utp.type) {
140
+ logging_1.Logger.instance.warn('UTP entry missing type property; telemetry entry may be ignored.');
141
+ }
142
+ const extras = [];
143
+ for (const key of Object.keys(record)) {
144
+ if (!allowedUtpKeys.has(key)) {
145
+ extras.push(key);
146
+ }
147
+ }
148
+ if (extras.length > 0) {
149
+ logging_1.Logger.instance.warn(`UTP entry contains unrecognized properties: ${extras.join(', ')}`);
150
+ }
151
+ return utp;
152
+ }
153
+ //# sourceMappingURL=utp.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utp.js","sourceRoot":"","sources":["../../src/utp/utp.ts"],"names":[],"mappings":";;;AAoLA,0DAkDC;AAtOD,wCAAoC;AAEpC,MAAa,OAAO;IAChB,IAAI,CAAU;IACd,OAAO,CAAU;IACjB,KAAK,CAAS;IACd,IAAI,CAAU;IACd,SAAS,CAAU;IACnB,QAAQ,CAAY;IACpB,OAAO,CAAU;IACjB,UAAU,CAAU;IACpB,IAAI,CAAU;IACd,UAAU,CAAU;IACpB,IAAI,CAAU;IACd,QAAQ,CAAU;IAClB,IAAI,CAAU;IACd,WAAW,CAAU;IACrB,QAAQ,CAAU;IAClB,oBAAoB,CAAU;IAC9B,MAAM,CAAa;CACtB;AAlBD,0BAkBC;AAED,MAAa,aAAc,SAAQ,OAAO;IACtC,eAAe,CAAU;IACzB,YAAY,C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GAAG,CAAC,UAAU,GAAG,GAAG,CAAC,IAAI,CAAC;IAC9B,CAAC;IAED,IAAI,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC;QACZ,gBAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,kEAAkE,CAAC,CAAC;IAC7F,CAAC;IAED,MAAM,MAAM,GAAa,EAAE,CAAC;IAC5B,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC;QACpC,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC;YAC3B,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;QACrB,CAAC;IACL,CAAC;IAED,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACpB,gBAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,+CAA+C,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IAC7F,CAAC;IAED,OAAO,GAAG,CAAC;AACf,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rage-against-the-pixel/unity-cli",
3
- "version": "1.8.0",
3
+ "version": "1.8.2",
4
4
  "description": "A command line utility for the Unity Game Engine.",
5
5
  "author": "RageAgainstThePixel",
6
6
  "license": "MIT",
@@ -50,17 +50,17 @@
50
50
  "dependencies": {
51
51
  "@electron/asar": "^4.0.1",
52
52
  "@rage-against-the-pixel/unity-releases-api": "^1.0.4",
53
- "commander": "^14.0.2",
53
+ "commander": "^14.0.3",
54
54
  "glob": "^11.1.0",
55
- "semver": "^7.7.3",
55
+ "semver": "^7.7.4",
56
56
  "source-map-support": "^0.5.21",
57
- "tar": "^7.5.2",
57
+ "tar": "^7.5.7",
58
58
  "update-notifier": "^7.3.1",
59
59
  "yaml": "^2.8.2"
60
60
  },
61
61
  "devDependencies": {
62
62
  "@types/jest": "^30.0.0",
63
- "@types/node": "^24.10.1",
63
+ "@types/node": "^24.10.12",
64
64
  "@types/semver": "^7.7.1",
65
65
  "@types/update-notifier": "^6.0.8",
66
66
  "jest": "^30.2.0",
@@ -68,4 +68,4 @@
68
68
  "ts-node": "^10.9.2",
69
69
  "typescript": "^5.9.3"
70
70
  }
71
- }
71
+ }
package/dist/utp.d.ts DELETED
@@ -1,41 +0,0 @@
1
- export declare class UTPBase {
2
- type?: string;
3
- version?: number;
4
- phase?: Phase;
5
- time?: number;
6
- processId?: number;
7
- severity?: Severity;
8
- message?: string;
9
- stacktrace?: string;
10
- line?: number;
11
- file?: string;
12
- name?: string;
13
- description?: string;
14
- duration?: number;
15
- errors?: unknown[];
16
- }
17
- export declare class UTPMemoryLeak extends UTPBase {
18
- allocatedMemory?: number;
19
- memoryLabels?: Record<string, number> | Array<Record<string, number>>;
20
- }
21
- export interface PlayerBuildInfoStep {
22
- description?: string;
23
- duration?: number;
24
- errors?: number;
25
- }
26
- export declare class UTPPlayerBuildInfo extends UTPBase {
27
- steps?: PlayerBuildInfoStep[];
28
- }
29
- export type UTP = UTPBase | UTPMemoryLeak | UTPPlayerBuildInfo;
30
- export declare enum Phase {
31
- Begin = "Begin",
32
- End = "End",
33
- Immediate = "Immediate"
34
- }
35
- export declare enum Severity {
36
- Info = "Info",
37
- Warning = "Warning",
38
- Error = "Error",
39
- Exception = "Exception",
40
- Assert = "Assert"
41
- }
package/dist/utp.js DELETED
@@ -1,44 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.Severity = exports.Phase = exports.UTPPlayerBuildInfo = exports.UTPMemoryLeak = exports.UTPBase = void 0;
4
- class UTPBase {
5
- type;
6
- version;
7
- phase;
8
- time;
9
- processId;
10
- severity;
11
- message;
12
- stacktrace;
13
- line;
14
- file;
15
- name;
16
- description;
17
- duration;
18
- errors;
19
- }
20
- exports.UTPBase = UTPBase;
21
- class UTPMemoryLeak extends UTPBase {
22
- allocatedMemory;
23
- memoryLabels;
24
- }
25
- exports.UTPMemoryLeak = UTPMemoryLeak;
26
- class UTPPlayerBuildInfo extends UTPBase {
27
- steps;
28
- }
29
- exports.UTPPlayerBuildInfo = UTPPlayerBuildInfo;
30
- var Phase;
31
- (function (Phase) {
32
- Phase["Begin"] = "Begin";
33
- Phase["End"] = "End";
34
- Phase["Immediate"] = "Immediate";
35
- })(Phase || (exports.Phase = Phase = {}));
36
- var Severity;
37
- (function (Severity) {
38
- Severity["Info"] = "Info";
39
- Severity["Warning"] = "Warning";
40
- Severity["Error"] = "Error";
41
- Severity["Exception"] = "Exception";
42
- Severity["Assert"] = "Assert";
43
- })(Severity || (exports.Severity = Severity = {}));
44
- //# sourceMappingURL=utp.js.map
package/dist/utp.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"utp.js","sourceRoot":"","sources":["../src/utp.ts"],"names":[],"mappings":";;;AAAA,MAAa,OAAO;IAChB,IAAI,CAAU;IACd,OAAO,CAAU;IACjB,KAAK,CAAS;IACd,IAAI,CAAU;IACd,SAAS,CAAU;IACnB,QAAQ,CAAY;IACpB,OAAO,CAAU;IACjB,UAAU,CAAU;IACpB,IAAI,CAAU;IACd,IAAI,CAAU;IACd,IAAI,CAAU;IACd,WAAW,CAAU;IACrB,QAAQ,CAAU;IAClB,MAAM,CAAa;CACtB;AAfD,0BAeC;AAED,MAAa,aAAc,SAAQ,OAAO;IACtC,eAAe,CAAU;IACzB,YAAY,CAA0D;CACzE;AAHD,sCAGC;AAQD,MAAa,kBAAmB,SAAQ,OAAO;IAC3C,KAAK,CAAyB;CACjC;AAFD,gDAEC;AAID,IAAY,KAIX;AAJD,WAAY,KAAK;IACb,wBAAe,CAAA;IACf,oBAAW,CAAA;IACX,gCAAuB,CAAA;AAC3B,CAAC,EAJW,KAAK,qBAAL,KAAK,QAIhB;AAED,IAAY,QAMX;AAND,WAAY,QAAQ;IAChB,yBAAa,CAAA;IACb,+BAAmB,CAAA;IACnB,2BAAe,CAAA;IACf,mCAAuB,CAAA;IACvB,6BAAiB,CAAA;AACrB,CAAC,EANW,QAAQ,wBAAR,QAAQ,QAMnB"}