@vercel/python-analysis 0.11.1 → 0.13.1
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/index.cjs +245 -4
- package/dist/index.d.ts +5 -3
- package/dist/index.js +249 -13
- package/dist/manifest/pyproject/schema.d.ts +13 -1
- package/dist/manifest/pyproject/schema.zod.d.ts +159 -0
- package/dist/manifest/pyproject/types.d.ts +19 -0
- package/dist/semantic/import-graph.d.ts +69 -0
- package/dist/wasm/interfaces/wasi-cli-environment.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-exit.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-stderr.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-stdin.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-stdout.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-terminal-input.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-terminal-output.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-terminal-stderr.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-terminal-stdin.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-cli-terminal-stdout.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-clocks-monotonic-clock.d.ts +4 -0
- package/dist/wasm/interfaces/wasi-clocks-wall-clock.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-filesystem-preopens.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-filesystem-types.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-io-error.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-io-poll.d.ts +2 -1
- package/dist/wasm/interfaces/wasi-io-streams.d.ts +1 -1
- package/dist/wasm/interfaces/wasi-random-insecure-seed.d.ts +1 -1
- package/dist/wasm/vercel_python_analysis.core.wasm +0 -0
- package/dist/wasm/vercel_python_analysis.core2.wasm +0 -0
- package/dist/wasm/vercel_python_analysis.core3.wasm +0 -0
- package/dist/wasm/vercel_python_analysis.d.ts +44 -34
- package/dist/wasm/vercel_python_analysis.js +292 -140
- package/package.json +1 -1
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* @module pyproject/schema
|
|
8
8
|
*/
|
|
9
9
|
import type { z } from 'zod';
|
|
10
|
-
import type { License, LicenseObject, Person, PyProjectBuildSystem, PyProjectDependencyGroups, PyProjectProject, PyProjectToml, PyProjectToolSection, Readme, ReadmeObject } from './types';
|
|
10
|
+
import type { License, LicenseObject, Person, PyProjectBuildSystem, PyProjectDependencyGroups, PyProjectProject, PyProjectToml, PyProjectToolSection, Readme, ReadmeObject, PyProjectToolVercelFastapiSection, PyProjectToolVercelFastapiStaticSection, PyProjectToolVercelSection } from './types';
|
|
11
11
|
/**
|
|
12
12
|
* Schema for [build-system] per PEP 518.
|
|
13
13
|
*/
|
|
@@ -40,6 +40,18 @@ export declare const PyProjectProjectSchema: z.ZodType<PyProjectProject>;
|
|
|
40
40
|
* Schema for [dependency-groups].
|
|
41
41
|
*/
|
|
42
42
|
export declare const PyProjectDependencyGroupsSchema: z.ZodType<PyProjectDependencyGroups>;
|
|
43
|
+
/**
|
|
44
|
+
* Schema for [tool.vercel] section.
|
|
45
|
+
*/
|
|
46
|
+
export declare const PyProjectToolVercelSectionSchema: z.ZodType<PyProjectToolVercelSection>;
|
|
47
|
+
/**
|
|
48
|
+
* Schema for [tool.vercel.fastapi] section.
|
|
49
|
+
*/
|
|
50
|
+
export declare const PyProjectToolVercelFastapiSectionSchema: z.ZodType<PyProjectToolVercelFastapiSection>;
|
|
51
|
+
/**
|
|
52
|
+
* Schema for [tool.vercel.fastapi.static] section.
|
|
53
|
+
*/
|
|
54
|
+
export declare const PyProjectToolVercelFastapiStaticSectionSchema: z.ZodType<PyProjectToolVercelFastapiStaticSection>;
|
|
43
55
|
/**
|
|
44
56
|
* Schema for [tool.FOO] section.
|
|
45
57
|
*/
|
|
@@ -195,6 +195,61 @@ export declare const pyProjectDependencyGroupsSchema: z.ZodRecord<z.ZodString, z
|
|
|
195
195
|
}, {
|
|
196
196
|
'include-group': string;
|
|
197
197
|
}>]>, "many">>;
|
|
198
|
+
export declare const pyProjectToolVercelFastapiStaticSectionSchema: z.ZodObject<{
|
|
199
|
+
cdn: z.ZodOptional<z.ZodBoolean>;
|
|
200
|
+
}, "strip", z.ZodTypeAny, {
|
|
201
|
+
cdn?: boolean | undefined;
|
|
202
|
+
}, {
|
|
203
|
+
cdn?: boolean | undefined;
|
|
204
|
+
}>;
|
|
205
|
+
export declare const pyProjectToolVercelFastapiSectionSchema: z.ZodObject<{
|
|
206
|
+
static: z.ZodOptional<z.ZodObject<{
|
|
207
|
+
cdn: z.ZodOptional<z.ZodBoolean>;
|
|
208
|
+
}, "strip", z.ZodTypeAny, {
|
|
209
|
+
cdn?: boolean | undefined;
|
|
210
|
+
}, {
|
|
211
|
+
cdn?: boolean | undefined;
|
|
212
|
+
}>>;
|
|
213
|
+
}, "strip", z.ZodTypeAny, {
|
|
214
|
+
static?: {
|
|
215
|
+
cdn?: boolean | undefined;
|
|
216
|
+
} | undefined;
|
|
217
|
+
}, {
|
|
218
|
+
static?: {
|
|
219
|
+
cdn?: boolean | undefined;
|
|
220
|
+
} | undefined;
|
|
221
|
+
}>;
|
|
222
|
+
export declare const pyProjectToolVercelSectionSchema: z.ZodObject<{
|
|
223
|
+
fastapi: z.ZodOptional<z.ZodObject<{
|
|
224
|
+
static: z.ZodOptional<z.ZodObject<{
|
|
225
|
+
cdn: z.ZodOptional<z.ZodBoolean>;
|
|
226
|
+
}, "strip", z.ZodTypeAny, {
|
|
227
|
+
cdn?: boolean | undefined;
|
|
228
|
+
}, {
|
|
229
|
+
cdn?: boolean | undefined;
|
|
230
|
+
}>>;
|
|
231
|
+
}, "strip", z.ZodTypeAny, {
|
|
232
|
+
static?: {
|
|
233
|
+
cdn?: boolean | undefined;
|
|
234
|
+
} | undefined;
|
|
235
|
+
}, {
|
|
236
|
+
static?: {
|
|
237
|
+
cdn?: boolean | undefined;
|
|
238
|
+
} | undefined;
|
|
239
|
+
}>>;
|
|
240
|
+
}, "strip", z.ZodTypeAny, {
|
|
241
|
+
fastapi?: {
|
|
242
|
+
static?: {
|
|
243
|
+
cdn?: boolean | undefined;
|
|
244
|
+
} | undefined;
|
|
245
|
+
} | undefined;
|
|
246
|
+
}, {
|
|
247
|
+
fastapi?: {
|
|
248
|
+
static?: {
|
|
249
|
+
cdn?: boolean | undefined;
|
|
250
|
+
} | undefined;
|
|
251
|
+
} | undefined;
|
|
252
|
+
}>;
|
|
198
253
|
export declare const pyProjectToolSectionSchema: z.ZodObject<{
|
|
199
254
|
uv: z.ZodOptional<z.ZodObject<{
|
|
200
255
|
sources: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodObject<{
|
|
@@ -317,6 +372,37 @@ export declare const pyProjectToolSectionSchema: z.ZodObject<{
|
|
|
317
372
|
} | undefined;
|
|
318
373
|
'dev-dependencies'?: string[] | undefined;
|
|
319
374
|
}>>;
|
|
375
|
+
vercel: z.ZodOptional<z.ZodObject<{
|
|
376
|
+
fastapi: z.ZodOptional<z.ZodObject<{
|
|
377
|
+
static: z.ZodOptional<z.ZodObject<{
|
|
378
|
+
cdn: z.ZodOptional<z.ZodBoolean>;
|
|
379
|
+
}, "strip", z.ZodTypeAny, {
|
|
380
|
+
cdn?: boolean | undefined;
|
|
381
|
+
}, {
|
|
382
|
+
cdn?: boolean | undefined;
|
|
383
|
+
}>>;
|
|
384
|
+
}, "strip", z.ZodTypeAny, {
|
|
385
|
+
static?: {
|
|
386
|
+
cdn?: boolean | undefined;
|
|
387
|
+
} | undefined;
|
|
388
|
+
}, {
|
|
389
|
+
static?: {
|
|
390
|
+
cdn?: boolean | undefined;
|
|
391
|
+
} | undefined;
|
|
392
|
+
}>>;
|
|
393
|
+
}, "strip", z.ZodTypeAny, {
|
|
394
|
+
fastapi?: {
|
|
395
|
+
static?: {
|
|
396
|
+
cdn?: boolean | undefined;
|
|
397
|
+
} | undefined;
|
|
398
|
+
} | undefined;
|
|
399
|
+
}, {
|
|
400
|
+
fastapi?: {
|
|
401
|
+
static?: {
|
|
402
|
+
cdn?: boolean | undefined;
|
|
403
|
+
} | undefined;
|
|
404
|
+
} | undefined;
|
|
405
|
+
}>>;
|
|
320
406
|
}, "strip", z.ZodTypeAny, {
|
|
321
407
|
uv?: {
|
|
322
408
|
sources?: Record<string, {
|
|
@@ -345,6 +431,13 @@ export declare const pyProjectToolSectionSchema: z.ZodObject<{
|
|
|
345
431
|
} | undefined;
|
|
346
432
|
'dev-dependencies'?: string[] | undefined;
|
|
347
433
|
} | undefined;
|
|
434
|
+
vercel?: {
|
|
435
|
+
fastapi?: {
|
|
436
|
+
static?: {
|
|
437
|
+
cdn?: boolean | undefined;
|
|
438
|
+
} | undefined;
|
|
439
|
+
} | undefined;
|
|
440
|
+
} | undefined;
|
|
348
441
|
}, {
|
|
349
442
|
uv?: {
|
|
350
443
|
sources?: Record<string, {
|
|
@@ -373,6 +466,13 @@ export declare const pyProjectToolSectionSchema: z.ZodObject<{
|
|
|
373
466
|
} | undefined;
|
|
374
467
|
'dev-dependencies'?: string[] | undefined;
|
|
375
468
|
} | undefined;
|
|
469
|
+
vercel?: {
|
|
470
|
+
fastapi?: {
|
|
471
|
+
static?: {
|
|
472
|
+
cdn?: boolean | undefined;
|
|
473
|
+
} | undefined;
|
|
474
|
+
} | undefined;
|
|
475
|
+
} | undefined;
|
|
376
476
|
}>;
|
|
377
477
|
export declare const pyProjectTomlSchema: z.ZodObject<{
|
|
378
478
|
project: z.ZodOptional<z.ZodObject<{
|
|
@@ -629,6 +729,37 @@ export declare const pyProjectTomlSchema: z.ZodObject<{
|
|
|
629
729
|
} | undefined;
|
|
630
730
|
'dev-dependencies'?: string[] | undefined;
|
|
631
731
|
}>>;
|
|
732
|
+
vercel: z.ZodOptional<z.ZodObject<{
|
|
733
|
+
fastapi: z.ZodOptional<z.ZodObject<{
|
|
734
|
+
static: z.ZodOptional<z.ZodObject<{
|
|
735
|
+
cdn: z.ZodOptional<z.ZodBoolean>;
|
|
736
|
+
}, "strip", z.ZodTypeAny, {
|
|
737
|
+
cdn?: boolean | undefined;
|
|
738
|
+
}, {
|
|
739
|
+
cdn?: boolean | undefined;
|
|
740
|
+
}>>;
|
|
741
|
+
}, "strip", z.ZodTypeAny, {
|
|
742
|
+
static?: {
|
|
743
|
+
cdn?: boolean | undefined;
|
|
744
|
+
} | undefined;
|
|
745
|
+
}, {
|
|
746
|
+
static?: {
|
|
747
|
+
cdn?: boolean | undefined;
|
|
748
|
+
} | undefined;
|
|
749
|
+
}>>;
|
|
750
|
+
}, "strip", z.ZodTypeAny, {
|
|
751
|
+
fastapi?: {
|
|
752
|
+
static?: {
|
|
753
|
+
cdn?: boolean | undefined;
|
|
754
|
+
} | undefined;
|
|
755
|
+
} | undefined;
|
|
756
|
+
}, {
|
|
757
|
+
fastapi?: {
|
|
758
|
+
static?: {
|
|
759
|
+
cdn?: boolean | undefined;
|
|
760
|
+
} | undefined;
|
|
761
|
+
} | undefined;
|
|
762
|
+
}>>;
|
|
632
763
|
}, "strip", z.ZodTypeAny, {
|
|
633
764
|
uv?: {
|
|
634
765
|
sources?: Record<string, {
|
|
@@ -657,6 +788,13 @@ export declare const pyProjectTomlSchema: z.ZodObject<{
|
|
|
657
788
|
} | undefined;
|
|
658
789
|
'dev-dependencies'?: string[] | undefined;
|
|
659
790
|
} | undefined;
|
|
791
|
+
vercel?: {
|
|
792
|
+
fastapi?: {
|
|
793
|
+
static?: {
|
|
794
|
+
cdn?: boolean | undefined;
|
|
795
|
+
} | undefined;
|
|
796
|
+
} | undefined;
|
|
797
|
+
} | undefined;
|
|
660
798
|
}, {
|
|
661
799
|
uv?: {
|
|
662
800
|
sources?: Record<string, {
|
|
@@ -685,6 +823,13 @@ export declare const pyProjectTomlSchema: z.ZodObject<{
|
|
|
685
823
|
} | undefined;
|
|
686
824
|
'dev-dependencies'?: string[] | undefined;
|
|
687
825
|
} | undefined;
|
|
826
|
+
vercel?: {
|
|
827
|
+
fastapi?: {
|
|
828
|
+
static?: {
|
|
829
|
+
cdn?: boolean | undefined;
|
|
830
|
+
} | undefined;
|
|
831
|
+
} | undefined;
|
|
832
|
+
} | undefined;
|
|
688
833
|
}>>;
|
|
689
834
|
}, "strip", z.ZodTypeAny, {
|
|
690
835
|
project?: {
|
|
@@ -753,6 +898,13 @@ export declare const pyProjectTomlSchema: z.ZodObject<{
|
|
|
753
898
|
} | undefined;
|
|
754
899
|
'dev-dependencies'?: string[] | undefined;
|
|
755
900
|
} | undefined;
|
|
901
|
+
vercel?: {
|
|
902
|
+
fastapi?: {
|
|
903
|
+
static?: {
|
|
904
|
+
cdn?: boolean | undefined;
|
|
905
|
+
} | undefined;
|
|
906
|
+
} | undefined;
|
|
907
|
+
} | undefined;
|
|
756
908
|
} | undefined;
|
|
757
909
|
}, {
|
|
758
910
|
project?: {
|
|
@@ -821,5 +973,12 @@ export declare const pyProjectTomlSchema: z.ZodObject<{
|
|
|
821
973
|
} | undefined;
|
|
822
974
|
'dev-dependencies'?: string[] | undefined;
|
|
823
975
|
} | undefined;
|
|
976
|
+
vercel?: {
|
|
977
|
+
fastapi?: {
|
|
978
|
+
static?: {
|
|
979
|
+
cdn?: boolean | undefined;
|
|
980
|
+
} | undefined;
|
|
981
|
+
} | undefined;
|
|
982
|
+
} | undefined;
|
|
824
983
|
} | undefined;
|
|
825
984
|
}>;
|
|
@@ -84,12 +84,31 @@ export type DependencyGroupEntry = string | DependencyGroupInclude;
|
|
|
84
84
|
* [dependency-groups] per PEP 735.
|
|
85
85
|
*/
|
|
86
86
|
export type PyProjectDependencyGroups = Record<string, DependencyGroupEntry[]>;
|
|
87
|
+
/**
|
|
88
|
+
* [tool.vercel] section.
|
|
89
|
+
*/
|
|
90
|
+
export interface PyProjectToolVercelSection {
|
|
91
|
+
fastapi?: PyProjectToolVercelFastapiSection;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* [tool.vercel.fastapi] section.
|
|
95
|
+
*/
|
|
96
|
+
export interface PyProjectToolVercelFastapiSection {
|
|
97
|
+
static?: PyProjectToolVercelFastapiStaticSection;
|
|
98
|
+
}
|
|
99
|
+
/**
|
|
100
|
+
* [tool.vercel.fastapi.static] section.
|
|
101
|
+
*/
|
|
102
|
+
export interface PyProjectToolVercelFastapiStaticSection {
|
|
103
|
+
cdn?: boolean;
|
|
104
|
+
}
|
|
87
105
|
/**
|
|
88
106
|
* [tool.FOO] section.
|
|
89
107
|
* @passthrough
|
|
90
108
|
*/
|
|
91
109
|
export interface PyProjectToolSection {
|
|
92
110
|
uv?: UvConfig;
|
|
111
|
+
vercel?: PyProjectToolVercelSection;
|
|
93
112
|
}
|
|
94
113
|
/**
|
|
95
114
|
* A pyproject.toml file.
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Static import-graph analysis: compute the transitive closure of modules a
|
|
3
|
+
* Python application imports at startup, without executing any user code.
|
|
4
|
+
*
|
|
5
|
+
* The closure feeds bytecode packing. Both error directions are safe:
|
|
6
|
+
* over-included modules waste capacity, and missed modules (plugin loaders,
|
|
7
|
+
* imports made by compiled extensions) still ship from residual capacity.
|
|
8
|
+
*
|
|
9
|
+
* Resolution semantics mirror CPython:
|
|
10
|
+
* - dotted name -> `a/b/__init__.py` | `a/b.py` | PEP 420 namespace dir
|
|
11
|
+
* - importing `a.b.c` executes every parent `__init__.py` (emitted + recursed)
|
|
12
|
+
* - `from a import b` probes `b` as a submodule of `a`
|
|
13
|
+
* - relative imports resolve against the importer's package by dot level
|
|
14
|
+
* - first search root wins, so app modules shadow vendor (runtime sys.path)
|
|
15
|
+
*
|
|
16
|
+
* Startup heuristics (applied on top of the raw WASM extraction):
|
|
17
|
+
* - imports inside function bodies are lazy and excluded
|
|
18
|
+
* - `if TYPE_CHECKING:` blocks never run at runtime and are excluded
|
|
19
|
+
* - both branches of module-level `if` / `try` are included
|
|
20
|
+
*/
|
|
21
|
+
export interface ImportStmt {
|
|
22
|
+
/** Dotted module path for from-imports; undefined for `from . import x`. */
|
|
23
|
+
module?: string;
|
|
24
|
+
/** Relative-import level (number of leading dots). 0 = absolute. */
|
|
25
|
+
level: number;
|
|
26
|
+
/** Imported names for from-imports (each may be a submodule). */
|
|
27
|
+
names: string[];
|
|
28
|
+
/** False when nested in a function body (lazy import). */
|
|
29
|
+
isModuleLevel: boolean;
|
|
30
|
+
/** True when under `if TYPE_CHECKING:` (never runs at runtime). */
|
|
31
|
+
inTypeChecking: boolean;
|
|
32
|
+
}
|
|
33
|
+
/**
|
|
34
|
+
* Extract every import statement in Python source with its syntactic
|
|
35
|
+
* context. Returns an empty list for invalid syntax.
|
|
36
|
+
*/
|
|
37
|
+
export declare function extractImports(source: string): Promise<ImportStmt[]>;
|
|
38
|
+
export interface ImportClosureOptions {
|
|
39
|
+
/**
|
|
40
|
+
* Entry points of the closure: absolute `.py` file paths and/or dotted
|
|
41
|
+
* module or object names (e.g. Django's ROOT_URLCONF / INSTALLED_APPS
|
|
42
|
+
* strings), resolved to their longest importable prefix against searchRoots.
|
|
43
|
+
*/
|
|
44
|
+
seeds: string[];
|
|
45
|
+
/**
|
|
46
|
+
* Ordered module search roots (e.g. [workPath, ...sitePackageDirs]).
|
|
47
|
+
* First match wins, so earlier roots shadow later ones.
|
|
48
|
+
*/
|
|
49
|
+
searchRoots: string[];
|
|
50
|
+
/**
|
|
51
|
+
* Approximate safety bound on parsed files, checked per frontier batch.
|
|
52
|
+
* On overflow the partial closure is returned with `truncated: true`
|
|
53
|
+
* (remaining modules fall to the residual bytecode tier).
|
|
54
|
+
*/
|
|
55
|
+
maxFiles?: number;
|
|
56
|
+
}
|
|
57
|
+
export interface ImportClosureResult {
|
|
58
|
+
/** Absolute paths of every `.py` file imported at startup. */
|
|
59
|
+
files: Set<string>;
|
|
60
|
+
truncated: boolean;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Compute the transitive closure of modules imported at startup.
|
|
64
|
+
*
|
|
65
|
+
* Only module-level imports outside `if TYPE_CHECKING:` blocks are followed
|
|
66
|
+
* (see module docstring). Files are read and parsed frontier-by-frontier in
|
|
67
|
+
* parallel; cycles are cut by the visited set.
|
|
68
|
+
*/
|
|
69
|
+
export declare function collectImportClosure({ seeds, searchRoots, maxFiles, }: ImportClosureOptions): Promise<ImportClosureResult>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/** @module Interface wasi:cli/environment@0.2.
|
|
1
|
+
/** @module Interface wasi:cli/environment@0.2.9 **/
|
|
2
2
|
export function getEnvironment(): Array<[string, string]>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** @module Interface wasi:io/streams@0.2.
|
|
1
|
+
/** @module Interface wasi:io/streams@0.2.9 **/
|
|
2
2
|
export type Error = import('./wasi-io-error.js').Error;
|
|
3
3
|
export type StreamError = StreamErrorLastOperationFailed | StreamErrorClosed;
|
|
4
4
|
export interface StreamErrorLastOperationFailed {
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
/** @module Interface wasi:random/insecure-seed@0.2.
|
|
1
|
+
/** @module Interface wasi:random/insecure-seed@0.2.9 **/
|
|
2
2
|
export function insecureSeed(): [bigint, bigint];
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
// world root:component/root
|
|
2
|
+
export interface ImportStmt {
|
|
3
|
+
module?: string,
|
|
4
|
+
level: number,
|
|
5
|
+
names: Array<string>,
|
|
6
|
+
isModuleLevel: boolean,
|
|
7
|
+
inTypeChecking: boolean,
|
|
8
|
+
}
|
|
2
9
|
export interface RecordEntry {
|
|
3
10
|
path: string,
|
|
4
11
|
hash?: string,
|
|
@@ -78,47 +85,50 @@ export interface ParsedRequirementsTxt {
|
|
|
78
85
|
noIndex: boolean,
|
|
79
86
|
}
|
|
80
87
|
import type * as VercelPythonAnalysisHostUtils from './interfaces/vercel-python-analysis-host-utils.js'; // vercel:python-analysis/host-utils
|
|
81
|
-
import type * as WasiCliEnvironment from './interfaces/wasi-cli-environment.js'; // wasi:cli/environment@0.2.
|
|
82
|
-
import type * as WasiCliExit from './interfaces/wasi-cli-exit.js'; // wasi:cli/exit@0.2.
|
|
83
|
-
import type * as WasiCliStderr from './interfaces/wasi-cli-stderr.js'; // wasi:cli/stderr@0.2.
|
|
84
|
-
import type * as WasiCliStdin from './interfaces/wasi-cli-stdin.js'; // wasi:cli/stdin@0.2.
|
|
85
|
-
import type * as WasiCliStdout from './interfaces/wasi-cli-stdout.js'; // wasi:cli/stdout@0.2.
|
|
86
|
-
import type * as WasiCliTerminalInput from './interfaces/wasi-cli-terminal-input.js'; // wasi:cli/terminal-input@0.2.
|
|
87
|
-
import type * as WasiCliTerminalOutput from './interfaces/wasi-cli-terminal-output.js'; // wasi:cli/terminal-output@0.2.
|
|
88
|
-
import type * as WasiCliTerminalStderr from './interfaces/wasi-cli-terminal-stderr.js'; // wasi:cli/terminal-stderr@0.2.
|
|
89
|
-
import type * as WasiCliTerminalStdin from './interfaces/wasi-cli-terminal-stdin.js'; // wasi:cli/terminal-stdin@0.2.
|
|
90
|
-
import type * as WasiCliTerminalStdout from './interfaces/wasi-cli-terminal-stdout.js'; // wasi:cli/terminal-stdout@0.2.
|
|
91
|
-
import type * as
|
|
92
|
-
import type * as
|
|
93
|
-
import type * as
|
|
94
|
-
import type * as
|
|
95
|
-
import type * as
|
|
96
|
-
import type * as
|
|
97
|
-
import type * as
|
|
88
|
+
import type * as WasiCliEnvironment from './interfaces/wasi-cli-environment.js'; // wasi:cli/environment@0.2.9
|
|
89
|
+
import type * as WasiCliExit from './interfaces/wasi-cli-exit.js'; // wasi:cli/exit@0.2.9
|
|
90
|
+
import type * as WasiCliStderr from './interfaces/wasi-cli-stderr.js'; // wasi:cli/stderr@0.2.9
|
|
91
|
+
import type * as WasiCliStdin from './interfaces/wasi-cli-stdin.js'; // wasi:cli/stdin@0.2.9
|
|
92
|
+
import type * as WasiCliStdout from './interfaces/wasi-cli-stdout.js'; // wasi:cli/stdout@0.2.9
|
|
93
|
+
import type * as WasiCliTerminalInput from './interfaces/wasi-cli-terminal-input.js'; // wasi:cli/terminal-input@0.2.9
|
|
94
|
+
import type * as WasiCliTerminalOutput from './interfaces/wasi-cli-terminal-output.js'; // wasi:cli/terminal-output@0.2.9
|
|
95
|
+
import type * as WasiCliTerminalStderr from './interfaces/wasi-cli-terminal-stderr.js'; // wasi:cli/terminal-stderr@0.2.9
|
|
96
|
+
import type * as WasiCliTerminalStdin from './interfaces/wasi-cli-terminal-stdin.js'; // wasi:cli/terminal-stdin@0.2.9
|
|
97
|
+
import type * as WasiCliTerminalStdout from './interfaces/wasi-cli-terminal-stdout.js'; // wasi:cli/terminal-stdout@0.2.9
|
|
98
|
+
import type * as WasiClocksMonotonicClock from './interfaces/wasi-clocks-monotonic-clock.js'; // wasi:clocks/monotonic-clock@0.2.9
|
|
99
|
+
import type * as WasiClocksWallClock from './interfaces/wasi-clocks-wall-clock.js'; // wasi:clocks/wall-clock@0.2.9
|
|
100
|
+
import type * as WasiFilesystemPreopens from './interfaces/wasi-filesystem-preopens.js'; // wasi:filesystem/preopens@0.2.9
|
|
101
|
+
import type * as WasiFilesystemTypes from './interfaces/wasi-filesystem-types.js'; // wasi:filesystem/types@0.2.9
|
|
102
|
+
import type * as WasiIoError from './interfaces/wasi-io-error.js'; // wasi:io/error@0.2.9
|
|
103
|
+
import type * as WasiIoPoll from './interfaces/wasi-io-poll.js'; // wasi:io/poll@0.2.9
|
|
104
|
+
import type * as WasiIoStreams from './interfaces/wasi-io-streams.js'; // wasi:io/streams@0.2.9
|
|
105
|
+
import type * as WasiRandomInsecureSeed from './interfaces/wasi-random-insecure-seed.js'; // wasi:random/insecure-seed@0.2.9
|
|
98
106
|
export interface ImportObject {
|
|
99
107
|
'vercel:python-analysis/host-utils': typeof VercelPythonAnalysisHostUtils,
|
|
100
|
-
'wasi:cli/environment@0.2.
|
|
101
|
-
'wasi:cli/exit@0.2.
|
|
102
|
-
'wasi:cli/stderr@0.2.
|
|
103
|
-
'wasi:cli/stdin@0.2.
|
|
104
|
-
'wasi:cli/stdout@0.2.
|
|
105
|
-
'wasi:cli/terminal-input@0.2.
|
|
106
|
-
'wasi:cli/terminal-output@0.2.
|
|
107
|
-
'wasi:cli/terminal-stderr@0.2.
|
|
108
|
-
'wasi:cli/terminal-stdin@0.2.
|
|
109
|
-
'wasi:cli/terminal-stdout@0.2.
|
|
110
|
-
'wasi:clocks/
|
|
111
|
-
'wasi:
|
|
112
|
-
'wasi:filesystem/
|
|
113
|
-
'wasi:
|
|
114
|
-
'wasi:io/
|
|
115
|
-
'wasi:io/
|
|
116
|
-
'wasi:
|
|
108
|
+
'wasi:cli/environment@0.2.9': typeof WasiCliEnvironment,
|
|
109
|
+
'wasi:cli/exit@0.2.9': typeof WasiCliExit,
|
|
110
|
+
'wasi:cli/stderr@0.2.9': typeof WasiCliStderr,
|
|
111
|
+
'wasi:cli/stdin@0.2.9': typeof WasiCliStdin,
|
|
112
|
+
'wasi:cli/stdout@0.2.9': typeof WasiCliStdout,
|
|
113
|
+
'wasi:cli/terminal-input@0.2.9': typeof WasiCliTerminalInput,
|
|
114
|
+
'wasi:cli/terminal-output@0.2.9': typeof WasiCliTerminalOutput,
|
|
115
|
+
'wasi:cli/terminal-stderr@0.2.9': typeof WasiCliTerminalStderr,
|
|
116
|
+
'wasi:cli/terminal-stdin@0.2.9': typeof WasiCliTerminalStdin,
|
|
117
|
+
'wasi:cli/terminal-stdout@0.2.9': typeof WasiCliTerminalStdout,
|
|
118
|
+
'wasi:clocks/monotonic-clock@0.2.9': typeof WasiClocksMonotonicClock,
|
|
119
|
+
'wasi:clocks/wall-clock@0.2.9': typeof WasiClocksWallClock,
|
|
120
|
+
'wasi:filesystem/preopens@0.2.9': typeof WasiFilesystemPreopens,
|
|
121
|
+
'wasi:filesystem/types@0.2.9': typeof WasiFilesystemTypes,
|
|
122
|
+
'wasi:io/error@0.2.9': typeof WasiIoError,
|
|
123
|
+
'wasi:io/poll@0.2.9': typeof WasiIoPoll,
|
|
124
|
+
'wasi:io/streams@0.2.9': typeof WasiIoStreams,
|
|
125
|
+
'wasi:random/insecure-seed@0.2.9': typeof WasiRandomInsecureSeed,
|
|
117
126
|
}
|
|
118
127
|
export interface Root {
|
|
119
128
|
findAppOrHandler(source: string): string | undefined,
|
|
120
129
|
getStringConstant(source: string, name: string): string | undefined,
|
|
121
130
|
containsTopLevelCallable(source: string, name: string): boolean,
|
|
131
|
+
extractImports(source: string): Array<ImportStmt>,
|
|
122
132
|
parseDistMetadata(content: Uint8Array): DistMetadata,
|
|
123
133
|
parseRecord(content: string): Array<RecordEntry>,
|
|
124
134
|
parseDirectUrl(content: string): DirectUrlInfo,
|