@descryy/adapter-kotlin 0.2.0 → 0.3.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/LICENSE +8 -0
- package/dist/adapter.d.ts +4 -8
- package/dist/adapter.d.ts.map +1 -1
- package/dist/adapter.js +56 -58
- package/dist/adapter.js.map +1 -1
- package/dist/client.d.ts +23 -41
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +42 -67
- package/dist/client.js.map +1 -1
- package/dist/extract.d.ts +18 -32
- package/dist/extract.d.ts.map +1 -1
- package/dist/extract.js +107 -173
- package/dist/extract.js.map +1 -1
- package/dist/parse.d.ts +20 -37
- package/dist/parse.d.ts.map +1 -1
- package/dist/parse.js +70 -118
- package/dist/parse.js.map +1 -1
- package/dist/retrofit.d.ts +23 -49
- package/dist/retrofit.d.ts.map +1 -1
- package/dist/retrofit.js +20 -46
- package/dist/retrofit.js.map +1 -1
- package/dist/routes.d.ts +13 -20
- package/dist/routes.d.ts.map +1 -1
- package/dist/routes.js +24 -45
- package/dist/routes.js.map +1 -1
- package/dist/spring.d.ts +16 -24
- package/dist/spring.d.ts.map +1 -1
- package/dist/spring.js +21 -33
- package/dist/spring.js.map +1 -1
- package/package.json +15 -6
package/LICENSE
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
Copyright (c) 2026 Descry
|
|
2
|
+
|
|
3
|
+
All rights reserved.
|
|
4
|
+
|
|
5
|
+
This software is proprietary and confidential. No license, express or
|
|
6
|
+
implied, to use, copy, modify, merge, publish, distribute, sublicense, or
|
|
7
|
+
sell copies of this software is granted without prior written permission
|
|
8
|
+
from the copyright holder.
|
package/dist/adapter.d.ts
CHANGED
|
@@ -1,14 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The Kotlin `LanguageAdapter` — breadth tier, tenth language.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* in this project at a two-week silent drift.
|
|
9
|
-
*
|
|
10
|
-
* The one place Kotlin diverges from Java is the fallback, and it diverges
|
|
11
|
-
* toward refusal. See `extract.ts`.
|
|
4
|
+
* Shares its identity anchor with `@descryy/adapter-jvm` (Java's) rather than
|
|
5
|
+
* defining its own — a copied rule drifts (measured elsewhere in this project
|
|
6
|
+
* at two weeks). Diverges from Java only in the fallback, toward refusal; see
|
|
7
|
+
* `extract.ts`.
|
|
12
8
|
*/
|
|
13
9
|
import { type LanguageAdapter, type ResolutionLevel } from "@descryy/ir";
|
|
14
10
|
export declare const ADAPTER_ID = "adapter-kotlin";
|
package/dist/adapter.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../src/adapter.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"adapter.d.ts","sourceRoot":"","sources":["../src/adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAKH,OAAO,EAML,KAAK,eAAe,EAGpB,KAAK,eAAe,EACrB,MAAM,aAAa,CAAC;AASrB,eAAO,MAAM,UAAU,mBAAmB,CAAC;AAC3C,eAAO,MAAM,eAAe,UAAU,CAAC;AACvC,eAAO,MAAM,oBAAoB,sBAAuB,CAAC;AACzD,eAAO,MAAM,QAAQ,WAAW,CAAC;AAuCjC,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACnC,QAAQ,CAAC,aAAa,CAAC,EAAE,eAAe,CAAC;CAC1C;AAcD,MAAM,WAAW,aAAc,SAAQ,eAAe;IACpD,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED,wBAAgB,mBAAmB,CAAC,OAAO,GAAE,oBAAyB,GAAG,aAAa,CA2OrF"}
|
package/dist/adapter.js
CHANGED
|
@@ -1,14 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The Kotlin `LanguageAdapter` — breadth tier, tenth language.
|
|
3
3
|
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
* in this project at a two-week silent drift.
|
|
9
|
-
*
|
|
10
|
-
* The one place Kotlin diverges from Java is the fallback, and it diverges
|
|
11
|
-
* toward refusal. See `extract.ts`.
|
|
4
|
+
* Shares its identity anchor with `@descryy/adapter-jvm` (Java's) rather than
|
|
5
|
+
* defining its own — a copied rule drifts (measured elsewhere in this project
|
|
6
|
+
* at two weeks). Diverges from Java only in the fallback, toward refusal; see
|
|
7
|
+
* `extract.ts`.
|
|
12
8
|
*/
|
|
13
9
|
import { existsSync, readFileSync } from "node:fs";
|
|
14
10
|
import { join } from "node:path";
|
|
@@ -24,14 +20,10 @@ export const DEFAULT_KOTLIN_GLOBS = ["**/*.kt"];
|
|
|
24
20
|
export const LANGUAGE = "kotlin";
|
|
25
21
|
const PRODUCED_BY = `${ADAPTER_ID}@${ADAPTER_VERSION}`;
|
|
26
22
|
/**
|
|
27
|
-
*
|
|
28
|
-
*
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
* an adapter that cannot parse and does not say so reports an empty graph as a
|
|
32
|
-
* clean one (DEC-171). Two locations because this module runs from `dist/` when
|
|
33
|
-
* built and from `src/` under Node's type stripping, which is how the unit
|
|
34
|
-
* tests import it.
|
|
23
|
+
* Grammar isn't on npm, so there's no `require.resolve` fallback — the error
|
|
24
|
+
* must name the fetch command, since a silent parse failure reports an empty
|
|
25
|
+
* graph as a clean one (DEC-171). Two candidate paths: `dist/` when built,
|
|
26
|
+
* `src/` under Node's type stripping (how tests import it).
|
|
35
27
|
*/
|
|
36
28
|
function grammarPath() {
|
|
37
29
|
const candidates = [
|
|
@@ -62,7 +54,17 @@ export function createKotlinAdapter(options = {}) {
|
|
|
62
54
|
const ceiling = options.maxResolution ?? 2;
|
|
63
55
|
let session;
|
|
64
56
|
let parser;
|
|
65
|
-
|
|
57
|
+
let nestedCheckouts = [];
|
|
58
|
+
let ignoredByProject = [];
|
|
59
|
+
const filesUnder = (root) => {
|
|
60
|
+
const nested = [];
|
|
61
|
+
const found = discover(root.absolutePath, globs, {
|
|
62
|
+
onNestedCheckout: (dir) => nested.push(dir),
|
|
63
|
+
onIgnored: (names) => (ignoredByProject = names),
|
|
64
|
+
}).filter((file) => !isGenerated(file));
|
|
65
|
+
nestedCheckouts = nested;
|
|
66
|
+
return found;
|
|
67
|
+
};
|
|
66
68
|
const current = () => {
|
|
67
69
|
const live = session;
|
|
68
70
|
if (live === undefined)
|
|
@@ -82,8 +84,8 @@ export function createKotlinAdapter(options = {}) {
|
|
|
82
84
|
const evidence = [];
|
|
83
85
|
if (files.length > 0)
|
|
84
86
|
evidence.push(`${files.length} .kt source files outside build output`);
|
|
85
|
-
//
|
|
86
|
-
//
|
|
87
|
+
// Stated at detection rather than discovered in a gate: the anchor's
|
|
88
|
+
// reach is what this adapter can emit.
|
|
87
89
|
if (files.length > 0) {
|
|
88
90
|
let anchored = 0;
|
|
89
91
|
for (const file of files) {
|
|
@@ -113,6 +115,13 @@ export function createKotlinAdapter(options = {}) {
|
|
|
113
115
|
"that claim (okhttp) contains no Kotlin-to-Java reference at all, so the rule would " +
|
|
114
116
|
"ship unwitnessed.");
|
|
115
117
|
}
|
|
118
|
+
for (const nested of nestedCheckouts) {
|
|
119
|
+
evidence.push(`skipped ${nested}: a separate checkout with its own .git`);
|
|
120
|
+
}
|
|
121
|
+
if (ignoredByProject.length > 0) {
|
|
122
|
+
evidence.push(`skipped ${ignoredByProject.length} director(ies) the project's own .gitignore excludes: ` +
|
|
123
|
+
`${ignoredByProject.slice(0, 12).join(", ")}`);
|
|
124
|
+
}
|
|
116
125
|
return { detected: files.length > 0, roots: files.length > 0 ? [root.absolutePath] : [], evidence };
|
|
117
126
|
},
|
|
118
127
|
capabilities() {
|
|
@@ -120,31 +129,24 @@ export function createKotlinAdapter(options = {}) {
|
|
|
120
129
|
maxResolution: ceiling,
|
|
121
130
|
nodeTypes: ["MODULE", "CLASS", "FUNCTION", "TEST_CASE", "API_ROUTE", "API_ENDPOINT"],
|
|
122
131
|
/**
|
|
123
|
-
* Kotlin
|
|
124
|
-
*
|
|
125
|
-
*
|
|
126
|
-
*
|
|
127
|
-
* with the syntax as confirmation.
|
|
132
|
+
* Kotlin states which supertype is the superclass — invoked as `Base()`,
|
|
133
|
+
* which an interface can't be — so `INHERITS`/`IMPLEMENTS` split cleanly
|
|
134
|
+
* from source, unlike Swift's. Decided against the declaration table,
|
|
135
|
+
* syntax only as confirmation.
|
|
128
136
|
*/
|
|
129
137
|
edgeTypes: ["IMPORTS", "CALLS", "TESTS", "IMPLEMENTS", "INHERITS", "USES_TYPE", "SERVES_API", "USES_API"],
|
|
130
138
|
hasCallHierarchy: false,
|
|
131
139
|
hasTypeHierarchy: false,
|
|
132
140
|
/**
|
|
133
|
-
*
|
|
134
|
-
*
|
|
135
|
-
*
|
|
136
|
-
*
|
|
137
|
-
*
|
|
138
|
-
* of Gradle's `build/` is output territory. `target/` covers a Maven-built module.
|
|
139
|
-
*
|
|
140
|
-
* Names only — the walk matches one path component, so a path or glob matches
|
|
141
|
-
* nothing. Nothing dotted — those are skipped structurally already.
|
|
141
|
+
* Per-ecosystem build/dependency dirs (DEC-110): the engine no longer
|
|
142
|
+
* hardcodes `node_modules`/`vendor`/`target`, adapters supply this instead.
|
|
143
|
+
* `build` covers Gradle output (`isGenerated()` already excludes the
|
|
144
|
+
* `generated`/`tmp` subpaths); `target` covers a Maven-built module.
|
|
145
|
+
* Names only, matched as one path component — no paths, no globs, no dotted dirs.
|
|
142
146
|
*/
|
|
143
147
|
noiseDirectories: ["build", "target"],
|
|
144
|
-
// Ktor
|
|
145
|
-
//
|
|
146
|
-
// supply calls. No ORM extractor is bound, so patterns 06/07 still
|
|
147
|
-
// skip naming the capability they wanted.
|
|
148
|
+
// Routes: Ktor DSL, Spring MVC/WebFlux annotations. Calls: Ktor client,
|
|
149
|
+
// Retrofit interfaces. No ORM extractor bound — patterns 06/07 unmet.
|
|
148
150
|
frameworkExtractors: ["ktor", "ktor-client", "spring", "retrofit"],
|
|
149
151
|
frameworkCapabilities: ["route-extractor", "client-call-extractor"],
|
|
150
152
|
};
|
|
@@ -187,10 +189,9 @@ export function createKotlinAdapter(options = {}) {
|
|
|
187
189
|
const parsed = read.value;
|
|
188
190
|
if (parsed.hasError)
|
|
189
191
|
parsedWithErrors.push(file);
|
|
190
|
-
//
|
|
191
|
-
//
|
|
192
|
-
//
|
|
193
|
-
// Kotlin refuses (DEC-173).
|
|
192
|
+
// Divergence from Java: an underivable source root yields no identity
|
|
193
|
+
// package and `extract.ts` mints nothing for the file. Java falls back
|
|
194
|
+
// to the bare package; Kotlin refuses (DEC-173).
|
|
194
195
|
const sourceRoot = sourceRootOf(file, parsed.packageName);
|
|
195
196
|
if (sourceRoot === undefined) {
|
|
196
197
|
withoutAnchor.push(file);
|
|
@@ -200,24 +201,21 @@ export function createKotlinAdapter(options = {}) {
|
|
|
200
201
|
let anchor = anchors.get(sourceRoot);
|
|
201
202
|
if (anchor === undefined) {
|
|
202
203
|
anchor = anchorOf(ctx.root.absolutePath, sourceRoot);
|
|
203
|
-
// `anchorOf` reads the source set as the segment
|
|
204
|
-
//
|
|
205
|
-
//
|
|
206
|
-
//
|
|
207
|
-
//
|
|
208
|
-
//
|
|
209
|
-
//
|
|
210
|
-
//
|
|
211
|
-
// refusal in `extract.ts` does not catch these — their source root IS
|
|
212
|
-
// derivable, so the failure is in the anchor rather than in the
|
|
213
|
-
// subtraction.
|
|
204
|
+
// `anchorOf` reads the source set as the segment after the last `src`
|
|
205
|
+
// (the Maven/Gradle-JVM layout). Kotlin Multiplatform inverts this —
|
|
206
|
+
// ktor writes `ktor-io/darwin/src`, source set BEFORE `src` — so the
|
|
207
|
+
// rule returns "" for every platform and two source sets collapse
|
|
208
|
+
// onto one identity. Measured on ktor: 33 colliding MODULE ids,
|
|
209
|
+
// `HttpClient.kt` in `common/src` and `posix/src` among them.
|
|
210
|
+
// `extract.ts`'s refusal doesn't catch this: the source root IS
|
|
211
|
+
// derivable, so the bug is in the anchor, not the subtraction.
|
|
214
212
|
//
|
|
215
|
-
//
|
|
216
|
-
// subtracting the package path
|
|
217
|
-
//
|
|
218
|
-
//
|
|
219
|
-
//
|
|
220
|
-
//
|
|
213
|
+
// Fix: fall back to the already-derived `sourceRoot` itself (built by
|
|
214
|
+
// subtracting the package path from the directory) as the source set,
|
|
215
|
+
// rather than matching against a list of known source-set names —
|
|
216
|
+
// KMP's `<sourceSet>/src` doesn't follow the `src/<sourceSet>`
|
|
217
|
+
// convention such a list would assume, so subtraction is what
|
|
218
|
+
// generalizes and a name list is not.
|
|
221
219
|
if (anchor.sourceSet === "")
|
|
222
220
|
anchor = { module: anchor.module, sourceSet: sourceRoot };
|
|
223
221
|
anchors.set(sourceRoot, anchor);
|
package/dist/adapter.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"adapter.js","sourceRoot":"","sources":["../src/adapter.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"adapter.js","sourceRoot":"","sources":["../src/adapter.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,EAAE,UAAU,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACnD,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAEjC,OAAO,EAUN,MAAM,aAAa,CAAC;AAErB,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAwB,MAAM,yBAAyB,CAAC;AACtF,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAC/E,OAAO,EAAE,SAAS,EAAE,SAAS,EAAkC,MAAM,6BAA6B,CAAC;AAEnG,OAAO,EAAE,cAAc,EAAmB,MAAM,YAAY,CAAC;AAC7D,OAAO,EAAE,OAAO,EAAE,MAA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AAC,WAAW,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;gBACnE,YAAY,EAAE;oBACZ,GAAG,CAAC,IAAI,EAAE,QAAQ,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC;oBAC1F,gFAAgF;oBAChF,GAAG,CAAC,IAAI,EAAE,UAAU,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,OAAgB,EAAE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC;iBACvG;gBACD,iBAAiB,EAAE,IAAI,EAAE,OAAO,IAAI,CAAC;gBACrC,KAAK;gBACL,KAAK;gBACL,UAAU;aACX,CAAC;QACJ,CAAC;QAED,KAAK,CAAC,OAAO;YACX,OAAO,GAAG,SAAS,CAAC;YACpB,MAAM,GAAG,SAAS,CAAC;QACrB,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/dist/client.d.ts
CHANGED
|
@@ -5,56 +5,39 @@
|
|
|
5
5
|
* API_ROUTE ──SERVES_API──▶ API_ENDPOINT ◀──USES_API── caller
|
|
6
6
|
* ```
|
|
7
7
|
*
|
|
8
|
-
* `routes.ts` produces the provider half
|
|
9
|
-
*
|
|
10
|
-
* pattern 08 was skipped rather than passed — declared incapacity, per DEC-043.
|
|
8
|
+
* `routes.ts` produces the provider half; this produces the consumer half (previously absent —
|
|
9
|
+
* golden pattern 08 was skipped as declared incapacity, DEC-043).
|
|
11
10
|
*
|
|
12
|
-
* ## Provenance,
|
|
11
|
+
* ## Provenance is required, not the verb name alone
|
|
13
12
|
*
|
|
14
|
-
* `client.get(
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* a *test client* that makes no HTTP request. Ktor's own `testApplication { }`
|
|
19
|
-
* hands the test a `client` with exactly that shape.
|
|
20
|
-
*
|
|
21
|
-
* Two independent conditions, both required:
|
|
13
|
+
* `client.get(...)` alone is unsafe: `adapter-python` measured that matching on verb name alone
|
|
14
|
+
* would mint **2,280** false edges, since every Django/Flask test suite calls `client.get(...)` on
|
|
15
|
+
* a test client that makes no request — Ktor's own `testApplication { }` client has the identical
|
|
16
|
+
* shape. Both conditions below are required:
|
|
22
17
|
*
|
|
23
18
|
* | condition | evidence |
|
|
24
19
|
* | --- | --- |
|
|
25
20
|
* | the file imports the verb | `io.ktor.client.request.*` (wildcard) or `io.ktor.client.request.get` (explicit) |
|
|
26
|
-
* | the receiver is a real client | a local
|
|
27
|
-
*
|
|
28
|
-
* The wildcard case is not a convenience — it is the common case. Counted
|
|
29
|
-
* across the reference set: **385** files write `import io.ktor.client.request.*`
|
|
30
|
-
* against **3** that import a verb explicitly. A reader that required the
|
|
31
|
-
* explicit form would have been built for a shape the corpus does not contain,
|
|
32
|
-
* which is the failure `adapter-python`'s own header records paying for.
|
|
33
|
-
*
|
|
34
|
-
* ## Interpolation means the opposite of what it means on the route side
|
|
21
|
+
* | the receiver is a real client | a local/property **constructed** `HttpClient(...)`, or a parameter/property whose **written type** is `HttpClient` |
|
|
35
22
|
*
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
* assembled elsewhere and half of it is an endpoint that does not exist.
|
|
23
|
+
* The wildcard form is the common case, not an edge case: **385** files in the reference set
|
|
24
|
+
* import it that way against **3** that import a verb explicitly.
|
|
39
25
|
*
|
|
40
|
-
*
|
|
41
|
-
* path *parameter*, and the interpolation is precisely the part that must
|
|
42
|
-
* become `{param}` for the call to join the route that serves it. Refusing it
|
|
43
|
-
* would refuse the only shape that ever joins.
|
|
26
|
+
* ## Interpolation is inverted from the route side
|
|
44
27
|
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
28
|
+
* `routes.ts` refuses an interpolated path (a route template must be written literally). Here,
|
|
29
|
+
* interpolation is how a caller writes a path *parameter* — it must collapse to `{param}` to join
|
|
30
|
+
* its route, so refusing it would refuse the only shape that ever joins. Both spellings are read:
|
|
31
|
+
* `$id` (`interpolated_identifier`) and `${id}` (`interpolated_expression`).
|
|
48
32
|
*
|
|
49
33
|
* ## What is refused
|
|
50
34
|
*
|
|
51
|
-
* A path that is not a string literal at all · a path that is not
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* else in another, which this reader cannot separate without a type checker.
|
|
35
|
+
* A path that is not a string literal at all · a path that is not repository-relative, which is
|
|
36
|
+
* an outbound call to somebody else's service and has no route on this side of the join · an
|
|
37
|
+
* absolute URL, for the same reason plus [DEC-014](../../../descry-core/DECISIONS.md): an endpoint
|
|
38
|
+
* is host-free, so `/v1/charges` on Stripe and `/v1/charges` here would be one node · a receiver
|
|
39
|
+
* whose name is bound to `HttpClient` in one place and to something else in another, which this
|
|
40
|
+
* reader cannot separate without a type checker.
|
|
58
41
|
*/
|
|
59
42
|
import type { Node } from "@descryy/adapter-treesitter";
|
|
60
43
|
import type { KotlinImport } from "./parse.ts";
|
|
@@ -77,9 +60,8 @@ export interface KotlinClientRefusal {
|
|
|
77
60
|
/** DEC-242's `attrs.refusalClass` — `undefined` means unclassified, never askable. */
|
|
78
61
|
readonly refusalClass: BaseRefusalClass | "out-of-scope" | undefined;
|
|
79
62
|
/**
|
|
80
|
-
* Diagnostic only, not part of DEC-242 — see `adapter-rust/src/client.ts
|
|
81
|
-
*
|
|
82
|
-
* contract. Present only on the generic fallthrough of `diagnoseArgument`.
|
|
63
|
+
* Diagnostic only, not part of DEC-242 — see `adapter-rust/src/client.ts`.
|
|
64
|
+
* Present only on the generic fallthrough of `diagnoseArgument`.
|
|
83
65
|
*/
|
|
84
66
|
readonly argumentKind?: "field" | "call" | "concatenation" | "other";
|
|
85
67
|
}
|
package/dist/client.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAEH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,6BAA6B,CAAC;AAExD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAkB/C,MAAM,WAAW,gBAAgB;IAC/B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,gEAAgE;IAChE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,yDAAyD;IACzD,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB,+CAA+C;IAC/C,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,mBAAmB;IAClC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,gFAAgF;IAChF,QAAQ,CAAC,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IAClC,sFAAsF;IACtF,QAAQ,CAAC,YAAY,EAAE,gBAAgB,GAAG,cAAc,GAAG,SAAS,CAAC;IACrE;;;OAGG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,eAAe,GAAG,OAAO,CAAC;CACtE;AAYD,MAAM,MAAM,gBAAgB,GAAG,eAAe,GAAG,iBAAiB,GAAG,gBAAgB,CAAC;AA0CtF,MAAM,WAAW,iBAAiB;IAChC,QAAQ,CAAC,KAAK,EAAE,SAAS,gBAAgB,EAAE,CAAC;IAC5C,QAAQ,CAAC,QAAQ,EAAE,SAAS,mBAAmB,EAAE,CAAC;CACnD;AAuKD,kEAAkE;AAClE,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,YAAY,EAAE,GAAG,iBAAiB,CA8EnG"}
|
package/dist/client.js
CHANGED
|
@@ -5,56 +5,39 @@
|
|
|
5
5
|
* API_ROUTE ──SERVES_API──▶ API_ENDPOINT ◀──USES_API── caller
|
|
6
6
|
* ```
|
|
7
7
|
*
|
|
8
|
-
* `routes.ts` produces the provider half
|
|
9
|
-
*
|
|
10
|
-
* pattern 08 was skipped rather than passed — declared incapacity, per DEC-043.
|
|
8
|
+
* `routes.ts` produces the provider half; this produces the consumer half (previously absent —
|
|
9
|
+
* golden pattern 08 was skipped as declared incapacity, DEC-043).
|
|
11
10
|
*
|
|
12
|
-
* ## Provenance,
|
|
11
|
+
* ## Provenance is required, not the verb name alone
|
|
13
12
|
*
|
|
14
|
-
* `client.get(
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
* a *test client* that makes no HTTP request. Ktor's own `testApplication { }`
|
|
19
|
-
* hands the test a `client` with exactly that shape.
|
|
20
|
-
*
|
|
21
|
-
* Two independent conditions, both required:
|
|
13
|
+
* `client.get(...)` alone is unsafe: `adapter-python` measured that matching on verb name alone
|
|
14
|
+
* would mint **2,280** false edges, since every Django/Flask test suite calls `client.get(...)` on
|
|
15
|
+
* a test client that makes no request — Ktor's own `testApplication { }` client has the identical
|
|
16
|
+
* shape. Both conditions below are required:
|
|
22
17
|
*
|
|
23
18
|
* | condition | evidence |
|
|
24
19
|
* | --- | --- |
|
|
25
20
|
* | the file imports the verb | `io.ktor.client.request.*` (wildcard) or `io.ktor.client.request.get` (explicit) |
|
|
26
|
-
* | the receiver is a real client | a local
|
|
27
|
-
*
|
|
28
|
-
* The wildcard case is not a convenience — it is the common case. Counted
|
|
29
|
-
* across the reference set: **385** files write `import io.ktor.client.request.*`
|
|
30
|
-
* against **3** that import a verb explicitly. A reader that required the
|
|
31
|
-
* explicit form would have been built for a shape the corpus does not contain,
|
|
32
|
-
* which is the failure `adapter-python`'s own header records paying for.
|
|
33
|
-
*
|
|
34
|
-
* ## Interpolation means the opposite of what it means on the route side
|
|
21
|
+
* | the receiver is a real client | a local/property **constructed** `HttpClient(...)`, or a parameter/property whose **written type** is `HttpClient` |
|
|
35
22
|
*
|
|
36
|
-
*
|
|
37
|
-
*
|
|
38
|
-
* assembled elsewhere and half of it is an endpoint that does not exist.
|
|
23
|
+
* The wildcard form is the common case, not an edge case: **385** files in the reference set
|
|
24
|
+
* import it that way against **3** that import a verb explicitly.
|
|
39
25
|
*
|
|
40
|
-
*
|
|
41
|
-
* path *parameter*, and the interpolation is precisely the part that must
|
|
42
|
-
* become `{param}` for the call to join the route that serves it. Refusing it
|
|
43
|
-
* would refuse the only shape that ever joins.
|
|
26
|
+
* ## Interpolation is inverted from the route side
|
|
44
27
|
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
28
|
+
* `routes.ts` refuses an interpolated path (a route template must be written literally). Here,
|
|
29
|
+
* interpolation is how a caller writes a path *parameter* — it must collapse to `{param}` to join
|
|
30
|
+
* its route, so refusing it would refuse the only shape that ever joins. Both spellings are read:
|
|
31
|
+
* `$id` (`interpolated_identifier`) and `${id}` (`interpolated_expression`).
|
|
48
32
|
*
|
|
49
33
|
* ## What is refused
|
|
50
34
|
*
|
|
51
|
-
* A path that is not a string literal at all · a path that is not
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
*
|
|
55
|
-
*
|
|
56
|
-
*
|
|
57
|
-
* else in another, which this reader cannot separate without a type checker.
|
|
35
|
+
* A path that is not a string literal at all · a path that is not repository-relative, which is
|
|
36
|
+
* an outbound call to somebody else's service and has no route on this side of the join · an
|
|
37
|
+
* absolute URL, for the same reason plus [DEC-014](../../../descry-core/DECISIONS.md): an endpoint
|
|
38
|
+
* is host-free, so `/v1/charges` on Stripe and `/v1/charges` here would be one node · a receiver
|
|
39
|
+
* whose name is bound to `HttpClient` in one place and to something else in another, which this
|
|
40
|
+
* reader cannot separate without a type checker.
|
|
58
41
|
*/
|
|
59
42
|
/** The package whose verb extension functions are HTTP calls. */
|
|
60
43
|
const REQUEST_PACKAGE = "io.ktor.client.request";
|
|
@@ -145,11 +128,10 @@ function templateOf(argument) {
|
|
|
145
128
|
return out;
|
|
146
129
|
}
|
|
147
130
|
/**
|
|
148
|
-
* Unwrap
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
* `
|
|
152
|
-
* the outer one loses every `client.get("/x") { header(...) }` in the corpus.
|
|
131
|
+
* Unwrap `receiver.verb(args)`, including the trailing-lambda form — args plus
|
|
132
|
+
* a lambda parse as two nested `call_expression`s (same fact `routes.ts`
|
|
133
|
+
* unwraps); reading only the outer node loses every
|
|
134
|
+
* `client.get("/x") { header(...) }` call.
|
|
153
135
|
*/
|
|
154
136
|
function verbCallOf(node) {
|
|
155
137
|
if (node.type !== "call_expression")
|
|
@@ -187,15 +169,12 @@ const typeNameOf = (node) => firstOfType(node, "user_type") === undefined
|
|
|
187
169
|
? undefined
|
|
188
170
|
: firstOfType(firstOfType(node, "user_type"), "type_identifier")?.text;
|
|
189
171
|
/**
|
|
190
|
-
* The name
|
|
172
|
+
* The name *constructed* by a call expression, unwrapping the nested form.
|
|
191
173
|
*
|
|
192
|
-
* `HttpClient()
|
|
193
|
-
*
|
|
194
|
-
*
|
|
195
|
-
*
|
|
196
|
-
* not a small miss: `HttpClient(engine) { … }` is how essentially every real
|
|
197
|
-
* Ktor client is built, so the reader saw zero clients on a repository holding
|
|
198
|
-
* hundreds.
|
|
174
|
+
* `HttpClient(engine) { … }` (args + trailing lambda) parses as two nested
|
|
175
|
+
* `call_expression`s, the same fact `verbCallOf` unwraps. Reading only the
|
|
176
|
+
* outer node finds zero clients — and that form is how essentially every real
|
|
177
|
+
* Ktor client is built, so the miss was total, not marginal.
|
|
199
178
|
*/
|
|
200
179
|
function constructedName(node) {
|
|
201
180
|
if (node.type !== "call_expression")
|
|
@@ -208,13 +187,11 @@ function constructedName(node) {
|
|
|
208
187
|
return head.type === "simple_identifier" ? head.text : undefined;
|
|
209
188
|
}
|
|
210
189
|
/**
|
|
211
|
-
* Names bound to
|
|
212
|
-
*
|
|
213
|
-
*
|
|
214
|
-
*
|
|
215
|
-
*
|
|
216
|
-
* aggressively, which makes that collision likelier here than in a language
|
|
217
|
-
* that writes its types down.
|
|
190
|
+
* Names bound to `HttpClient` vs. bound to anything else, collected file-wide
|
|
191
|
+
* then **intersected**: a name typed as `HttpClient` in one scope and
|
|
192
|
+
* something else in another can't be separated at R2 without a type checker,
|
|
193
|
+
* so it's disclosed rather than admitted. Kotlin's aggressive inference makes
|
|
194
|
+
* this collision likelier than in an explicitly-typed language.
|
|
218
195
|
*/
|
|
219
196
|
function clientNames(root, imports) {
|
|
220
197
|
const verified = new Set();
|
|
@@ -270,11 +247,10 @@ export function readKtorClientCalls(root, imports) {
|
|
|
270
247
|
const calls = [];
|
|
271
248
|
const refusals = [];
|
|
272
249
|
const { verified, ambiguous } = clientNames(root, imports);
|
|
273
|
-
// Replaced, not merged, on entering a nested `function_declaration
|
|
274
|
-
// innermost function's
|
|
275
|
-
//
|
|
276
|
-
//
|
|
277
|
-
// capture here, not a parameter.
|
|
250
|
+
// Replaced, not merged, on entering a nested `function_declaration`: the
|
|
251
|
+
// innermost function's parameters are what "varies-per-call" means inside it
|
|
252
|
+
// (same scoping as every other language's diagnoseArgument). A name closed
|
|
253
|
+
// over from an outer function is an ordinary capture, not a parameter.
|
|
278
254
|
const visit = (node, parameterNames) => {
|
|
279
255
|
const scoped = node.type === "function_declaration" ? parameterNamesOf(node) : parameterNames;
|
|
280
256
|
const call = verbCallOf(node);
|
|
@@ -294,10 +270,9 @@ export function readKtorClientCalls(root, imports) {
|
|
|
294
270
|
else if (verified.has(call.receiver)) {
|
|
295
271
|
readVerified(call, method, scoped);
|
|
296
272
|
}
|
|
297
|
-
//
|
|
298
|
-
//
|
|
299
|
-
//
|
|
300
|
-
// real refusals under the 2,280-row population.
|
|
273
|
+
// Neither verified nor ambiguous: no visible client, no ledger row.
|
|
274
|
+
// `x.get(...)` is overwhelmingly a map lookup or test client; filing
|
|
275
|
+
// every one would bury real refusals under a 2,280-row population.
|
|
301
276
|
}
|
|
302
277
|
}
|
|
303
278
|
for (const child of namedChildren(node))
|
package/dist/client.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AAMH,iEAAiE;AACjE,MAAM,eAAe,GAAG,wBAAwB,CAAC;AACjD,0EAA0E;AAC1E,MAAM,WAAW,GAAG,YAAY,CAAC;AACjC,MAAM,cAAc,GAAG,gBAAgB,CAAC;AAExC,MAAM,KAAK,GAAgC,IAAI,GAAG,CAAC;IACjD,CAAC,KAAK,EAAE,KAAK,CAAC;IACd,CAAC,MAAM,EAAE,MAAM,CAAC;IAChB,CAAC,KAAK,EAAE,KAAK,CAAC;IACd,CAAC,OAAO,EAAE,OAAO,CAAC;IAClB,CAAC,QAAQ,EAAE,QAAQ,CAAC;IACpB,CAAC,MAAM,EAAE,MAAM,CAAC;IAChB,CAAC,SAAS,EAAE,SAAS,CAAC;CACvB,CAAC,CAAC;AA8CH,MAAM,cAAc,GAAkB,EAAE,SAAS,EAAE,IAAI,EAAE,YAAY,EAAE,gBAAgB,EAAE,CAAC;AAC1F,MAAM,eAAe,GAAkB,EAAE,SAAS,EAAE,IAAI,EAAE,YAAY,EAAE,iBAAiB,EAAE,CAAC;AAC5F,MAAM,YAAY,GAAkB,EAAE,SAAS,EA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