@motherduck/wasm-client 0.6.0 → 0.6.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.
Files changed (59) hide show
  1. package/README.md +38 -22
  2. package/index.js +1 -1
  3. package/index_with_arrow.js +11 -11
  4. package/package.json +2 -2
  5. package/types/DuckDBInstance.d.ts +3 -0
  6. package/types/{api.d.ts → MDConnection.d.ts} +6 -4
  7. package/types/MDConnectionParams.d.ts +11 -0
  8. package/types/QueryTypes.d.ts +17 -5
  9. package/types/TaskSequencer.d.ts +1 -0
  10. package/types/createDuckDbConnection.d.ts +3 -0
  11. package/types/fetchDuckDBAssets.d.ts +17 -0
  12. package/types/fetchVersion.d.ts +1 -0
  13. package/types/genConnectionId.d.ts +1 -0
  14. package/types/getAsyncDuckDb.d.ts +3 -0
  15. package/types/getDuckDBBundlesFromDuckDBAssets.d.ts +2 -0
  16. package/types/getVersionSuffix.d.ts +1 -0
  17. package/types/index.d.ts +9 -9
  18. package/types/instantiateDB.d.ts +2 -0
  19. package/types/{duckdb/files.d.ts → readLocalFS.d.ts} +1 -5
  20. package/types/recursivelyPrefix.d.ts +1 -0
  21. package/types/registerFiles.d.ts +5 -0
  22. package/types/transformQueryError.d.ts +2 -0
  23. package/types/urlPathConcat.d.ts +1 -0
  24. package/types/arrow/AsyncDuckDBRecordBatchIterator.d.ts +0 -13
  25. package/types/arrow/DuckDBRecordBatch.d.ts +0 -14
  26. package/types/arrow/TypedTypeMap.d.ts +0 -2
  27. package/types/arrow/duckDBTypeFromArrowType.d.ts +0 -4
  28. package/types/arrow/duckDBValueFromArrowData.d.ts +0 -8
  29. package/types/createDeferred.d.ts +0 -6
  30. package/types/duckdb/AsyncDuckDBDataBatchIterator.d.ts +0 -3
  31. package/types/duckdb/DuckDBData.d.ts +0 -56
  32. package/types/duckdb/DuckDBDataReader.d.ts +0 -68
  33. package/types/duckdb/DuckDBRow.d.ts +0 -4
  34. package/types/duckdb/conversion/dateTimeStringConversion.d.ts +0 -12
  35. package/types/duckdb/conversion/displayStringForDuckDBValue.d.ts +0 -2
  36. package/types/duckdb/conversion/stringFromBlob.d.ts +0 -2
  37. package/types/duckdb/conversion/stringFromDecimal.d.ts +0 -18
  38. package/types/duckdb/types/DuckDBType.d.ts +0 -110
  39. package/types/duckdb/types/DuckDBTypes.d.ts +0 -39
  40. package/types/duckdb/types/index.d.ts +0 -2
  41. package/types/duckdb/values/DuckDBBlob.d.ts +0 -6
  42. package/types/duckdb/values/DuckDBDate.d.ts +0 -6
  43. package/types/duckdb/values/DuckDBDecimal.d.ts +0 -10
  44. package/types/duckdb/values/DuckDBInterval.d.ts +0 -8
  45. package/types/duckdb/values/DuckDBList.d.ts +0 -7
  46. package/types/duckdb/values/DuckDBMap.d.ts +0 -7
  47. package/types/duckdb/values/DuckDBMapEntry.d.ts +0 -5
  48. package/types/duckdb/values/DuckDBStruct.d.ts +0 -7
  49. package/types/duckdb/values/DuckDBStructEntry.d.ts +0 -5
  50. package/types/duckdb/values/DuckDBTime.d.ts +0 -6
  51. package/types/duckdb/values/DuckDBTimestampMicroseconds.d.ts +0 -8
  52. package/types/duckdb/values/DuckDBTimestampMilliseconds.d.ts +0 -6
  53. package/types/duckdb/values/DuckDBTimestampNanoseconds.d.ts +0 -6
  54. package/types/duckdb/values/DuckDBTimestampSeconds.d.ts +0 -6
  55. package/types/duckdb/values/DuckDBValue.d.ts +0 -2
  56. package/types/duckdb/values/SpecialDuckDBValue.d.ts +0 -4
  57. package/types/duckdb/values/index.d.ts +0 -16
  58. package/types/duckdb/worker_factory.d.ts +0 -15
  59. package/types/observability.d.ts +0 -26
@@ -1,5 +0,0 @@
1
- import { DuckDBValue } from './DuckDBValue';
2
- export interface DuckDBMapEntry {
3
- readonly key: DuckDBValue;
4
- readonly value: DuckDBValue;
5
- }
@@ -1,7 +0,0 @@
1
- import { DuckDBStructEntry } from './DuckDBStructEntry';
2
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
3
- export declare class DuckDBStruct extends SpecialDuckDBValue {
4
- readonly entries: readonly DuckDBStructEntry[];
5
- constructor(entries: readonly DuckDBStructEntry[]);
6
- toDuckDBString(): string;
7
- }
@@ -1,5 +0,0 @@
1
- import { DuckDBValue } from './DuckDBValue';
2
- export interface DuckDBStructEntry {
3
- readonly key: string;
4
- readonly value: DuckDBValue;
5
- }
@@ -1,6 +0,0 @@
1
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
2
- export declare class DuckDBTime extends SpecialDuckDBValue {
3
- readonly microseconds: bigint;
4
- constructor(microseconds: bigint);
5
- toDuckDBString(): string;
6
- }
@@ -1,8 +0,0 @@
1
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
2
- export declare class DuckDBTimestampMicroseconds extends SpecialDuckDBValue {
3
- readonly microseconds: bigint;
4
- readonly timezone: string | null | undefined;
5
- constructor(microseconds: bigint, timezone?: string | null);
6
- toDuckDBString(): string;
7
- }
8
- export type DuckDBTimestamp = DuckDBTimestampMicroseconds;
@@ -1,6 +0,0 @@
1
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
2
- export declare class DuckDBTimestampMilliseconds extends SpecialDuckDBValue {
3
- readonly milliseconds: bigint;
4
- constructor(milliseconds: bigint);
5
- toDuckDBString(): string;
6
- }
@@ -1,6 +0,0 @@
1
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
2
- export declare class DuckDBTimestampNanoseconds extends SpecialDuckDBValue {
3
- readonly nanoseconds: bigint;
4
- constructor(nanoseconds: bigint);
5
- toDuckDBString(): string;
6
- }
@@ -1,6 +0,0 @@
1
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
2
- export declare class DuckDBTimestampSeconds extends SpecialDuckDBValue {
3
- readonly seconds: bigint;
4
- constructor(seconds: bigint);
5
- toDuckDBString(): string;
6
- }
@@ -1,2 +0,0 @@
1
- import { SpecialDuckDBValue } from './SpecialDuckDBValue';
2
- export type DuckDBValue = null | boolean | number | string | bigint | SpecialDuckDBValue;
@@ -1,4 +0,0 @@
1
- export declare abstract class SpecialDuckDBValue {
2
- abstract toDuckDBString(): string;
3
- toString(): string;
4
- }
@@ -1,16 +0,0 @@
1
- export { DuckDBBlob } from './DuckDBBlob';
2
- export { DuckDBDate } from './DuckDBDate';
3
- export { DuckDBDecimal } from './DuckDBDecimal';
4
- export { DuckDBInterval } from './DuckDBInterval';
5
- export { DuckDBList } from './DuckDBList';
6
- export { DuckDBMap } from './DuckDBMap';
7
- export { DuckDBMapEntry } from './DuckDBMapEntry';
8
- export { DuckDBStruct } from './DuckDBStruct';
9
- export { DuckDBStructEntry } from './DuckDBStructEntry';
10
- export { DuckDBTime } from './DuckDBTime';
11
- export { DuckDBTimestampMicroseconds } from './DuckDBTimestampMicroseconds';
12
- export { DuckDBTimestampMilliseconds } from './DuckDBTimestampMilliseconds';
13
- export { DuckDBTimestampNanoseconds } from './DuckDBTimestampNanoseconds';
14
- export { DuckDBTimestampSeconds } from './DuckDBTimestampSeconds';
15
- export { DuckDBValue } from './DuckDBValue';
16
- export { SpecialDuckDBValue } from './SpecialDuckDBValue';
@@ -1,15 +0,0 @@
1
- import { AsyncDuckDB, AsyncDuckDBConnection } from '@duckdb/duckdb-wasm';
2
- import { LogSink } from '../LogSink';
3
- export interface MDConnectionParams {
4
- mdToken: string;
5
- mdServerURL?: string;
6
- duckDBAssetsURLPrefix?: string;
7
- useDuckDBWasmCOI?: boolean;
8
- logSink?: LogSink;
9
- skipWelcomePack?: boolean;
10
- version?: string;
11
- enableDebugLogging?: boolean;
12
- }
13
- export declare const CATALOG_CHANGE_EVENT = "CatalogChangeEvent";
14
- export declare function createDuckDbConnection(params: MDConnectionParams): Promise<AsyncDuckDBConnection>;
15
- export declare function getAsyncDuckDb(params: MDConnectionParams): Promise<AsyncDuckDB>;
@@ -1,26 +0,0 @@
1
- export interface Logger {
2
- debug(message: string, context?: any): void;
3
- info(message: string, context?: any): void;
4
- log(message: string, context?: any): void;
5
- warn(message: string, context?: any): void;
6
- error(message: string, context?: any): void;
7
- userAction(name: string, context?: any): void;
8
- appAction(name: string, context: any): void;
9
- startSpan(name: string, context?: any): Span;
10
- finishSpan(span: Span): void;
11
- }
12
- export declare class Span {
13
- startTimeMs: number;
14
- timeTakenMs: number;
15
- name: string;
16
- logger: Logger;
17
- context: any;
18
- spanId: string;
19
- private internalError;
20
- constructor(name: string, logger: Logger, context: any);
21
- finish(): void;
22
- setContextProperty(key: string, value: any): void;
23
- get error(): Error | null;
24
- set error(err: Error | null);
25
- }
26
- export declare function sanitize(queryText: string): string;