@teambit/typescript 0.0.880 → 0.0.882
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/cmds/check-types.cmd.js +0 -21
- package/dist/cmds/check-types.cmd.js.map +1 -1
- package/dist/cmds/write-tsconfig.cmd.js +2 -25
- package/dist/cmds/write-tsconfig.cmd.js.map +1 -1
- package/dist/dedupe-path.spec.js +6 -8
- package/dist/dedupe-path.spec.js.map +1 -1
- package/dist/exceptions/index.js +0 -3
- package/dist/exceptions/index.js.map +1 -1
- package/dist/exceptions/transformer-not-found.js +0 -7
- package/dist/exceptions/transformer-not-found.js.map +1 -1
- package/dist/export-identifier.js +0 -3
- package/dist/export-identifier.js.map +1 -1
- package/dist/export-list.js +0 -4
- package/dist/export-list.js.map +1 -1
- package/dist/index.js +0 -9
- package/dist/index.js.map +1 -1
- package/dist/schema-extractor-context.js +16 -120
- package/dist/schema-extractor-context.js.map +1 -1
- package/dist/schema-transformer.plugin.js +0 -8
- package/dist/schema-transformer.plugin.js.map +1 -1
- package/dist/transformers/binding-element.js +0 -23
- package/dist/transformers/binding-element.js.map +1 -1
- package/dist/transformers/class-deceleration.js +2 -34
- package/dist/transformers/class-deceleration.js.map +1 -1
- package/dist/transformers/enum-declaration.js +0 -16
- package/dist/transformers/enum-declaration.js.map +1 -1
- package/dist/transformers/export-declaration.js +8 -47
- package/dist/transformers/export-declaration.js.map +1 -1
- package/dist/transformers/function-declaration.js +2 -19
- package/dist/transformers/function-declaration.js.map +1 -1
- package/dist/transformers/index.js +0 -30
- package/dist/transformers/index.js.map +1 -1
- package/dist/transformers/interface-declaration.js +0 -25
- package/dist/transformers/interface-declaration.js.map +1 -1
- package/dist/transformers/source-file-transformer.js +3 -24
- package/dist/transformers/source-file-transformer.js.map +1 -1
- package/dist/transformers/type-alias.js +0 -23
- package/dist/transformers/type-alias.js.map +1 -1
- package/dist/transformers/utils/class-element-to-schema.js +0 -35
- package/dist/transformers/utils/class-element-to-schema.js.map +1 -1
- package/dist/transformers/utils/get-params.js +6 -33
- package/dist/transformers/utils/get-params.js.map +1 -1
- package/dist/transformers/utils/jsdoc-to-doc-schema.js +4 -49
- package/dist/transformers/utils/jsdoc-to-doc-schema.js.map +1 -1
- package/dist/transformers/utils/parse-type-from-quick-info.js +4 -16
- package/dist/transformers/utils/parse-type-from-quick-info.js.map +1 -1
- package/dist/transformers/utils/to-function-like-schema.js +0 -15
- package/dist/transformers/utils/to-function-like-schema.js.map +1 -1
- package/dist/transformers/utils/type-element-to-schema.js +0 -37
- package/dist/transformers/utils/type-element-to-schema.js.map +1 -1
- package/dist/transformers/utils/type-node-to-schema.js +5 -71
- package/dist/transformers/utils/type-node-to-schema.js.map +1 -1
- package/dist/transformers/variable-declaration.js +0 -30
- package/dist/transformers/variable-declaration.js.map +1 -1
- package/dist/transformers/variable-statement.js +0 -22
- package/dist/transformers/variable-statement.js.map +1 -1
- package/dist/tsconfig-writer.js +8 -58
- package/dist/tsconfig-writer.js.map +1 -1
- package/dist/typescript.aspect.js +0 -5
- package/dist/typescript.aspect.js.map +1 -1
- package/dist/typescript.compiler.js +16 -83
- package/dist/typescript.compiler.js.map +1 -1
- package/dist/typescript.compiler.spec.js +0 -25
- package/dist/typescript.compiler.spec.js.map +1 -1
- package/dist/typescript.composition.js +0 -6
- package/dist/typescript.composition.js.map +1 -1
- package/dist/typescript.extractor.js +6 -50
- package/dist/typescript.extractor.js.map +1 -1
- package/dist/typescript.main.runtime.js +10 -114
- package/dist/typescript.main.runtime.js.map +1 -1
- package/dist/typescript.parser.js +3 -30
- package/dist/typescript.parser.js.map +1 -1
- package/dist/typescript.parser.spec.js +0 -22
- package/dist/typescript.parser.spec.js.map +1 -1
- package/package-tar/teambit-typescript-0.0.882.tgz +0 -0
- package/package.json +15 -15
- package/{preview-1666312873430.js → preview-1666496165706.js} +2 -2
- package/package-tar/teambit-typescript-0.0.880.tgz +0 -0
|
@@ -1,86 +1,61 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
|
|
5
4
|
require("core-js/modules/es.array.iterator.js");
|
|
6
|
-
|
|
7
5
|
require("core-js/modules/es.promise.js");
|
|
8
|
-
|
|
9
6
|
Object.defineProperty(exports, "__esModule", {
|
|
10
7
|
value: true
|
|
11
8
|
});
|
|
12
9
|
exports.TypeScriptExtractor = void 0;
|
|
13
|
-
|
|
14
10
|
function _defineProperty2() {
|
|
15
11
|
const data = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
16
|
-
|
|
17
12
|
_defineProperty2 = function () {
|
|
18
13
|
return data;
|
|
19
14
|
};
|
|
20
|
-
|
|
21
15
|
return data;
|
|
22
16
|
}
|
|
23
|
-
|
|
24
17
|
function _typescript() {
|
|
25
18
|
const data = _interopRequireDefault(require("typescript"));
|
|
26
|
-
|
|
27
19
|
_typescript = function () {
|
|
28
20
|
return data;
|
|
29
21
|
};
|
|
30
|
-
|
|
31
22
|
return data;
|
|
32
23
|
}
|
|
33
|
-
|
|
34
24
|
function _semanticsEntities() {
|
|
35
25
|
const data = require("@teambit/semantics.entities.semantic-schema");
|
|
36
|
-
|
|
37
26
|
_semanticsEntities = function () {
|
|
38
27
|
return data;
|
|
39
28
|
};
|
|
40
|
-
|
|
41
29
|
return data;
|
|
42
30
|
}
|
|
43
|
-
|
|
44
31
|
function _lodash() {
|
|
45
32
|
const data = require("lodash");
|
|
46
|
-
|
|
47
33
|
_lodash = function () {
|
|
48
34
|
return data;
|
|
49
35
|
};
|
|
50
|
-
|
|
51
36
|
return data;
|
|
52
37
|
}
|
|
53
|
-
|
|
54
38
|
function _exceptions() {
|
|
55
39
|
const data = require("./exceptions");
|
|
56
|
-
|
|
57
40
|
_exceptions = function () {
|
|
58
41
|
return data;
|
|
59
42
|
};
|
|
60
|
-
|
|
61
43
|
return data;
|
|
62
44
|
}
|
|
63
|
-
|
|
64
45
|
function _schemaExtractorContext() {
|
|
65
46
|
const data = require("./schema-extractor-context");
|
|
66
|
-
|
|
67
47
|
_schemaExtractorContext = function () {
|
|
68
48
|
return data;
|
|
69
49
|
};
|
|
70
|
-
|
|
71
50
|
return data;
|
|
72
51
|
}
|
|
73
|
-
|
|
74
52
|
function _exportList() {
|
|
75
53
|
const data = require("./export-list");
|
|
76
|
-
|
|
77
54
|
_exportList = function () {
|
|
78
55
|
return data;
|
|
79
56
|
};
|
|
80
|
-
|
|
81
57
|
return data;
|
|
82
58
|
}
|
|
83
|
-
|
|
84
59
|
class TypeScriptExtractor {
|
|
85
60
|
constructor(tsconfig, schemaTransformerSlot, tsMain, rootPath, depResolver, workspace) {
|
|
86
61
|
this.tsconfig = tsconfig;
|
|
@@ -91,21 +66,17 @@ class TypeScriptExtractor {
|
|
|
91
66
|
this.workspace = workspace;
|
|
92
67
|
(0, _defineProperty2().default)(this, "tsserver", undefined);
|
|
93
68
|
}
|
|
94
|
-
|
|
95
69
|
parseSourceFile(file) {
|
|
96
70
|
const sourceFile = _typescript().default.createSourceFile(file.path, file.contents.toString('utf8'), _typescript().default.ScriptTarget.Latest, true
|
|
97
|
-
/** don't pass the scriptKind, it'll be determined automatically by typescript by the filepath */
|
|
98
|
-
|
|
71
|
+
/** don't pass the scriptKind, it'll be determined automatically by typescript by the filepath */);
|
|
72
|
+
// leave this commented out, it's helpful when there are issues with ASTs. consider throwing in this case.
|
|
99
73
|
// console.log("sourceFile Errors", file.path, sourceFile.parseDiagnostics);
|
|
100
|
-
|
|
101
|
-
|
|
102
74
|
return sourceFile;
|
|
103
75
|
}
|
|
76
|
+
|
|
104
77
|
/**
|
|
105
78
|
* extract a component schema.
|
|
106
79
|
*/
|
|
107
|
-
|
|
108
|
-
|
|
109
80
|
async extract(component) {
|
|
110
81
|
const tsserver = await this.getTsServer();
|
|
111
82
|
const mainFile = component.mainFile;
|
|
@@ -119,72 +90,57 @@ class TypeScriptExtractor {
|
|
|
119
90
|
const location = context.getLocation(mainAst);
|
|
120
91
|
return new (_semanticsEntities().APISchema)(location, apiScheme, component.id);
|
|
121
92
|
}
|
|
122
|
-
|
|
123
93
|
async computeExportedIdentifiers(node, context) {
|
|
124
94
|
const transformer = this.getTransformer(node, context);
|
|
125
|
-
|
|
126
95
|
if (!transformer || !transformer.getIdentifiers) {
|
|
127
96
|
throw new (_exceptions().TransformerNotFound)(node, context.component, context.getLocation(node));
|
|
128
97
|
}
|
|
129
|
-
|
|
130
98
|
return transformer.getIdentifiers(node, context);
|
|
131
99
|
}
|
|
132
|
-
|
|
133
100
|
async createContext(tsserver, component) {
|
|
134
101
|
const componentDeps = await this.getComponentDeps(component);
|
|
135
102
|
return new (_schemaExtractorContext().SchemaExtractorContext)(tsserver, component, this, componentDeps);
|
|
136
103
|
}
|
|
137
|
-
|
|
138
104
|
async getComponentDeps(component) {
|
|
139
105
|
const deps = await this.depResolver.getDependencies(component);
|
|
140
106
|
const componentDeps = deps.getComponentDependencies();
|
|
141
107
|
return componentDeps;
|
|
142
108
|
}
|
|
143
|
-
|
|
144
109
|
async getTsServer() {
|
|
145
110
|
if (!this.tsserver) {
|
|
146
111
|
const tsserver = this.tsMain.getTsserverClient();
|
|
147
|
-
|
|
148
112
|
if (tsserver) {
|
|
149
113
|
this.tsserver = tsserver;
|
|
150
114
|
return tsserver;
|
|
151
115
|
}
|
|
152
|
-
|
|
153
116
|
this.tsserver = await this.tsMain.initTsserverClient(this.rootPath);
|
|
154
117
|
return this.tsserver;
|
|
155
118
|
}
|
|
156
|
-
|
|
157
119
|
return this.tsserver;
|
|
158
120
|
}
|
|
159
|
-
|
|
160
121
|
async computeSchema(node, context) {
|
|
161
|
-
const transformer = this.getTransformer(node, context);
|
|
122
|
+
const transformer = this.getTransformer(node, context);
|
|
123
|
+
// leave the next line commented out, it is used for debugging
|
|
162
124
|
// console.log('transformer', transformer.constructor.name, node.getText());
|
|
163
|
-
|
|
164
125
|
return transformer.transform(node, context);
|
|
165
126
|
}
|
|
166
|
-
|
|
167
127
|
async getComponentIDByPath(file) {
|
|
168
128
|
if (!this.workspace) {
|
|
169
129
|
return null;
|
|
170
130
|
}
|
|
171
|
-
|
|
172
131
|
return this.workspace.getComponentIdByPath(file);
|
|
173
132
|
}
|
|
133
|
+
|
|
174
134
|
/**
|
|
175
135
|
* select the correct transformer for a node.
|
|
176
136
|
*/
|
|
177
|
-
|
|
178
|
-
|
|
179
137
|
getTransformer(node, context) {
|
|
180
138
|
const transformers = (0, _lodash().flatten)(this.schemaTransformerSlot.values());
|
|
181
139
|
const transformer = transformers.find(singleTransformer => singleTransformer.predicate(node));
|
|
182
140
|
if (!transformer) throw new (_exceptions().TransformerNotFound)(node, context.component, context.getLocation(node));
|
|
183
141
|
return transformer;
|
|
184
142
|
}
|
|
185
|
-
|
|
186
143
|
}
|
|
187
|
-
|
|
188
144
|
exports.TypeScriptExtractor = TypeScriptExtractor;
|
|
189
145
|
|
|
190
146
|
//# sourceMappingURL=typescript.extractor.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["TypeScriptExtractor","constructor","tsconfig","schemaTransformerSlot","tsMain","rootPath","depResolver","workspace","undefined","parseSourceFile","file","sourceFile","ts","createSourceFile","path","contents","toString","ScriptTarget","Latest","extract","component","tsserver","getTsServer","mainFile","mainAst","context","createContext","exportNames","computeExportedIdentifiers","setExports","ExportList","moduleSchema","computeSchema","flatExportsRecursively","apiScheme","location","getLocation","APISchema","id","node","transformer","getTransformer","getIdentifiers","TransformerNotFound","componentDeps","getComponentDeps","SchemaExtractorContext","deps","getDependencies","getComponentDependencies","getTsserverClient","initTsserverClient","transform","getComponentIDByPath","getComponentIdByPath","transformers","flatten","values","find","singleTransformer","predicate"],"sources":["typescript.extractor.ts"],"sourcesContent":["import ts, { Node, SourceFile } from 'typescript';\nimport { SchemaExtractor } from '@teambit/schema';\nimport { TsserverClient } from '@teambit/ts-server';\nimport type { Workspace } from '@teambit/workspace';\nimport { ComponentDependency, DependencyResolverMain } from '@teambit/dependency-resolver';\nimport { SchemaNode, APISchema, Module } from '@teambit/semantics.entities.semantic-schema';\nimport { Component } from '@teambit/component';\nimport { AbstractVinyl } from '@teambit/legacy/dist/consumer/component/sources';\nimport { flatten } from 'lodash';\nimport { TypescriptMain, SchemaTransformerSlot } from './typescript.main.runtime';\nimport { TransformerNotFound } from './exceptions';\nimport { SchemaExtractorContext } from './schema-extractor-context';\nimport { ExportList } from './export-list';\n\nexport class TypeScriptExtractor implements SchemaExtractor {\n constructor(\n private tsconfig: any,\n private schemaTransformerSlot: SchemaTransformerSlot,\n private tsMain: TypescriptMain,\n private rootPath: string,\n private depResolver: DependencyResolverMain,\n private workspace: Workspace | undefined\n ) {}\n\n parseSourceFile(file: AbstractVinyl): SourceFile {\n const sourceFile = ts.createSourceFile(\n file.path,\n file.contents.toString('utf8'),\n ts.ScriptTarget.Latest,\n true\n /** don't pass the scriptKind, it'll be determined automatically by typescript by the filepath */\n );\n // leave this commented out, it's helpful when there are issues with ASTs. consider throwing in this case.\n // console.log(\"sourceFile Errors\", file.path, sourceFile.parseDiagnostics);\n return sourceFile;\n }\n\n /**\n * extract a component schema.\n */\n async extract(component: Component): Promise<APISchema> {\n const tsserver = await this.getTsServer();\n const mainFile = component.mainFile;\n const mainAst = this.parseSourceFile(mainFile);\n const context = await this.createContext(tsserver, component);\n const exportNames = await this.computeExportedIdentifiers(mainAst, context);\n context.setExports(new ExportList(exportNames));\n const moduleSchema = (await this.computeSchema(mainAst, context)) as Module;\n moduleSchema.flatExportsRecursively();\n const apiScheme = moduleSchema;\n const location = context.getLocation(mainAst);\n\n return new APISchema(location, apiScheme, component.id);\n }\n\n async computeExportedIdentifiers(node: Node, context: SchemaExtractorContext) {\n const transformer = this.getTransformer(node, context);\n if (!transformer || !transformer.getIdentifiers) {\n throw new TransformerNotFound(node, context.component, context.getLocation(node));\n }\n return transformer.getIdentifiers(node, context);\n }\n\n private async createContext(tsserver: TsserverClient, component: Component): Promise<SchemaExtractorContext> {\n const componentDeps = await this.getComponentDeps(component);\n return new SchemaExtractorContext(tsserver, component, this, componentDeps);\n }\n\n private async getComponentDeps(component: Component): Promise<ComponentDependency[]> {\n const deps = await this.depResolver.getDependencies(component);\n const componentDeps = deps.getComponentDependencies();\n return componentDeps;\n }\n\n private tsserver: TsserverClient | undefined = undefined;\n\n private async getTsServer() {\n if (!this.tsserver) {\n const tsserver = this.tsMain.getTsserverClient();\n if (tsserver) {\n this.tsserver = tsserver;\n return tsserver;\n }\n\n this.tsserver = await this.tsMain.initTsserverClient(this.rootPath);\n return this.tsserver;\n }\n\n return this.tsserver;\n }\n\n async computeSchema(node: Node, context: SchemaExtractorContext): Promise<SchemaNode> {\n const transformer = this.getTransformer(node, context);\n // leave the next line commented out, it is used for debugging\n // console.log('transformer', transformer.constructor.name, node.getText());\n return transformer.transform(node, context);\n }\n\n async getComponentIDByPath(file: string) {\n if (!this.workspace) {\n return null;\n }\n return this.workspace.getComponentIdByPath(file);\n }\n\n /**\n * select the correct transformer for a node.\n */\n private getTransformer(node: Node, context: SchemaExtractorContext) {\n const transformers = flatten(this.schemaTransformerSlot.values());\n const transformer = transformers.find((singleTransformer) => singleTransformer.predicate(node));\n\n if (!transformer) throw new TransformerNotFound(node, context.component, context.getLocation(node));\n\n return transformer;\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"names":["TypeScriptExtractor","constructor","tsconfig","schemaTransformerSlot","tsMain","rootPath","depResolver","workspace","undefined","parseSourceFile","file","sourceFile","ts","createSourceFile","path","contents","toString","ScriptTarget","Latest","extract","component","tsserver","getTsServer","mainFile","mainAst","context","createContext","exportNames","computeExportedIdentifiers","setExports","ExportList","moduleSchema","computeSchema","flatExportsRecursively","apiScheme","location","getLocation","APISchema","id","node","transformer","getTransformer","getIdentifiers","TransformerNotFound","componentDeps","getComponentDeps","SchemaExtractorContext","deps","getDependencies","getComponentDependencies","getTsserverClient","initTsserverClient","transform","getComponentIDByPath","getComponentIdByPath","transformers","flatten","values","find","singleTransformer","predicate"],"sources":["typescript.extractor.ts"],"sourcesContent":["import ts, { Node, SourceFile } from 'typescript';\nimport { SchemaExtractor } from '@teambit/schema';\nimport { TsserverClient } from '@teambit/ts-server';\nimport type { Workspace } from '@teambit/workspace';\nimport { ComponentDependency, DependencyResolverMain } from '@teambit/dependency-resolver';\nimport { SchemaNode, APISchema, Module } from '@teambit/semantics.entities.semantic-schema';\nimport { Component } from '@teambit/component';\nimport { AbstractVinyl } from '@teambit/legacy/dist/consumer/component/sources';\nimport { flatten } from 'lodash';\nimport { TypescriptMain, SchemaTransformerSlot } from './typescript.main.runtime';\nimport { TransformerNotFound } from './exceptions';\nimport { SchemaExtractorContext } from './schema-extractor-context';\nimport { ExportList } from './export-list';\n\nexport class TypeScriptExtractor implements SchemaExtractor {\n constructor(\n private tsconfig: any,\n private schemaTransformerSlot: SchemaTransformerSlot,\n private tsMain: TypescriptMain,\n private rootPath: string,\n private depResolver: DependencyResolverMain,\n private workspace: Workspace | undefined\n ) {}\n\n parseSourceFile(file: AbstractVinyl): SourceFile {\n const sourceFile = ts.createSourceFile(\n file.path,\n file.contents.toString('utf8'),\n ts.ScriptTarget.Latest,\n true\n /** don't pass the scriptKind, it'll be determined automatically by typescript by the filepath */\n );\n // leave this commented out, it's helpful when there are issues with ASTs. consider throwing in this case.\n // console.log(\"sourceFile Errors\", file.path, sourceFile.parseDiagnostics);\n return sourceFile;\n }\n\n /**\n * extract a component schema.\n */\n async extract(component: Component): Promise<APISchema> {\n const tsserver = await this.getTsServer();\n const mainFile = component.mainFile;\n const mainAst = this.parseSourceFile(mainFile);\n const context = await this.createContext(tsserver, component);\n const exportNames = await this.computeExportedIdentifiers(mainAst, context);\n context.setExports(new ExportList(exportNames));\n const moduleSchema = (await this.computeSchema(mainAst, context)) as Module;\n moduleSchema.flatExportsRecursively();\n const apiScheme = moduleSchema;\n const location = context.getLocation(mainAst);\n\n return new APISchema(location, apiScheme, component.id);\n }\n\n async computeExportedIdentifiers(node: Node, context: SchemaExtractorContext) {\n const transformer = this.getTransformer(node, context);\n if (!transformer || !transformer.getIdentifiers) {\n throw new TransformerNotFound(node, context.component, context.getLocation(node));\n }\n return transformer.getIdentifiers(node, context);\n }\n\n private async createContext(tsserver: TsserverClient, component: Component): Promise<SchemaExtractorContext> {\n const componentDeps = await this.getComponentDeps(component);\n return new SchemaExtractorContext(tsserver, component, this, componentDeps);\n }\n\n private async getComponentDeps(component: Component): Promise<ComponentDependency[]> {\n const deps = await this.depResolver.getDependencies(component);\n const componentDeps = deps.getComponentDependencies();\n return componentDeps;\n }\n\n private tsserver: TsserverClient | undefined = undefined;\n\n private async getTsServer() {\n if (!this.tsserver) {\n const tsserver = this.tsMain.getTsserverClient();\n if (tsserver) {\n this.tsserver = tsserver;\n return tsserver;\n }\n\n this.tsserver = await this.tsMain.initTsserverClient(this.rootPath);\n return this.tsserver;\n }\n\n return this.tsserver;\n }\n\n async computeSchema(node: Node, context: SchemaExtractorContext): Promise<SchemaNode> {\n const transformer = this.getTransformer(node, context);\n // leave the next line commented out, it is used for debugging\n // console.log('transformer', transformer.constructor.name, node.getText());\n return transformer.transform(node, context);\n }\n\n async getComponentIDByPath(file: string) {\n if (!this.workspace) {\n return null;\n }\n return this.workspace.getComponentIdByPath(file);\n }\n\n /**\n * select the correct transformer for a node.\n */\n private getTransformer(node: Node, context: SchemaExtractorContext) {\n const transformers = flatten(this.schemaTransformerSlot.values());\n const transformer = transformers.find((singleTransformer) => singleTransformer.predicate(node));\n\n if (!transformer) throw new TransformerNotFound(node, context.component, context.getLocation(node));\n\n return transformer;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;AAAA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAKA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAGA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AAEA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;EAAA;AAAA;AACA;EAAA;EAAA;IAAA;EAAA;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