diff --git a/.changeset/zero-rust-inspector.md b/.changeset/zero-rust-inspector.md new file mode 100644 index 0000000000..18c844d6d5 --- /dev/null +++ b/.changeset/zero-rust-inspector.md @@ -0,0 +1,5 @@ +--- +'zero-rust': minor +--- + +Add JS's inspector and query metrics. `Zero::inspector()` returns an `Inspector` that lists the clients in the local store and their queries (with each query's ZQL, row count, and timings), reads a client's stored data and rows, fetches zero-cache's version and the client's metrics merged with the server's, and asks zero-cache to analyze a query (`analyze_query`, `analyze_server_ast`, `analyze_named_query`). When zero-cache requires its admin password, an inspector call fails until `authenticate(password)` succeeds, and the accepted password is presented again after a reconnect. The client now records JS's `query-materialization-client`, `query-materialization-end-to-end`, and `query-update-client` metrics as `tdigest::TDigest`s, and logs each query's end-to-end materialization, as a warning when it takes longer than the new `ZeroOptions::slow_materialize_threshold_ms` (5,000 by default). diff --git a/packages/zero-conformance/src/client/harness.ts b/packages/zero-conformance/src/client/harness.ts index eb26e2f50d..120c58e492 100644 --- a/packages/zero-conformance/src/client/harness.ts +++ b/packages/zero-conformance/src/client/harness.ts @@ -13,12 +13,22 @@ */ import {vi} from 'vitest'; import type {ReadonlyJSONValue} from '../../../shared/src/json.ts'; +import type {TDigest} from '../../../shared/src/tdigest.ts'; +import type {Client} from '../../../zero-client/src/client/inspector/client.ts'; +// Loaded now, so the inspector's lazy import of it settles with the step. +import '../../../zero-client/src/client/inspector/lazy-inspector.ts'; +import type {Metrics} from '../../../zero-client/src/client/inspector/lazy-inspector.ts'; +import type {Query} from '../../../zero-client/src/client/inspector/query.ts'; import { MockSocket, TestZero, } from '../../../zero-client/src/client/test-utils.ts'; +import type {PlanDebugEventJSON} from '../../../zero-protocol/src/analyze-query-result.ts'; +import type {AST} from '../../../zero-protocol/src/ast.ts'; import {decodeSecProtocols} from '../../../zero-protocol/src/connect.ts'; +import type {AnalyzeQueryOptions} from '../../../zero-protocol/src/inspect-up.ts'; import {POKE_CHUNK_MESSAGE_TYPE} from '../../../zero-protocol/src/poke.ts'; +import {addContextToQuery} from '../../../zql/src/query/query-registry.ts'; import type {TTL} from '../../../zql/src/query/ttl.ts'; import {issueMutators, mutators, queries, schema} from './app.ts'; @@ -50,8 +60,33 @@ export type ScenarioOptions = { * wrapped view or `listen` listener calls, with how many. */ batchViewUpdates?: boolean | undefined; + /** Defaults to 5000, the JS default. */ + slowMaterializeThreshold?: number | undefined; + /** + * Defaults to `warn`. The materialization messages at this level and + * above are reported in `logs`. + */ + logLevel?: 'debug' | 'info' | 'warn' | 'error' | undefined; }; +/** The calls of `zero.inspector` an `inspect` step can make. */ +export type InspectMethod = + | 'metrics' + | 'serverVersion' + | 'clients' + | 'clientsWithQueries' + | 'clientQueries' + | 'clientMap' + | 'clientRows' + | 'clientGroupClients' + | 'clientGroupClientsWithQueries' + | 'clientGroupQueries' + | 'analyzeQuery' + | 'analyzeServerAST' + | 'analyzeNamedQuery' + | 'authenticate' + | 'formatPlannerEvents'; + export type Step = | {op: 'materialize'; view: string; query: string; args?: Args; ttl?: TTL} | {op: 'destroy'; view: string} @@ -148,7 +183,32 @@ export type Step = actions?: Step[]; } /** Removes a listener added by `listen`. */ - | {op: 'unlisten'; listener: string}; + | {op: 'unlisten'; listener: string} + /** + * Calls `zero.inspector.` (`client` and `clientGroup` methods on + * `inspector.client` and `inspector.clientGroup`); its result is reported + * in `inspector` under `call`. `query` and `args` name the query of + * `analyzeQuery`; `ast` is `analyzeServerAST`'s, `name` and `queryArgs` + * are `analyzeNamedQuery`'s, `table` is `clientRows`'s, and `password` is + * `authenticate`'s, and `events` is `formatPlannerEvents`'s. The client sends each request with a new ID; the + * n-th sent in the scenario is `$inspect.`, which a downstream message + * answers. JS's password prompt, where the server refuses an unauthenticated + * request, answers nothing: the request fails. + */ + | { + op: 'inspect'; + call: string; + method: InspectMethod; + query?: string; + args?: Args; + ast?: AST; + name?: string; + queryArgs?: ReadonlyJSONValue[]; + table?: string; + options?: AnalyzeQueryOptions; + password?: string; + events?: PlanDebugEventJSON[]; + }; type Args = ReadonlyJSONValue | undefined; @@ -207,6 +267,19 @@ export type StepResult = { preloads?: Record; /** `onUpdateNeeded`, `onClientStateNotFound`, and `batchViewUpdates` calls. */ events?: ReadonlyJSONValue[]; + /** + * The `inspect` calls: `pending`, `{resolved}` with the value as JSON + * (queries as their fields, digests as their JSON, clients as + * `{id, clientGroupID}` sorted by ID, a map as its entries), or + * `{rejected}` with the error's message. + */ + inspector?: Record; + /** + * The materialization messages logged during the step (`Slow query + * materialization ...` and `Materialized query ...`): level, and the + * message, query ID, AST, and ms. + */ + logs?: {level: string; args: ReadonlyJSONValue[]}[]; /** * Listeners added by `listen`, in order: the data and result type of * each call during the step. @@ -333,6 +406,8 @@ export async function runScenario(scenario: Scenario): Promise { queryURL: options.queryURL, queryHeaders: options.queryHeaders, hiddenTabDisconnectDelay: options.hiddenTabDisconnectDelay, + slowMaterializeThreshold: options.slowMaterializeThreshold, + logLevel: options.logLevel, batchViewUpdates: options.batchViewUpdates ? apply => { const before = listenerCalls; @@ -424,6 +499,43 @@ export async function runScenario(scenario: Scenario): Promise { } >(); + const inspectCalls = new Map(); + let inspectCount = 0; + // JS prompts for the admin password; a native client can't. + vi.stubGlobal('prompt', () => null); + let logsSeen = 0; + const materializationLogs = () => { + const messages = z.testLogSink.messages; + const out: {level: string; args: ReadonlyJSONValue[]}[] = []; + for (const [level, , args] of messages.slice(logsSeen)) { + const [message] = args; + if ( + message === 'Slow query materialization (including server/network)' || + message === 'Materialized query (including server/network)' + ) { + out.push({level, args: args.map(json)}); + } + } + logsSeen = messages.length; + return out; + }; + const normalizeKey = (k: string) => { + for (const [id, placeholder] of placeholders) { + k = k.replaceAll(id, placeholder); + } + return k; + }; + const clientsJSON = async (clients: Client[]) => { + const out = []; + for (const c of clients) { + out.push({ + id: placeholders.get(c.id) ?? c.id, + clientGroupID: normalize(await c.clientGroup.id), + }); + } + return out.sort((a, b) => (a.id < b.id ? -1 : a.id > b.id ? 1 : 0)); + }; + const targetSocket = (index: number | undefined) => { const socket = index === undefined ? sockets.at(-1) : sockets[index]; if (!socket) throw new Error('No socket'); @@ -624,6 +736,78 @@ export async function runScenario(scenario: Scenario): Promise { case 'unlisten': listeners.get(step.listener)?.remove(); return; + case 'inspect': { + const {inspector} = z; + const {call} = step; + inspectCalls.set(call, 'pending'); + const record = ( + p: Promise, + convert: (v: T) => unknown = v => v, + ) => + p.then( + async v => + inspectCalls.set(call, {resolved: json(await convert(v))}), + e => inspectCalls.set(call, {rejected: errorMessage(e)}), + ); + const options = step.options; + switch (step.method) { + case 'metrics': + return void record(inspector.metrics(), metricsJSON); + case 'serverVersion': + return void record(inspector.serverVersion()); + case 'clients': + return void record(inspector.clients(), clientsJSON); + case 'clientsWithQueries': + return void record(inspector.clientsWithQueries(), clientsJSON); + case 'clientQueries': + return void record(inspector.client.queries(), queriesJSON); + case 'clientMap': + return void record(inspector.client.map(), m => + Array.from(m, ([k, v]) => [normalizeKey(k), v]), + ); + case 'clientRows': + return void record(inspector.client.rows(step.table ?? '')); + case 'clientGroupClients': + return void record(inspector.clientGroup.clients(), clientsJSON); + case 'clientGroupClientsWithQueries': + return void record( + inspector.clientGroup.clientsWithQueries(), + clientsJSON, + ); + case 'clientGroupQueries': + return void record(inspector.clientGroup.queries(), queriesJSON); + case 'analyzeQuery': + return void record( + inspector.analyzeQuery( + addContextToQuery( + request(step.query ?? '', step.args), + z.context, + ), + options, + ), + ); + case 'analyzeServerAST': + return void record( + inspector.analyzeServerAST(step.ast as AST, options), + ); + case 'analyzeNamedQuery': + return void record( + inspector.analyzeNamedQuery( + step.name ?? '', + step.queryArgs ?? [], + options, + ), + ); + case 'authenticate': + return void record(inspector.authenticate(step.password ?? '')); + case 'formatPlannerEvents': + inspectCalls.set(call, { + resolved: inspector.formatPlannerEvents(step.events ?? []), + }); + return; + } + return; + } case 'restart': { await z.close(); await settle(); @@ -648,6 +832,8 @@ export async function runScenario(scenario: Scenario): Promise { mutations.clear(); runs.clear(); preloads.clear(); + inspectCalls.clear(); + logsSeen = 0; return; } } @@ -675,9 +861,18 @@ export async function runScenario(scenario: Scenario): Promise { })); if (opened.length > 0) result.opened = opened; const sent = sockets.flatMap((s, i) => - s.messages - .slice(sentCounts[i] ?? 0) - .map(m => normalize(JSON.parse(m) as ReadonlyJSONValue)), + s.messages.slice(sentCounts[i] ?? 0).map(m => { + const message = JSON.parse(m) as ReadonlyJSONValue; + if (Array.isArray(message) && message[0] === 'inspect') { + const {id} = message[1] as {id: string}; + if (!placeholders.has(id)) { + const placeholder = `$inspect.${inspectCount++}`; + placeholders.set(id, placeholder); + ids.set(placeholder, id); + } + } + return normalize(message); + }), ); if (sent.length > 0) result.sent = sent; const closed = sockets.flatMap((s, i) => @@ -711,6 +906,18 @@ export async function runScenario(scenario: Scenario): Promise { if (events.length > 0) { result.events = events.splice(0); } + if (inspectCalls.size > 0) { + result.inspector = normalize( + json(Object.fromEntries(inspectCalls)), + ) as Record; + } + const logs = materializationLogs(); + if (logs.length > 0) { + result.logs = logs.map(l => ({ + level: l.level, + args: l.args.map(a => normalize(a)), + })); + } if (listeners.size > 0) { result.listeners = Object.fromEntries( Array.from(listeners, ([k, v]) => [ @@ -758,3 +965,33 @@ function socketURL( } return {origin: url.origin, path: url.pathname, query}; } + +function metricsJSON(metrics: Metrics): ReadonlyJSONValue { + return Object.fromEntries( + Object.entries(metrics).map(([k, d]) => [k, (d as TDigest).toJSON()]), + ); +} + +function queriesJSON(queries: Query[]): ReadonlyJSONValue { + return queries.map(q => ({ + name: q.name, + args: q.args, + got: q.got, + ttl: q.ttl, + inactivatedAt: q.inactivatedAt === null ? null : q.inactivatedAt.getTime(), + rowCount: q.rowCount, + deleted: q.deleted, + id: q.id, + clientID: q.clientID, + metrics: q.metrics === null ? null : metricsJSON(q.metrics), + clientZQL: q.clientZQL, + serverZQL: q.serverZQL, + hydrateClient: q.hydrateClient, + hydrateServer: q.hydrateServer, + hydrateTotal: q.hydrateTotal, + updateClientP50: q.updateClientP50, + updateClientP95: q.updateClientP95, + updateServerP50: q.updateServerP50, + updateServerP95: q.updateServerP95, + })); +} diff --git a/packages/zero-conformance/src/client/inspector.test.ts b/packages/zero-conformance/src/client/inspector.test.ts new file mode 100644 index 0000000000..38e7b5effc --- /dev/null +++ b/packages/zero-conformance/src/client/inspector.test.ts @@ -0,0 +1,26 @@ +import {test} from 'vitest'; +import {emitVectors} from '../vectors.ts'; +import { + runScenario, + START_TIME, + type Scenario, + type StepResult, +} from './harness.ts'; +import {inspectorScenarios} from './scenarios/inspector.ts'; + +type Case = Scenario & {expect: StepResult[]}; + +test('client inspector scenarios', {timeout: 600_000}, async () => { + const cases: Case[] = []; + for (const scenario of inspectorScenarios) { + cases.push({...scenario, expect: await runScenario(scenario)}); + } + emitVectors( + 'client-inspector', + 'client-scenarios', + 'Inspector scenarios run against the JS zero-client like vectors/client.json (see src/client/harness.ts): the inspect step, the RPCs it sends and how their answers resolve, the query metrics, and the slow materialization logs.', + cases, + {startTime: START_TIME}, + {compact: true}, + ); +}); diff --git a/packages/zero-conformance/src/client/scenarios/inspector.ts b/packages/zero-conformance/src/client/scenarios/inspector.ts new file mode 100644 index 0000000000..19d6b8b3f9 --- /dev/null +++ b/packages/zero-conformance/src/client/scenarios/inspector.ts @@ -0,0 +1,552 @@ +/** + * The inspector: its RPCs over the socket (metrics, version, queries, + * analyze, authenticate) and how it resolves the server's answers, its view + * of the local store, and the query metrics and slow materialization logs. + */ +import type {ReadonlyJSONValue} from '../../../../shared/src/json.ts'; +import type {PlanDebugEventJSON} from '../../../../zero-protocol/src/analyze-query-result.ts'; +import type {Scenario, Step} from '../harness.ts'; +import { + advance, + connected, + issue, + mutate, + put, + queryHash, + start, + syncPoke, + user, +} from './helpers.ts'; + +const allHash = queryHash('issues.all'); +const usersHash = queryHash('users.all'); +const byOwnerU1 = queryHash('issues.byOwner', 'u1'); + +function answer(n: number, op: string, value: ReadonlyJSONValue): Step { + return { + op: 'receive', + message: ['inspect', {op, id: `$inspect.${n}`, value}], + }; +} + +const authenticated = (n: number, value: boolean) => + answer(n, 'authenticated', value); + +const serverMetrics = { + 'query-materialization-server': [100, 5, 1, 7.5, 2, 40, 1], + 'query-update-server': [100, 0.5, 3, 1.25, 1], +}; + +/** Issue rows i00..i, as the server sends them. */ +function issues(n: number) { + return Array.from({length: n}, (_, i) => + put('issues', issue(`i${String(i).padStart(2, '0')}`)), + ); +} + +const queryRows = [ + { + clientID: '$clientID', + queryID: allHash, + ast: {table: 'issues', orderBy: [['id', 'asc']]}, + name: 'issues.all', + args: [], + got: true, + deleted: false, + ttl: 300_000, + inactivatedAt: null, + rowCount: 40, + metrics: { + 'query-hydration-server-ms': 12.5, + 'query-update-server': [100, 1, 2, 3, 1, 9, 1], + }, + }, + { + clientID: '$clientID', + queryID: usersHash, + ast: null, + name: 'users.all', + args: [], + got: true, + deleted: false, + ttl: 60_000, + inactivatedAt: 1_700_000_000_123.5, + rowCount: 1, + }, + { + clientID: 'other-client', + queryID: 'q-unknown', + ast: { + table: 'issues', + where: { + type: 'simple', + op: '=', + left: {type: 'column', name: 'owner_id'}, + right: {type: 'literal', value: "o'k"}, + }, + limit: 3, + }, + name: null, + args: null, + got: false, + deleted: true, + ttl: -1, + inactivatedAt: null, + rowCount: 0, + metrics: { + 'query-hydration-server-ms': 40, + 'query-update-server': [100], + }, + }, +]; + +const joinPlans: PlanDebugEventJSON[] = [ + {type: 'attempt-start', attemptNumber: 0, totalAttempts: 2}, + { + type: 'node-cost', + attemptNumber: 0, + nodeType: 'connection', + node: 'issues', + branchPattern: [0], + downstreamChildSelectivity: 0.125, + costEstimate: { + startupCost: 0, + scanEst: 100, + cost: 100.005, + returnedRows: 10, + selectivity: 0.1, + limit: 3, + }, + filters: { + type: 'simple', + op: '=', + left: {type: 'column', name: 'owner_id'}, + right: {type: 'literal', value: 'u1'}, + }, + ordering: [['id', 'asc']], + }, + { + type: 'node-constraint', + attemptNumber: 0, + nodeType: 'connection', + node: 'issues', + branchPattern: [0], + constraint: {owner_id: null}, + from: 'join', + }, + { + type: 'node-cost', + attemptNumber: 0, + nodeType: 'join', + node: 'join(issues,comments)', + branchPattern: [], + downstreamChildSelectivity: 1, + costEstimate: { + startupCost: 1, + scanEst: 2, + cost: 3.333, + returnedRows: 4, + selectivity: 1, + }, + joinType: 'semi', + }, + { + type: 'plan-complete', + attemptNumber: 0, + totalCost: 103.338, + flipPattern: 0, + joinStates: [{join: 'join(issues,comments)', type: 'semi'}], + }, + {type: 'attempt-start', attemptNumber: 1, totalAttempts: 2}, + {type: 'plan-failed', attemptNumber: 1, reason: 'unflippable join'}, + { + type: 'best-plan-selected', + bestAttemptNumber: 0, + totalCost: 103.338, + flipPattern: 0, + joinStates: [{join: 'join(issues,comments)', type: 'semi'}], + }, +]; + +/** Shapes `joinPlans` lacks: more attempts, every value kind, no best plan. */ +const morePlans: PlanDebugEventJSON[] = [ + {type: 'attempt-start', attemptNumber: 2, totalAttempts: 5}, + { + type: 'node-cost', + attemptNumber: 2, + nodeType: 'connection', + node: 'comments', + branchPattern: [1, 0], + downstreamChildSelectivity: 0.000000125, + costEstimate: { + startupCost: 2.675, + scanEst: 1e21, + cost: 0.125, + returnedRows: 1.005, + selectivity: 0.123456785, + }, + filters: { + type: 'and', + conditions: [ + { + type: 'simple', + op: 'IN', + left: {type: 'column', name: 'id'}, + right: {type: 'literal', value: ['a', 1]}, + }, + { + type: 'or', + conditions: [ + { + type: 'simple', + op: '>', + left: { + type: 'json', + value: {type: 'column', name: 'm'}, + path: ['a', 0], + }, + right: {type: 'static', anchor: 'authData', field: ['x', 'y']}, + }, + { + type: 'correlatedSubquery', + op: 'EXISTS', + related: { + correlation: {parentField: ['id'], childField: ['issue_id']}, + subquery: {table: 'issues', alias: 'zsubq_issue'}, + }, + }, + ], + }, + ], + }, + }, + { + type: 'node-constraint', + attemptNumber: 2, + nodeType: 'connection', + node: 'comments', + branchPattern: [1, 0], + constraint: {}, + from: 'x', + }, + { + type: 'node-cost', + attemptNumber: 2, + nodeType: 'join', + node: 'j', + branchPattern: [], + downstreamChildSelectivity: 1, + costEstimate: { + startupCost: 0, + scanEst: 0, + cost: 0, + returnedRows: 0, + selectivity: 0, + limit: 0, + }, + }, + { + type: 'node-cost', + nodeType: 'filter', + node: 'f', + branchPattern: [], + downstreamChildSelectivity: 1, + costEstimate: { + startupCost: 0, + scanEst: 0, + cost: 0, + returnedRows: 0, + selectivity: 0, + }, + }, + { + type: 'plan-complete', + attemptNumber: 2, + totalCost: 1.005, + flipPattern: 1, + joinStates: [], + }, + {type: 'attempt-start', attemptNumber: 1, totalAttempts: 1}, + { + type: 'best-plan-selected', + bestAttemptNumber: 2, + totalCost: 0.125, + flipPattern: 1, + joinStates: [], + }, +]; + +const analyzeResult = { + warnings: ['a warning'], + syncedRows: {issues: [issue('i1')]}, + syncedRowCount: 1, + start: 1000, + end: 1012.5, + elapsed: 12.5, + afterPermissions: "issues.where('owner_id', 'u1')", + vendedRowCounts: {issues: {'SELECT 1': 3}}, + sqlitePlans: {'SELECT 1': ['SCAN issues']}, + readRowCount: 3, + // The events' optional fields are undefined-able, which JSON values aren't. + joinPlans: joinPlans as unknown as ReadonlyJSONValue, +}; + +export const inspectorScenarios: Scenario[] = [ + { + name: 'inspector: serverVersion sends version and resolves with the answer', + steps: [ + start, + connected, + {op: 'inspect', call: 'v', method: 'serverVersion'}, + answer(0, 'version', '0.26.1'), + ], + }, + { + name: 'inspector: a request made before the connection is sent once connected', + steps: [ + start, + {op: 'inspect', call: 'v', method: 'serverVersion'}, + advance(10), + connected, + answer(0, 'version', '0.26.1'), + ], + }, + { + name: 'inspector: an error answer rejects; answers to other IDs are ignored', + steps: [ + start, + connected, + {op: 'inspect', call: 'a', method: 'serverVersion'}, + {op: 'inspect', call: 'b', method: 'serverVersion'}, + { + op: 'receive', + message: ['inspect', {op: 'version', id: 'nobody', value: 'x'}], + }, + answer(1, 'error', 'Unknown inspector op'), + answer(0, 'version', '1.0.0'), + ], + }, + { + name: 'inspector: metrics merges the client metrics with the server digests; slow materializations warn', + options: {slowMaterializeThreshold: 50, logLevel: 'debug'}, + steps: [ + start, + connected, + {op: 'materialize', view: 'all', query: 'issues.all'}, + advance(100), + ...syncPoke('p1', null, '01', [allHash], issues(40)), + {op: 'materialize', view: 'users', query: 'users.all'}, + advance(10), + ...syncPoke( + 'p2', + '01', + '02', + [usersHash], + [put('users', user('u1', 'A'))], + ), + ...syncPoke('p3', '02', '03', [], issues(70).slice(30)), + mutate('m1', 'issue.create', {id: 'j1'}), + {op: 'inspect', call: 'metrics', method: 'metrics'}, + answer(0, 'metrics', serverMetrics), + ], + }, + { + name: 'inspector: slowMaterializeThreshold at its default logs nothing at warn', + steps: [ + start, + connected, + {op: 'materialize', view: 'all', query: 'issues.all'}, + advance(4990), + ...syncPoke('p1', null, '01', [allHash], issues(1)), + {op: 'materialize', view: 'users', query: 'users.all'}, + advance(5001), + ...syncPoke('p2', '01', '02', [usersHash]), + ], + }, + { + name: 'inspector: queries of the client and of its group, with the client and server metrics', + steps: [ + start, + connected, + {op: 'materialize', view: 'users', query: 'users.all'}, + advance(10), + ...syncPoke( + 'p1', + null, + '01', + [usersHash], + [put('users', user('u1', 'A'))], + ), + // Evicted before the inspector exists: forgotten. + {op: 'destroy', view: 'users'}, + advance(10), + {op: 'inspect', call: 'version', method: 'serverVersion'}, + answer(0, 'version', '1'), + {op: 'materialize', view: 'all', query: 'issues.all'}, + advance(25), + ...syncPoke('p2', '01', '02', [allHash], issues(40)), + // Evicted once the inspector exists: kept for it. + {op: 'destroy', view: 'all'}, + advance(10), + {op: 'inspect', call: 'client', method: 'clientQueries'}, + answer(1, 'queries', queryRows), + {op: 'inspect', call: 'group', method: 'clientGroupQueries'}, + answer(2, 'queries', [queryRows[2], queryRows[0]]), + ], + }, + { + name: 'inspector: analyzeQuery, analyzeServerAST, and analyzeNamedQuery', + steps: [ + start, + connected, + { + op: 'inspect', + call: 'named', + method: 'analyzeQuery', + query: 'issues.byOwner', + args: 'u1', + options: {vendedRows: true, joinPlans: true}, + }, + { + op: 'inspect', + call: 'ast', + method: 'analyzeServerAST', + ast: { + table: 'issues', + where: { + type: 'simple', + op: '=', + left: {type: 'column', name: 'owner_id'}, + right: {type: 'literal', value: 'u1'}, + }, + orderBy: [['id', 'asc']], + }, + options: {syncedRows: false}, + }, + { + op: 'inspect', + call: 'byName', + method: 'analyzeNamedQuery', + name: 'issues.byOwner', + queryArgs: ['u2'], + }, + answer(0, 'analyze-query', analyzeResult), + answer(1, 'analyze-query', { + warnings: [], + syncedRowCount: 0, + start: 1, + end: 2, + }), + answer(2, 'error', 'No query named issues.byOwner'), + { + op: 'inspect', + call: 'formatted', + method: 'formatPlannerEvents', + events: joinPlans, + }, + { + op: 'inspect', + call: 'formattedMore', + method: 'formatPlannerEvents', + events: morePlans, + }, + {op: 'inspect', call: 'formattedNone', method: 'formatPlannerEvents'}, + ], + }, + { + name: 'inspector: authenticate, then a refused request presents the accepted password again', + steps: [ + start, + connected, + {op: 'inspect', call: 'auth', method: 'authenticate', password: 'secret'}, + authenticated(0, true), + {op: 'inspect', call: 'v', method: 'serverVersion'}, + authenticated(1, false), + authenticated(2, true), + answer(3, 'version', '2.0.0'), + ], + }, + { + name: 'inspector: unauthenticated without a password fails; a refused password resolves false', + steps: [ + start, + connected, + {op: 'inspect', call: 'v1', method: 'serverVersion'}, + authenticated(0, false), + {op: 'inspect', call: 'wrong', method: 'authenticate', password: 'nope'}, + authenticated(1, false), + {op: 'inspect', call: 'v2', method: 'metrics'}, + authenticated(2, false), + {op: 'inspect', call: 'right', method: 'authenticate', password: 'pw'}, + authenticated(3, true), + {op: 'inspect', call: 'v3', method: 'metrics'}, + answer(4, 'metrics', serverMetrics), + ], + }, + { + name: 'inspector: after a reconnect the accepted password is presented before retrying', + steps: [ + start, + connected, + {op: 'inspect', call: 'auth', method: 'authenticate', password: 'secret'}, + authenticated(0, true), + {op: 'socketClose', code: 1006}, + connected, + {op: 'inspect', call: 'v', method: 'serverVersion'}, + authenticated(1, false), + authenticated(2, true), + answer(3, 'version', '3.0.0'), + // The server refuses it now: forgotten, and the request fails. + {op: 'socketClose', code: 1006}, + connected, + {op: 'inspect', call: 'v2', method: 'serverVersion'}, + authenticated(4, false), + authenticated(5, false), + {op: 'inspect', call: 'v3', method: 'serverVersion'}, + authenticated(6, false), + ], + }, + { + name: 'inspector: the clients, the map, and the rows of the local store', + steps: [ + start, + connected, + {op: 'materialize', view: 'v', query: 'issues.byOwner', args: 'u1'}, + advance(10), + ...syncPoke( + 'p1', + null, + '01', + [byOwnerU1], + [ + put('issues', issue('i1', {ownerId: 'u1'})), + put('issues', issue('i2', {ownerId: 'u1'})), + ], + ), + mutate('m1', 'issue.create', {id: 'i3', ownerId: 'u1'}), + {op: 'inspect', call: 'clients', method: 'clients'}, + {op: 'inspect', call: 'groupClients', method: 'clientGroupClients'}, + {op: 'inspect', call: 'rows', method: 'clientRows', table: 'issue'}, + {op: 'inspect', call: 'none', method: 'clientRows', table: 'nope'}, + {op: 'inspect', call: 'map', method: 'clientMap'}, + {op: 'inspect', call: 'withQueries', method: 'clientsWithQueries'}, + answer(0, 'queries', [queryRows[0]]), + { + op: 'inspect', + call: 'groupWithQueries', + method: 'clientGroupClientsWithQueries', + }, + answer(1, 'queries', []), + ], + }, + { + name: 'inspector: clients after a restart on the same storage', + steps: [ + start, + connected, + {op: 'restart'}, + {op: 'inspect', call: 'clients', method: 'clients'}, + {op: 'inspect', call: 'group', method: 'clientGroupClients'}, + ], + }, +]; diff --git a/packages/zero-conformance/src/primitives/ast-to-zql.test.ts b/packages/zero-conformance/src/primitives/ast-to-zql.test.ts new file mode 100644 index 0000000000..8276cea2c2 --- /dev/null +++ b/packages/zero-conformance/src/primitives/ast-to-zql.test.ts @@ -0,0 +1,174 @@ +import {readFileSync} from 'node:fs'; +import {test} from 'vitest'; +import {astToZQL} from '../../../ast-to-zql/src/ast-to-zql.ts'; +import type {AST, CorrelatedSubquery} from '../../../zero-protocol/src/ast.ts'; +import {emitVectors} from '../vectors.ts'; + +function corpus(name: string): AST[] { + const file = JSON.parse( + readFileSync( + new URL(`../../vectors/${name}.json`, import.meta.url), + 'utf8', + ), + ) as {cases: {ast: AST; normalized?: AST; valid?: boolean}[]}; + return file.cases.flatMap(c => + c.valid === false ? [] : [c.ast, ...(c.normalized ? [c.normalized] : [])], + ); +} + +const sq = ( + alias: string, + ast: Omit & {table?: string}, +): CorrelatedSubquery => ({ + correlation: {parentField: ['id'], childField: ['issueId']}, + subquery: {table: ast.table ?? 'comment', alias, ...ast}, +}); + +/** Shapes the corpora lack: junction hops, NOT EXISTS, escapes. */ +const extra: AST[] = [ + { + table: 'issue', + related: [ + { + ...sq('labels', { + table: 'issueLabel', + related: [ + sq('labels', { + table: 'label', + orderBy: [['name', 'asc']], + limit: 3, + }), + ], + }), + hidden: true, + }, + sq('comments', {limit: 0}), + sq('owner', {orderBy: []}), + ], + }, + { + table: 'issue', + where: { + type: 'or', + conditions: [ + { + type: 'correlatedSubquery', + op: 'NOT EXISTS', + related: sq('zsubq_comments', { + where: { + type: 'simple', + op: 'LIKE', + left: {type: 'column', name: 'body'}, + right: {type: 'literal', value: 'it\'s \\ "quoted"\n'}, + }, + }), + }, + { + type: 'and', + conditions: [ + { + type: 'simple', + op: '=', + left: {type: 'column', name: 'ownerId'}, + right: {type: 'static', anchor: 'authData', field: 'sub'}, + }, + { + type: 'simple', + op: 'IN', + left: {type: 'column', name: 'id'}, + right: {type: 'literal', value: ['a', 1, true]}, + }, + { + type: 'correlatedSubquery', + op: 'EXISTS', + related: sq('zsubq_owner', {table: 'user'}), + flip: true, + }, + ], + }, + ], + }, + start: {row: {id: 'x', n: 1.5}, exclusive: false}, + }, + { + table: 'issue', + where: { + type: 'correlatedSubquery', + op: 'EXISTS', + related: sq('zsubq_labels', { + table: 'issueLabel', + where: { + type: 'correlatedSubquery', + op: 'EXISTS', + related: sq('zsubq_zhidden_labels', { + table: 'label', + where: { + type: 'simple', + op: '!=', + left: {type: 'column', name: 'name'}, + right: {type: 'literal', value: null}, + }, + }), + }, + }), + scalar: true, + }, + limit: 10, + start: {row: {id: 'y'}, exclusive: true}, + }, + { + table: 'issue', + where: { + type: 'and', + conditions: [ + { + type: 'simple', + op: '>', + left: { + type: 'json', + value: {type: 'column', name: 'meta'}, + path: ["a'b", 0], + }, + right: {type: 'static', anchor: 'preMutationRow', field: ['x', 'y']}, + }, + { + type: 'or', + conditions: [ + { + type: 'simple', + op: 'IS', + left: {type: 'column', name: 'closed'}, + right: {type: 'literal', value: false}, + }, + ], + }, + ], + }, + }, + {table: 'issue', where: {type: 'and', conditions: []}}, + {table: 'issue', where: {type: 'or', conditions: []}}, +] as AST[]; + +test('ast-to-zql', () => { + const asts = [...corpus('ast'), ...corpus('ast-features'), ...extra]; + const seen = new Set(); + const cases = []; + for (const ast of asts) { + const key = JSON.stringify(ast); + if (seen.has(key)) continue; + seen.add(key); + cases.push({ + ast, + zql: astToZQL(ast), + redacted: astToZQL(ast, {redactLiterals: true}), + }); + } + emitVectors( + 'ast-to-zql', + 'ast-to-zql', + 'astToZQL (ast-to-zql/src/ast-to-zql.ts) of the ASTs of vectors/ast.json and vectors/ast-features.json (each as given and normalized) and a few more: as is, and with redactLiterals.', + cases, + undefined, + {compact: true}, + ); +}); diff --git a/packages/zero-conformance/src/primitives/tdigest.test.ts b/packages/zero-conformance/src/primitives/tdigest.test.ts new file mode 100644 index 0000000000..86139ecb4a --- /dev/null +++ b/packages/zero-conformance/src/primitives/tdigest.test.ts @@ -0,0 +1,279 @@ +import {test} from 'vitest'; +import {TDigest} from '../../../shared/src/tdigest.ts'; +import {Random} from '../random.ts'; +import {emitVectors} from '../vectors.ts'; + +/** A number as JSON: NaN and the infinities as strings. */ +type Num = number | 'NaN' | 'Infinity' | '-Infinity'; + +function enc(n: number): Num { + if (Number.isNaN(n)) return 'NaN'; + if (n === Infinity) return 'Infinity'; + if (n === -Infinity) return '-Infinity'; + return n; +} + +function dec(n: Num): number { + return typeof n === 'number' ? n : Number(n); +} + +type Op = + | {op: 'add'; d: number; values: [Num, Num][]} + | {op: 'merge'; d: number; from: number} + | {op: 'quantile'; d: number; q: Num[]} + | {op: 'cdf'; d: number; x: Num[]} + | {op: 'count'; d: number} + | {op: 'toJSON'; d: number} + | {op: 'fromJSON'; d: number; json: number[]} + | {op: 'reset'; d: number}; + +type Case = {name: string; compressions: number[]; ops: Op[]}; + +const QUANTILES: Num[] = [ + 0, + 0.001, + 0.01, + 0.1, + 0.25, + 0.5, + 0.75, + 0.9, + 0.95, + 0.99, + 0.999, + 1, + -0.1, + 1.1, + 'NaN', +]; + +function run(c: Case): unknown[] { + const digests = c.compressions.map(n => new TDigest(n)); + return c.ops.map(op => { + const d = digests[op.d]; + switch (op.op) { + case 'add': + for (const [m, w] of op.values) d.add(dec(m), dec(w)); + return null; + case 'merge': + d.merge(digests[op.from]); + return null; + case 'quantile': + return op.q.map(q => enc(d.quantile(dec(q)))); + case 'cdf': + return op.x.map(x => enc(d.cdf(dec(x)))); + case 'count': + return enc(d.count()); + case 'toJSON': + return d.toJSON().map(enc); + case 'fromJSON': + try { + digests[op.d] = TDigest.fromJSON( + op.json as unknown as Parameters[0], + ); + return 'ok'; + } catch (e) { + return {threw: (e as Error).message}; + } + case 'reset': + d.reset(); + return null; + } + }); +} + +function values(r: Random, n: number, kind: string): [Num, Num][] { + const out: [Num, Num][] = []; + for (let i = 0; i < n; i++) { + let m: number; + switch (kind) { + case 'ints': + m = r.int(20); + break; + case 'timing': + // Durations in ms, mostly small with a long tail. + m = Math.round(-Math.log(1 - r.next()) * 30 * 1000) / 1000; + break; + case 'wide': + m = Math.round((r.next() - 0.5) * 2e7) / 10; + break; + default: + m = Math.round(r.next() * 1e6) / 1000; + } + let w: number; + const p = r.next(); + if (p < 0.5) w = 1; + else if (p < 0.7) w = 32; + else if (p < 0.95) w = Math.round(r.next() * 1000) / 100 + 0.01; + else w = r.pick([0, -1, NaN, Infinity]); + out.push([enc(r.next() < 0.01 ? NaN : m), enc(w)]); + } + return out; +} + +test('tdigest', () => { + const cases: Case[] = [ + { + name: 'empty', + compressions: [100], + ops: [ + {op: 'count', d: 0}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'cdf', d: 0, x: [0, 1]}, + {op: 'toJSON', d: 0}, + ], + }, + { + name: 'one value', + compressions: [100], + ops: [ + {op: 'add', d: 0, values: [[5, 1]]}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'cdf', d: 0, x: [4, 5, 6]}, + {op: 'toJSON', d: 0}, + ], + }, + { + name: 'two values, sampled weight', + compressions: [100], + ops: [ + { + op: 'add', + d: 0, + values: [ + [0, 32], + [3, 32], + ], + }, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'cdf', d: 0, x: [-1, 0, 1, 1.5, 3, 4]}, + {op: 'count', d: 0}, + {op: 'toJSON', d: 0}, + ], + }, + { + name: 'ignored values', + compressions: [100], + ops: [ + { + op: 'add', + d: 0, + values: [ + ['NaN', 1], + [1, 0], + [1, -1], + [1, 'NaN'], + [1, 'Infinity'], + [2, 1], + [-0, 1], + [0, 1], + ], + }, + {op: 'count', d: 0}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'toJSON', d: 0}, + ], + }, + { + name: 'fromJSON', + compressions: [100], + ops: [ + {op: 'fromJSON', d: 0, json: [100, 1, 2, 3, 4, 10, 1]}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'toJSON', d: 0}, + {op: 'fromJSON', d: 0, json: [100, 1]}, + {op: 'fromJSON', d: 0, json: [50]}, + {op: 'count', d: 0}, + {op: 'toJSON', d: 0}, + {op: 'fromJSON', d: 0, json: [1000, 5, 1, 2, 1]}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'toJSON', d: 0}, + ], + }, + { + name: 'merge into itself', + compressions: [100], + ops: [ + { + op: 'add', + d: 0, + values: [ + [1, 1], + [2, 1], + [3, 1], + ], + }, + {op: 'merge', d: 0, from: 0}, + {op: 'count', d: 0}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'toJSON', d: 0}, + ], + }, + ]; + + const r = new Random(0x7d16); + const kinds = ['uniform', 'ints', 'timing', 'wide']; + const compressions = [100, 100, 100, 20, 5, 1000, 33.5]; + for (let i = 0; i < 30; i++) { + const n = r.pick([1, 2, 3]); + const cs = Array.from({length: n}, () => r.pick(compressions)); + const ops: Op[] = []; + const steps = 2 + r.int(6); + for (let s = 0; s < steps; s++) { + const d = r.int(n); + const p = r.next(); + if (p < 0.55) { + const size = r.pick([1, 5, 50, 300, 850]); + ops.push({op: 'add', d, values: values(r, size, r.pick(kinds))}); + } else if (p < 0.7 && n > 1) { + ops.push({op: 'merge', d, from: r.int(n)}); + } else if (p < 0.8) { + ops.push({op: 'quantile', d, q: QUANTILES}); + } else if (p < 0.85) { + ops.push({op: 'cdf', d, x: [0, 1, 10, 100, 500, 999]}); + } else if (p < 0.95) { + ops.push({op: 'toJSON', d}); + } else { + ops.push({op: 'reset', d}); + } + } + for (let d = 0; d < n; d++) { + ops.push( + {op: 'count', d}, + {op: 'quantile', d, q: QUANTILES}, + {op: 'cdf', d, x: [0, 1, 10, 100, 500, 999]}, + {op: 'toJSON', d}, + ); + } + cases.push({name: `random ${i}`, compressions: cs, ops}); + } + + // The JSON round trip: each final digest read back. + for (const c of cases.slice()) { + const results = run(c); + const json = c.ops.flatMap((op, i) => + op.op === 'toJSON' && results[i] !== null ? [results[i] as Num[]] : [], + ); + const last = json.at(-1); + if (last && last.every(n => typeof n === 'number')) { + cases.push({ + name: `${c.name}, read back`, + compressions: [100], + ops: [ + {op: 'fromJSON', d: 0, json: last as number[]}, + {op: 'quantile', d: 0, q: QUANTILES}, + {op: 'toJSON', d: 0}, + ], + }); + } + } + + emitVectors( + 'tdigest', + 'tdigest', + 'TDigest (shared/src/tdigest.ts): each case runs `ops` on `compressions.length` digests; `expect` holds each op result (null for add, merge, and reset). NaN and the infinities are strings.', + cases.map(c => ({...c, expect: run(c)})), + undefined, + {compact: true}, + ); +}); diff --git a/packages/zero-conformance/vectors/ast-to-zql.json b/packages/zero-conformance/vectors/ast-to-zql.json new file mode 100644 index 0000000000..ba6b28dfd7 --- /dev/null +++ b/packages/zero-conformance/vectors/ast-to-zql.json @@ -0,0 +1,103 @@ +{"formatVersion":1,"kind":"ast-to-zql","description":"astToZQL (ast-to-zql/src/ast-to-zql.ts) of the ASTs of vectors/ast.json and vectors/ast-features.json (each as given and normalized) and a few more: as is, and with redactLiterals.","cases":[ +{"ast":{"table":"issue"},"zql":"","redacted":""}, +{"ast":{"table":"issue","where":{"type":"and","conditions":[]}},"zql":"","redacted":""}, +{"ast":{"table":"issue","where":{"type":"or","conditions":[]}},"zql":".where(({cmp, or}) => or())","redacted":".where(({cmp, or}) => or())"}, +{"ast":{"table":"issue","where":{"type":"and","conditions":[{"type":"simple","op":"=","left":{"type":"column","name":"b"},"right":{"type":"literal","value":1}}]}},"zql":".where('b', 1)","redacted":".where('b', ?)"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"=","left":{"type":"column","name":"b"},"right":{"type":"literal","value":1}}},"zql":".where('b', 1)","redacted":".where('b', ?)"}, +{"ast":{"table":"issue","where":{"type":"and","conditions":[{"type":"or","conditions":[{"type":"simple","op":"=","left":{"type":"column","name":"x"},"right":{"type":"literal","value":"b"}},{"type":"simple","op":"=","left":{"type":"column","name":"x"},"right":{"type":"literal","value":"a"}}]},{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"zsubq_comments"}}},{"type":"and","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":5}},{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"label","alias":"zsubq_labels"}}}]},{"type":"simple","op":"IN","left":{"type":"column","name":"a"},"right":{"type":"literal","value":["b","a",1,true]}}]},"related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments","limit":3}},{"correlation":{"parentField":["ownerId"],"childField":["id"]},"subquery":{"table":"user","alias":"owner"}},{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"issueLabel","alias":"comments"}}]},"zql":".where(({cmp, or}) => or(cmp('x', 'b'), cmp('x', 'a'))).whereExists('comments').where('a', '<', 5).where(({exists, not}) => not(exists('labels'))).where('a', 'IN', [\"b\",\"a\",1,true]).related('comments', q => q.limit(3)).related('owner').related('comments')","redacted":".where(({cmp, or}) => or(cmp('x', ?), cmp('x', ?))).whereExists('comments').where('a', '<', ?).where(({exists, not}) => not(exists('labels'))).where('a', 'IN', ?).related('comments', q => q.limit(3)).related('owner').related('comments')"}, +{"ast":{"table":"issue","where":{"type":"and","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":5}},{"type":"simple","op":"IN","left":{"type":"column","name":"a"},"right":{"type":"literal","value":["b","a",1,true]}},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"zsubq_comments"}},"op":"EXISTS"},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"label","alias":"zsubq_labels"}},"op":"NOT EXISTS"},{"type":"or","conditions":[{"type":"simple","op":"=","left":{"type":"column","name":"x"},"right":{"type":"literal","value":"a"}},{"type":"simple","op":"=","left":{"type":"column","name":"x"},"right":{"type":"literal","value":"b"}}]}]},"related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments","limit":3}},{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"issueLabel","alias":"comments"}},{"correlation":{"parentField":["ownerId"],"childField":["id"]},"subquery":{"table":"user","alias":"owner"}}]},"zql":".where('a', '<', 5).where('a', 'IN', [\"b\",\"a\",1,true]).whereExists('comments').where(({exists, not}) => not(exists('labels'))).where(({cmp, or}) => or(cmp('x', 'a'), cmp('x', 'b'))).related('comments', q => q.limit(3)).related('comments').related('owner')","redacted":".where('a', '<', ?).where('a', 'IN', ?).whereExists('comments').where(({exists, not}) => not(exists('labels'))).where(({cmp, or}) => or(cmp('x', ?), cmp('x', ?))).related('comments', q => q.limit(3)).related('comments').related('owner')"}, +{"ast":{"table":"user","orderBy":[["createdAt","asc"]]},"zql":".orderBy('createdAt', 'asc')","redacted":".orderBy('createdAt', 'asc')"}, +{"ast":{"table":"comment","related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"owner","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["createdAt"],"childField":["ownerId"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"and","conditions":[{"type":"simple","op":"IN","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"literal","value":null}},{"type":"simple","op":"ILIKE","left":{"type":"column","name":"a"},"right":{"type":"static","anchor":"authData","field":["a","c"]}}]},"orderBy":[["closed","desc"]]}},"flip":false}},"system":"client"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"or","conditions":[{"type":"or","conditions":[{"type":"simple","op":"IS NOT","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},{"type":"simple","op":"NOT LIKE","left":{"type":"literal","value":"é"},"right":{"type":"literal","value":"a"}},{"type":"simple","op":"IS NOT","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":["","",-2147483649]}},{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":["é"]}}]}]},"orderBy":[["ownerId","desc"]]},"system":"client"}],"limit":0,"orderBy":[["ownerId","asc"],["id","asc"]]},"zql":".related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where(authParam('sub'), 'IN', null).where('a', 'ILIKE', authParam(['a', 'c'])).orderBy('closed', 'desc'), {flip: false})))).related('zsubq_b', q => q.where(({cmp, or}) => or(cmp('ownerId', 'IS NOT', null), cmp('é', 'NOT LIKE', 'a'), cmp('ownerId', 'IS NOT', [\"\",\"\",-2147483649]), cmp('id', 'NOT LIKE', [\"é\"]))).orderBy('ownerId', 'desc')).orderBy('ownerId', 'asc').orderBy('id', 'asc').limit(0)","redacted":".related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where(authParam('sub'), 'IN', ?).where('a', 'ILIKE', authParam(['a', 'c'])).orderBy('closed', 'desc'), {flip: false})))).related('zsubq_b', q => q.where(({cmp, or}) => or(cmp('ownerId', 'IS NOT', ?), cmp(?, 'NOT LIKE', ?), cmp('ownerId', 'IS NOT', ?), cmp('id', 'NOT LIKE', ?))).orderBy('ownerId', 'desc')).orderBy('ownerId', 'asc').orderBy('id', 'asc').limit(0)"}, +{"ast":{"table":"comment","related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"owner","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["createdAt"],"childField":["ownerId"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"and","conditions":[{"type":"simple","op":"ILIKE","left":{"type":"column","name":"a"},"right":{"type":"static","anchor":"authData","field":["a","c"]}},{"type":"simple","op":"IN","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"literal","value":null}}]},"orderBy":[["closed","desc"]]}},"op":"NOT EXISTS","flip":false}},"system":"client"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"or","conditions":[{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":["é"]}},{"type":"simple","op":"IS NOT","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},{"type":"simple","op":"IS NOT","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":["","",-2147483649]}},{"type":"simple","op":"NOT LIKE","left":{"type":"literal","value":"é"},"right":{"type":"literal","value":"a"}}]},"orderBy":[["ownerId","desc"]]},"system":"client"}],"limit":0,"orderBy":[["ownerId","asc"],["id","asc"]]},"zql":".related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where('a', 'ILIKE', authParam(['a', 'c'])).where(authParam('sub'), 'IN', null).orderBy('closed', 'desc'), {flip: false})))).related('zsubq_b', q => q.where(({cmp, or}) => or(cmp('id', 'NOT LIKE', [\"é\"]), cmp('ownerId', 'IS NOT', null), cmp('ownerId', 'IS NOT', [\"\",\"\",-2147483649]), cmp('é', 'NOT LIKE', 'a'))).orderBy('ownerId', 'desc')).orderBy('ownerId', 'asc').orderBy('id', 'asc').limit(0)","redacted":".related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where('a', 'ILIKE', authParam(['a', 'c'])).where(authParam('sub'), 'IN', ?).orderBy('closed', 'desc'), {flip: false})))).related('zsubq_b', q => q.where(({cmp, or}) => or(cmp('id', 'NOT LIKE', ?), cmp('ownerId', 'IS NOT', ?), cmp('ownerId', 'IS NOT', ?), cmp(?, 'NOT LIKE', ?))).orderBy('ownerId', 'desc')).orderBy('ownerId', 'asc').orderBy('id', 'asc').limit(0)"}, +{"ast":{"table":"user"},"zql":"","redacted":""}, +{"ast":{"table":"user","where":{"type":"and","conditions":[{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id"],"childField":["a"]},"subquery":{"table":"label","alias":"comments","where":{"type":"simple","op":"IS NOT","left":{"type":"literal","value":true},"right":{"type":"literal","value":0}},"orderBy":[["a","asc"]],"start":{"row":{"id":"a","createdAt":null},"exclusive":false}}},"flip":true,"scalar":true},{"type":"and","conditions":[{"type":"and","conditions":[{"type":"simple","op":"LIKE","left":{"type":"literal","value":[]},"right":{"type":"literal","value":-2147483649}},{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[-2147483649]}},{"type":"simple","op":">","left":{"type":"column","name":"createdAt"},"right":{"type":"static","anchor":"preMutationRow","field":["a","c"]}}]},{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["a"],"childField":["closed"]},"subquery":{"table":"label","alias":"comments","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"a"},"right":{"type":"literal","value":1e+21}},"orderBy":[["a","desc"]]}}},{"type":"simple","op":"IS NOT","left":{"type":"literal","value":-1},"right":{"type":"literal","value":-2147483649}}]},{"type":"simple","op":"ILIKE","left":{"type":"column","name":"a"},"right":{"type":"literal","value":[1.5,"a",-1]}},{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["ownerId"],"childField":["closed"]},"subquery":{"table":"comment","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"simple","op":"NOT IN","left":{"type":"column","name":"id"},"right":{"type":"literal","value":""}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"a"},"right":{"type":"static","anchor":"authData","field":"role"}},{"type":"simple","op":"IS","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":1.5}},{"type":"simple","op":"IS","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":""}}]},"limit":1,"orderBy":[["id","asc"]],"start":{"row":{"id":true,"createdAt":null},"exclusive":true}},"hidden":true}}]}},"zql":".whereExists('comments', q => q.where(true, 'IS NOT', 0).orderBy('a', 'asc').start({\"id\":\"a\",\"createdAt\":null}, { inclusive: true }), {flip: true, scalar: true}).where([], 'LIKE', -2147483649).where('é', 'NOT LIKE', [-2147483649]).where('createdAt', '>', authParam(['a', 'c'])).where(({exists, not}) => not(exists('comments', q => q.where('a', 'NOT LIKE', 1e+21).orderBy('a', 'desc')))).where(-1, 'IS NOT', -2147483649).where('a', 'ILIKE', [1.5,\"a\",-1]).where(({exists, not}) => not(exists('a', q => q.where(({cmp, or}) => or(cmp('id', 'NOT IN', ''), cmp('a', 'NOT IN', authParam('role')), cmp('createdAt', 'IS', 1.5), cmp('ownerId', 'IS', ''))).orderBy('id', 'asc').limit(1).start({\"id\":true,\"createdAt\":null}))))","redacted":".whereExists('comments', q => q.where(?, 'IS NOT', ?).orderBy('a', 'asc').start(?, { inclusive: true }), {flip: true, scalar: true}).where(?, 'LIKE', ?).where('é', 'NOT LIKE', ?).where('createdAt', '>', authParam(['a', 'c'])).where(({exists, not}) => not(exists('comments', q => q.where('a', 'NOT LIKE', ?).orderBy('a', 'desc')))).where(?, 'IS NOT', ?).where('a', 'ILIKE', ?).where(({exists, not}) => not(exists('a', q => q.where(({cmp, or}) => or(cmp('id', 'NOT IN', ?), cmp('a', 'NOT IN', authParam('role')), cmp('createdAt', 'IS', ?), cmp('ownerId', 'IS', ?))).orderBy('id', 'asc').limit(1).start(?))))"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[{"type":"simple","op":"ILIKE","left":{"type":"column","name":"a"},"right":{"type":"literal","value":[1.5,"a",-1]}},{"type":"simple","op":">","left":{"type":"column","name":"createdAt"},"right":{"type":"static","anchor":"preMutationRow","field":["a","c"]}},{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[-2147483649]}},{"type":"simple","op":"IS NOT","left":{"type":"literal","value":-1},"right":{"type":"literal","value":-2147483649}},{"type":"simple","op":"LIKE","left":{"type":"literal","value":[]},"right":{"type":"literal","value":-2147483649}},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id"],"childField":["a"]},"subquery":{"table":"label","alias":"comments","where":{"type":"simple","op":"IS NOT","left":{"type":"literal","value":true},"right":{"type":"literal","value":0}},"start":{"row":{"id":"a","createdAt":null},"exclusive":false},"orderBy":[["a","asc"]]}},"op":"EXISTS","flip":true,"scalar":true},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["a"],"childField":["closed"]},"subquery":{"table":"label","alias":"comments","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"a"},"right":{"type":"literal","value":1e+21}},"orderBy":[["a","desc"]]}},"op":"NOT EXISTS"},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["ownerId"],"childField":["closed"]},"hidden":true,"subquery":{"table":"comment","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"simple","op":"NOT IN","left":{"type":"column","name":"a"},"right":{"type":"static","anchor":"authData","field":"role"}},{"type":"simple","op":"IS","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":1.5}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"id"},"right":{"type":"literal","value":""}},{"type":"simple","op":"IS","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":""}}]},"start":{"row":{"id":true,"createdAt":null},"exclusive":true},"limit":1,"orderBy":[["id","asc"]]}},"op":"NOT EXISTS"}]}},"zql":".where('a', 'ILIKE', [1.5,\"a\",-1]).where('createdAt', '>', authParam(['a', 'c'])).where('é', 'NOT LIKE', [-2147483649]).where(-1, 'IS NOT', -2147483649).where([], 'LIKE', -2147483649).whereExists('comments', q => q.where(true, 'IS NOT', 0).orderBy('a', 'asc').start({\"id\":\"a\",\"createdAt\":null}, { inclusive: true }), {flip: true, scalar: true}).where(({exists, not}) => not(exists('comments', q => q.where('a', 'NOT LIKE', 1e+21).orderBy('a', 'desc')))).where(({exists, not}) => not(exists('a', q => q.where(({cmp, or}) => or(cmp('a', 'NOT IN', authParam('role')), cmp('createdAt', 'IS', 1.5), cmp('id', 'NOT IN', ''), cmp('ownerId', 'IS', ''))).orderBy('id', 'asc').limit(1).start({\"id\":true,\"createdAt\":null}))))","redacted":".where('a', 'ILIKE', ?).where('createdAt', '>', authParam(['a', 'c'])).where('é', 'NOT LIKE', ?).where(?, 'IS NOT', ?).where(?, 'LIKE', ?).whereExists('comments', q => q.where(?, 'IS NOT', ?).orderBy('a', 'asc').start(?, { inclusive: true }), {flip: true, scalar: true}).where(({exists, not}) => not(exists('comments', q => q.where('a', 'NOT LIKE', ?).orderBy('a', 'desc')))).where(({exists, not}) => not(exists('a', q => q.where(({cmp, or}) => or(cmp('a', 'NOT IN', authParam('role')), cmp('createdAt', 'IS', ?), cmp('id', 'NOT IN', ?), cmp('ownerId', 'IS', ?))).orderBy('id', 'asc').limit(1).start(?))))"}, +{"ast":{"table":"label","where":{"type":"or","conditions":[]},"limit":100,"orderBy":[["é","asc"],["id","asc"]]},"zql":".where(({cmp, or}) => or()).orderBy('é', 'asc').orderBy('id', 'asc').limit(100)","redacted":".where(({cmp, or}) => or()).orderBy('é', 'asc').orderBy('id', 'asc').limit(100)"}, +{"ast":{"table":"user","schema":"public","where":{"type":"and","conditions":[{"type":"or","conditions":[{"type":"or","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"é"},"right":{"type":"literal","value":-1}},{"type":"simple","op":"IS","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[2147483648,"😀"]}},{"type":"simple","op":"=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":-1}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"title"},"right":{"type":"static","anchor":"authData","field":"role"}}]},{"type":"or","conditions":[{"type":"simple","op":"IN","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}},{"type":"simple","op":"=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":[1e+21,2147483648,1]}},{"type":"simple","op":"=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":null}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"a"},"right":{"type":"literal","value":false}}]},{"type":"or","conditions":[{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"a"},"right":{"type":"static","anchor":"preMutationRow","field":["a","c"]}},{"type":"simple","op":">","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":1}}]},{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["closed"],"childField":["a"]},"subquery":{"table":"issue","alias":"comments","schema":"public","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}},"orderBy":[["createdAt","asc"]]}},"flip":true,"scalar":true}]}]},"related":[{"correlation":{"parentField":["closed"],"childField":["createdAt"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"or","conditions":[]},"limit":100},"system":"permissions","hidden":true}],"start":{"row":{"id":-2147483649,"createdAt":2.5},"exclusive":true}},"zql":".where(({cmp, exists, not, or}) => or(or(cmp('é', '<', -1), cmp('é', 'IS', [2147483648,\"😀\"]), cmp('title', -1), cmp('title', 'NOT IN', authParam('role'))), or(cmp('a', 'IN', null), cmp('closed', [1e+21,2147483648,1]), cmp('é', null), cmp('a', 'NOT IN', false)), or(cmp('a', 'NOT LIKE', authParam(['a', 'c'])), cmp('ownerId', '>', 1)), not(exists('comments', q => q.where('closed', 'ILIKE', null).orderBy('createdAt', 'asc'), {flip: true, scalar: true})))).start({\"id\":-2147483649,\"createdAt\":2.5})","redacted":".where(({cmp, exists, not, or}) => or(or(cmp('é', '<', ?), cmp('é', 'IS', ?), cmp('title', ?), cmp('title', 'NOT IN', authParam('role'))), or(cmp('a', 'IN', ?), cmp('closed', ?), cmp('é', ?), cmp('a', 'NOT IN', ?)), or(cmp('a', 'NOT LIKE', authParam(['a', 'c'])), cmp('ownerId', '>', ?)), not(exists('comments', q => q.where('closed', 'ILIKE', ?).orderBy('createdAt', 'asc'), {flip: true, scalar: true})))).start(?)"}, +{"ast":{"schema":"public","table":"user","where":{"type":"or","conditions":[{"type":"simple","op":"IN","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"a"},"right":{"type":"literal","value":false}},{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"a"},"right":{"type":"static","anchor":"preMutationRow","field":["a","c"]}},{"type":"simple","op":"=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":[1e+21,2147483648,1]}},{"type":"simple","op":">","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":-1}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"title"},"right":{"type":"static","anchor":"authData","field":"role"}},{"type":"simple","op":"<","left":{"type":"column","name":"é"},"right":{"type":"literal","value":-1}},{"type":"simple","op":"=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":null}},{"type":"simple","op":"IS","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[2147483648,"😀"]}},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["closed"],"childField":["a"]},"subquery":{"schema":"public","table":"issue","alias":"comments","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}},"orderBy":[["createdAt","asc"]]}},"op":"NOT EXISTS","flip":true,"scalar":true}]},"related":[{"correlation":{"parentField":["closed"],"childField":["createdAt"]},"hidden":true,"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"or","conditions":[]},"limit":100},"system":"permissions"}],"start":{"row":{"id":-2147483649,"createdAt":2.5},"exclusive":true}},"zql":".where(({cmp, exists, not, or}) => or(cmp('a', 'IN', null), cmp('a', 'NOT IN', false), cmp('a', 'NOT LIKE', authParam(['a', 'c'])), cmp('closed', [1e+21,2147483648,1]), cmp('ownerId', '>', 1), cmp('title', -1), cmp('title', 'NOT IN', authParam('role')), cmp('é', '<', -1), cmp('é', null), cmp('é', 'IS', [2147483648,\"😀\"]), not(exists('comments', q => q.where('closed', 'ILIKE', null).orderBy('createdAt', 'asc'), {flip: true, scalar: true})))).start({\"id\":-2147483649,\"createdAt\":2.5})","redacted":".where(({cmp, exists, not, or}) => or(cmp('a', 'IN', ?), cmp('a', 'NOT IN', ?), cmp('a', 'NOT LIKE', authParam(['a', 'c'])), cmp('closed', ?), cmp('ownerId', '>', ?), cmp('title', ?), cmp('title', 'NOT IN', authParam('role')), cmp('é', '<', ?), cmp('é', ?), cmp('é', 'IS', ?), not(exists('comments', q => q.where('closed', 'ILIKE', ?).orderBy('createdAt', 'asc'), {flip: true, scalar: true})))).start(?)"}, +{"ast":{"table":"issue","schema":"public","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}}},"zql":".where('closed', 'NOT IN', null)","redacted":".where('closed', 'NOT IN', ?)"}, +{"ast":{"schema":"public","table":"issue","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}}},"zql":".where('closed', 'NOT IN', null)","redacted":".where('closed', 'NOT IN', ?)"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":-2147483649}},"related":[{"correlation":{"parentField":["a"],"childField":["id"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"and","conditions":[]},"related":[{"correlation":{"parentField":["a"],"childField":["id"]},"subquery":{"table":"issue","alias":"owner","limit":0,"orderBy":[["a","asc"],["id","asc"]],"start":{"row":{"id":"b","createdAt":null},"exclusive":true}},"hidden":true},{"correlation":{"parentField":["é"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_b","orderBy":[["createdAt","desc"],["id","asc"]]}},{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["é"],"childField":["createdAt"]},"subquery":{"table":"issue","alias":"zsubq_b","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":null}}}},"scalar":true},"limit":1.5},"system":"client"}]}}],"orderBy":[["é","asc"]]},"zql":".where('id', 'NOT LIKE', -2147483649).related('zsubq_a', q => q.related('zsubq_b', q => q.orderBy('createdAt', 'desc').orderBy('id', 'asc')).related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where('id', 'NOT ILIKE', null), {scalar: true}))).limit(1.5))).orderBy('é', 'asc')","redacted":".where('id', 'NOT LIKE', ?).related('zsubq_a', q => q.related('zsubq_b', q => q.orderBy('createdAt', 'desc').orderBy('id', 'asc')).related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where('id', 'NOT ILIKE', ?), {scalar: true}))).limit(1.5))).orderBy('é', 'asc')"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":-2147483649}},"related":[{"correlation":{"parentField":["a"],"childField":["id"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"and","conditions":[]},"related":[{"correlation":{"parentField":["a"],"childField":["id"]},"hidden":true,"subquery":{"table":"issue","alias":"owner","start":{"row":{"id":"b","createdAt":null},"exclusive":true},"limit":0,"orderBy":[["a","asc"],["id","asc"]]}},{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["é"],"childField":["createdAt"]},"subquery":{"table":"issue","alias":"zsubq_b","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":null}}}},"op":"NOT EXISTS","scalar":true},"limit":1.5},"system":"client"},{"correlation":{"parentField":["é"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_b","orderBy":[["createdAt","desc"],["id","asc"]]}}]}}],"orderBy":[["é","asc"]]},"zql":".where('id', 'NOT LIKE', -2147483649).related('zsubq_a', q => q.related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where('id', 'NOT ILIKE', null), {scalar: true}))).limit(1.5)).related('zsubq_b', q => q.orderBy('createdAt', 'desc').orderBy('id', 'asc'))).orderBy('é', 'asc')","redacted":".where('id', 'NOT LIKE', ?).related('zsubq_a', q => q.related('owner', q => q.where(({exists, not}) => not(exists('b', q => q.where('id', 'NOT ILIKE', ?), {scalar: true}))).limit(1.5)).related('zsubq_b', q => q.orderBy('createdAt', 'desc').orderBy('id', 'asc'))).orderBy('é', 'asc')"}, +{"ast":{"table":"user","related":[{"correlation":{"parentField":["createdAt"],"childField":["é"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"comment","alias":"zsubq_a","schema":"public","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"title"},"right":{"type":"literal","value":-1}}},"system":"client","hidden":false},"scalar":true},"orderBy":[["title","asc"],["id","asc"]]}},{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"or","conditions":[]},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["a"],"childField":["id"]},"subquery":{"table":"comment","alias":"comments","orderBy":[["a","asc"]]},"system":"permissions"},"flip":false}},"system":"client"}],"orderBy":[["closed","desc"],["id","asc"]]},"system":"client"}]},"zql":".related('owner', q => q.where(({exists, not}) => not(exists('a', q => q.where('title', 'NOT ILIKE', -1), {scalar: true}))).orderBy('title', 'asc').orderBy('id', 'asc')).related('zsubq_b', q => q.where(({cmp, or}) => or()).related('zsubq_a', q => q.whereExists('comments', q => q.orderBy('a', 'asc'), {flip: false})).orderBy('closed', 'desc').orderBy('id', 'asc'))","redacted":".related('owner', q => q.where(({exists, not}) => not(exists('a', q => q.where('title', 'NOT ILIKE', ?), {scalar: true}))).orderBy('title', 'asc').orderBy('id', 'asc')).related('zsubq_b', q => q.where(({cmp, or}) => or()).related('zsubq_a', q => q.whereExists('comments', q => q.orderBy('a', 'asc'), {flip: false})).orderBy('closed', 'desc').orderBy('id', 'asc'))"}, +{"ast":{"table":"user","related":[{"correlation":{"parentField":["createdAt"],"childField":["é"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["a"],"childField":["title"]},"hidden":false,"subquery":{"schema":"public","table":"comment","alias":"zsubq_a","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"title"},"right":{"type":"literal","value":-1}}},"system":"client"},"op":"NOT EXISTS","scalar":true},"orderBy":[["title","asc"],["id","asc"]]}},{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"or","conditions":[]},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["a"],"childField":["id"]},"subquery":{"table":"comment","alias":"comments","orderBy":[["a","asc"]]},"system":"permissions"},"op":"EXISTS","flip":false}},"system":"client"}],"orderBy":[["closed","desc"],["id","asc"]]},"system":"client"}]},"zql":".related('owner', q => q.where(({exists, not}) => not(exists('a', q => q.where('title', 'NOT ILIKE', -1), {scalar: true}))).orderBy('title', 'asc').orderBy('id', 'asc')).related('zsubq_b', q => q.where(({cmp, or}) => or()).related('zsubq_a', q => q.whereExists('comments', q => q.orderBy('a', 'asc'), {flip: false})).orderBy('closed', 'desc').orderBy('id', 'asc'))","redacted":".related('owner', q => q.where(({exists, not}) => not(exists('a', q => q.where('title', 'NOT ILIKE', ?), {scalar: true}))).orderBy('title', 'asc').orderBy('id', 'asc')).related('zsubq_b', q => q.where(({cmp, or}) => or()).related('zsubq_a', q => q.whereExists('comments', q => q.orderBy('a', 'asc'), {flip: false})).orderBy('closed', 'desc').orderBy('id', 'asc'))"}, +{"ast":{"table":"comment","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":0}},"related":[{"correlation":{"parentField":["id"],"childField":["closed"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"or","conditions":[{"type":"simple","op":"!=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}}]},"limit":10,"start":{"row":{"id":1.5,"createdAt":2.5},"exclusive":true}},"system":"client"},{"correlation":{"parentField":["createdAt"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"simple","op":">","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},{"type":"simple","op":"=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[]}},{"type":"simple","op":"=","left":{"type":"literal","value":2147483648},"right":{"type":"literal","value":0}}]},"related":[{"correlation":{"parentField":["closed"],"childField":["createdAt"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["é"],"childField":["title"]},"subquery":{"table":"comment","alias":"zsubq_b","orderBy":[["title","desc"],["id","asc"]]}}},"orderBy":[["a","asc"],["id","asc"]],"start":{"row":{"id":"é","createdAt":1},"exclusive":false}},"system":"test"},{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"or","conditions":[{"type":"simple","op":"<","left":{"type":"literal","value":null},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}},{"type":"simple","op":">=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":[]}}]}},"system":"permissions"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"and","conditions":[{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"a"},"right":{"type":"literal","value":[-1,2147483648,1]}},{"type":"simple","op":"!=","left":{"type":"column","name":"title"},"right":{"type":"static","anchor":"preMutationRow","field":["a","b"]}},{"type":"simple","op":"<","left":{"type":"column","name":"é"},"right":{"type":"literal","value":false}}]},"orderBy":[["title","desc"],["id","asc"]]}}],"orderBy":[["ownerId","desc"]]},"system":"test"}],"limit":4294967296,"orderBy":[["id","asc"],["id","asc"]],"start":{"row":{"id":"é","createdAt":null},"exclusive":true}},"zql":".where('createdAt', 'ILIKE', 0).related('owner', q => q.where('closed', '!=', null).limit(10).start({\"id\":1.5,\"createdAt\":2.5})).related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('ownerId', '>', null), cmp('é', []), cmp(2147483648, 0))).related('comments', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('title', 'desc').orderBy('id', 'asc')))).orderBy('a', 'asc').orderBy('id', 'asc').start({\"id\":\"é\",\"createdAt\":1}, { inclusive: true })).related('owner', q => q.where(({cmp, or}) => or(cmp(null, '<', authParam('sub')), cmp('title', '>=', [])))).related('zsubq_a', q => q.where('a', 'NOT LIKE', [-1,2147483648,1]).where('title', '!=', authParam(['a', 'b'])).where('é', '<', false).orderBy('title', 'desc').orderBy('id', 'asc')).orderBy('ownerId', 'desc')).orderBy('id', 'asc').orderBy('id', 'asc').limit(4294967296).start({\"id\":\"é\",\"createdAt\":null})","redacted":".where('createdAt', 'ILIKE', ?).related('owner', q => q.where('closed', '!=', ?).limit(10).start(?)).related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('ownerId', '>', ?), cmp('é', ?), cmp(?, ?))).related('comments', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('title', 'desc').orderBy('id', 'asc')))).orderBy('a', 'asc').orderBy('id', 'asc').start(?, { inclusive: true })).related('owner', q => q.where(({cmp, or}) => or(cmp(?, '<', authParam('sub')), cmp('title', '>=', ?)))).related('zsubq_a', q => q.where('a', 'NOT LIKE', ?).where('title', '!=', authParam(['a', 'b'])).where('é', '<', ?).orderBy('title', 'desc').orderBy('id', 'asc')).orderBy('ownerId', 'desc')).orderBy('id', 'asc').orderBy('id', 'asc').limit(4294967296).start(?)"}, +{"ast":{"table":"comment","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":0}},"related":[{"correlation":{"parentField":["id"],"childField":["closed"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"simple","op":"!=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}},"start":{"row":{"id":1.5,"createdAt":2.5},"exclusive":true},"limit":10},"system":"client"},{"correlation":{"parentField":["createdAt"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"simple","op":">","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},{"type":"simple","op":"=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[]}},{"type":"simple","op":"=","left":{"type":"literal","value":2147483648},"right":{"type":"literal","value":0}}]},"related":[{"correlation":{"parentField":["closed"],"childField":["createdAt"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["é"],"childField":["title"]},"subquery":{"table":"comment","alias":"zsubq_b","orderBy":[["title","desc"],["id","asc"]]}},"op":"NOT EXISTS"},"start":{"row":{"id":"é","createdAt":1},"exclusive":false},"orderBy":[["a","asc"],["id","asc"]]},"system":"test"},{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"or","conditions":[{"type":"simple","op":">=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":[]}},{"type":"simple","op":"<","left":{"type":"literal","value":null},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}}]}},"system":"permissions"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"and","conditions":[{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"a"},"right":{"type":"literal","value":[-1,2147483648,1]}},{"type":"simple","op":"!=","left":{"type":"column","name":"title"},"right":{"type":"static","anchor":"preMutationRow","field":["a","b"]}},{"type":"simple","op":"<","left":{"type":"column","name":"é"},"right":{"type":"literal","value":false}}]},"orderBy":[["title","desc"],["id","asc"]]}}],"orderBy":[["ownerId","desc"]]},"system":"test"}],"start":{"row":{"id":"é","createdAt":null},"exclusive":true},"limit":4294967296,"orderBy":[["id","asc"],["id","asc"]]},"zql":".where('createdAt', 'ILIKE', 0).related('owner', q => q.where('closed', '!=', null).limit(10).start({\"id\":1.5,\"createdAt\":2.5})).related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('ownerId', '>', null), cmp('é', []), cmp(2147483648, 0))).related('comments', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('title', 'desc').orderBy('id', 'asc')))).orderBy('a', 'asc').orderBy('id', 'asc').start({\"id\":\"é\",\"createdAt\":1}, { inclusive: true })).related('owner', q => q.where(({cmp, or}) => or(cmp('title', '>=', []), cmp(null, '<', authParam('sub'))))).related('zsubq_a', q => q.where('a', 'NOT LIKE', [-1,2147483648,1]).where('title', '!=', authParam(['a', 'b'])).where('é', '<', false).orderBy('title', 'desc').orderBy('id', 'asc')).orderBy('ownerId', 'desc')).orderBy('id', 'asc').orderBy('id', 'asc').limit(4294967296).start({\"id\":\"é\",\"createdAt\":null})","redacted":".where('createdAt', 'ILIKE', ?).related('owner', q => q.where('closed', '!=', ?).limit(10).start(?)).related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('ownerId', '>', ?), cmp('é', ?), cmp(?, ?))).related('comments', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('title', 'desc').orderBy('id', 'asc')))).orderBy('a', 'asc').orderBy('id', 'asc').start(?, { inclusive: true })).related('owner', q => q.where(({cmp, or}) => or(cmp('title', '>=', ?), cmp(?, '<', authParam('sub'))))).related('zsubq_a', q => q.where('a', 'NOT LIKE', ?).where('title', '!=', authParam(['a', 'b'])).where('é', '<', ?).orderBy('title', 'desc').orderBy('id', 'asc')).orderBy('ownerId', 'desc')).orderBy('id', 'asc').orderBy('id', 'asc').limit(4294967296).start(?)"}, +{"ast":{"table":"comment","where":{"type":"or","conditions":[{"type":"and","conditions":[]}]},"related":[{"correlation":{"parentField":["é"],"childField":["a"]},"subquery":{"table":"user","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":"1"}}},"system":"permissions","hidden":false}],"limit":4294967296,"start":{"row":{"id":"😀","createdAt":1},"exclusive":true}},"zql":".related('owner', q => q.where('ownerId', '1')).limit(4294967296).start({\"id\":\"😀\",\"createdAt\":1})","redacted":".related('owner', q => q.where('ownerId', ?)).limit(4294967296).start(?)"}, +{"ast":{"table":"comment","where":{"type":"and","conditions":[]},"related":[{"correlation":{"parentField":["é"],"childField":["a"]},"hidden":false,"subquery":{"table":"user","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":"1"}}},"system":"permissions"}],"start":{"row":{"id":"😀","createdAt":1},"exclusive":true},"limit":4294967296},"zql":".related('owner', q => q.where('ownerId', '1')).limit(4294967296).start({\"id\":\"😀\",\"createdAt\":1})","redacted":".related('owner', q => q.where('ownerId', ?)).limit(4294967296).start(?)"}, +{"ast":{"table":"label","where":{"type":"simple","op":"<=","left":{"type":"literal","value":1.5},"right":{"type":"literal","value":[""]}},"related":[{"correlation":{"parentField":["ownerId"],"childField":["closed"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"owner","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":true}},"start":{"row":{"id":1.5,"createdAt":1},"exclusive":false}},"system":"permissions"},"scalar":true},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"label","alias":"comments","where":{"type":"or","conditions":[]}},"system":"test"}],"limit":0,"start":{"row":{"id":1,"createdAt":1},"exclusive":true}},"system":"client"},{"correlation":{"parentField":["é"],"childField":["title"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"or","conditions":[{"type":"or","conditions":[]},{"type":"and","conditions":[{"type":"simple","op":"LIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":null}},{"type":"simple","op":">=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":null}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"id"},"right":{"type":"literal","value":"😀"}}]},{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["é"],"childField":["closed"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"é"},"right":{"type":"literal","value":null}},"orderBy":[["title","asc"],["id","asc"]]},"system":"test"}},{"type":"or","conditions":[]}]},"related":[{"correlation":{"parentField":["createdAt"],"childField":["a"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"!=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}},"orderBy":[["createdAt","desc"]]},"system":"client"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"zsubq_a","orderBy":[["createdAt","asc"]],"start":{"row":{"id":"é","createdAt":null},"exclusive":false}},"hidden":true},{"correlation":{"parentField":["a"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"simple","op":">","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"static","anchor":"preMutationRow","field":["a","b"]}},"orderBy":[["ownerId","desc"],["id","asc"]]}}]}},{"correlation":{"parentField":["title"],"childField":["id"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["ownerId"],"childField":["é"]},"subquery":{"table":"comment","alias":"zsubq_b","orderBy":[["closed","desc"],["id","asc"]]}},"scalar":true},"related":[{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["ownerId"],"childField":["é"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"simple","op":"LIKE","left":{"type":"column","name":"id"},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}},"limit":1.5,"orderBy":[["é","asc"],["id","asc"]]},"hidden":true}},"orderBy":[["closed","desc"],["id","asc"]]}},{"correlation":{"parentField":["title"],"childField":["ownerId"]},"subquery":{"table":"label","alias":"owner","where":{"type":"and","conditions":[{"type":"simple","op":"<=","left":{"type":"column","name":"é"},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}}]},"start":{"row":{"id":0,"createdAt":2.5},"exclusive":true}},"system":"test"},{"correlation":{"parentField":["a"],"childField":["closed"]},"subquery":{"table":"user","alias":"comments","where":{"type":"or","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":[2147483648,"é",0]}},{"type":"simple","op":"ILIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":[false,""]}}]}}}],"orderBy":[["closed","asc"],["id","asc"]],"start":{"row":{"id":-1,"createdAt":2.5},"exclusive":true}},"system":"permissions"}],"limit":1.5},"zql":".where(1.5, '<=', [\"\"]).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('createdAt', 'NOT IN', true).start({\"id\":1.5,\"createdAt\":1}, { inclusive: true }), {scalar: true}))).related('comments', q => q.where(({cmp, or}) => or())).limit(0).start({\"id\":1,\"createdAt\":1})).related('zsubq_b', q => q.where(({and, cmp, exists, or}) => or(or(), and(cmp('createdAt', 'LIKE', null), cmp('é', '>=', null), cmp('id', 'NOT IN', '😀')), exists('b', q => q.where('é', 'NOT IN', null).orderBy('title', 'asc').orderBy('id', 'asc')), or())).related('zsubq_b', q => q.where('closed', '!=', null).orderBy('createdAt', 'desc')).related('zsubq_b', q => q.where(authParam('sub'), '>', authParam(['a', 'b'])).orderBy('ownerId', 'desc').orderBy('id', 'asc'))).related('zsubq_a', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('closed', 'desc').orderBy('id', 'asc'), {scalar: true}))).related('zsubq_b', q => q.whereExists('a', q => q.where('id', 'LIKE', authParam('sub')).orderBy('é', 'asc').orderBy('id', 'asc').limit(1.5)).orderBy('closed', 'desc').orderBy('id', 'asc')).related('owner', q => q.where('é', '<=', authParam('sub')).start({\"id\":0,\"createdAt\":2.5})).related('comments', q => q.where(({cmp, or}) => or(cmp('ownerId', '<', [2147483648,\"é\",0]), cmp('id', 'ILIKE', [false,\"\"])))).orderBy('closed', 'asc').orderBy('id', 'asc').start({\"id\":-1,\"createdAt\":2.5})).limit(1.5)","redacted":".where(?, '<=', ?).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('createdAt', 'NOT IN', ?).start(?, { inclusive: true }), {scalar: true}))).related('comments', q => q.where(({cmp, or}) => or())).limit(0).start(?)).related('zsubq_b', q => q.where(({and, cmp, exists, or}) => or(or(), and(cmp('createdAt', 'LIKE', ?), cmp('é', '>=', ?), cmp('id', 'NOT IN', ?)), exists('b', q => q.where('é', 'NOT IN', ?).orderBy('title', 'asc').orderBy('id', 'asc')), or())).related('zsubq_b', q => q.where('closed', '!=', ?).orderBy('createdAt', 'desc')).related('zsubq_b', q => q.where(authParam('sub'), '>', authParam(['a', 'b'])).orderBy('ownerId', 'desc').orderBy('id', 'asc'))).related('zsubq_a', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('closed', 'desc').orderBy('id', 'asc'), {scalar: true}))).related('zsubq_b', q => q.whereExists('a', q => q.where('id', 'LIKE', authParam('sub')).orderBy('é', 'asc').orderBy('id', 'asc').limit(1.5)).orderBy('closed', 'desc').orderBy('id', 'asc')).related('owner', q => q.where('é', '<=', authParam('sub')).start(?)).related('comments', q => q.where(({cmp, or}) => or(cmp('ownerId', '<', ?), cmp('id', 'ILIKE', ?)))).orderBy('closed', 'asc').orderBy('id', 'asc').start(?)).limit(1.5)"}, +{"ast":{"table":"label","where":{"type":"simple","op":"<=","left":{"type":"literal","value":1.5},"right":{"type":"literal","value":[""]}},"related":[{"correlation":{"parentField":["ownerId"],"childField":["closed"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"owner","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":true}},"start":{"row":{"id":1.5,"createdAt":1},"exclusive":false}},"system":"permissions"},"op":"NOT EXISTS","scalar":true},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"label","alias":"comments","where":{"type":"or","conditions":[]}},"system":"test"}],"start":{"row":{"id":1,"createdAt":1},"exclusive":true},"limit":0},"system":"client"},{"correlation":{"parentField":["title"],"childField":["id"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["ownerId"],"childField":["é"]},"subquery":{"table":"comment","alias":"zsubq_b","orderBy":[["closed","desc"],["id","asc"]]}},"op":"NOT EXISTS","scalar":true},"related":[{"correlation":{"parentField":["a"],"childField":["closed"]},"subquery":{"table":"user","alias":"comments","where":{"type":"or","conditions":[{"type":"simple","op":"ILIKE","left":{"type":"column","name":"id"},"right":{"type":"literal","value":[false,""]}},{"type":"simple","op":"<","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":[2147483648,"é",0]}}]}}},{"correlation":{"parentField":["title"],"childField":["ownerId"]},"subquery":{"table":"label","alias":"owner","where":{"type":"simple","op":"<=","left":{"type":"column","name":"é"},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}},"start":{"row":{"id":0,"createdAt":2.5},"exclusive":true}},"system":"test"},{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["ownerId"],"childField":["é"]},"hidden":true,"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"simple","op":"LIKE","left":{"type":"column","name":"id"},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}},"limit":1.5,"orderBy":[["é","asc"],["id","asc"]]}},"op":"EXISTS"},"orderBy":[["closed","desc"],["id","asc"]]}}],"start":{"row":{"id":-1,"createdAt":2.5},"exclusive":true},"orderBy":[["closed","asc"],["id","asc"]]},"system":"permissions"},{"correlation":{"parentField":["é"],"childField":["title"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"or","conditions":[{"type":"correlatedSubquery","related":{"correlation":{"parentField":["é"],"childField":["closed"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"é"},"right":{"type":"literal","value":null}},"orderBy":[["title","asc"],["id","asc"]]},"system":"test"},"op":"EXISTS"},{"type":"and","conditions":[{"type":"simple","op":"LIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":null}},{"type":"simple","op":"NOT IN","left":{"type":"column","name":"id"},"right":{"type":"literal","value":"😀"}},{"type":"simple","op":">=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":null}}]}]},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"hidden":true,"subquery":{"table":"issue","alias":"zsubq_a","start":{"row":{"id":"é","createdAt":null},"exclusive":false},"orderBy":[["createdAt","asc"]]}},{"correlation":{"parentField":["createdAt"],"childField":["a"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"!=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":null}},"orderBy":[["createdAt","desc"]]},"system":"client"},{"correlation":{"parentField":["a"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"simple","op":">","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"static","anchor":"preMutationRow","field":["a","b"]}},"orderBy":[["ownerId","desc"],["id","asc"]]}}]}}],"limit":1.5},"zql":".where(1.5, '<=', [\"\"]).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('createdAt', 'NOT IN', true).start({\"id\":1.5,\"createdAt\":1}, { inclusive: true }), {scalar: true}))).related('comments', q => q.where(({cmp, or}) => or())).limit(0).start({\"id\":1,\"createdAt\":1})).related('zsubq_a', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('closed', 'desc').orderBy('id', 'asc'), {scalar: true}))).related('comments', q => q.where(({cmp, or}) => or(cmp('id', 'ILIKE', [false,\"\"]), cmp('ownerId', '<', [2147483648,\"é\",0])))).related('owner', q => q.where('é', '<=', authParam('sub')).start({\"id\":0,\"createdAt\":2.5})).related('zsubq_b', q => q.whereExists('a', q => q.where('id', 'LIKE', authParam('sub')).orderBy('é', 'asc').orderBy('id', 'asc').limit(1.5)).orderBy('closed', 'desc').orderBy('id', 'asc')).orderBy('closed', 'asc').orderBy('id', 'asc').start({\"id\":-1,\"createdAt\":2.5})).related('zsubq_b', q => q.where(({and, cmp, exists, or}) => or(exists('b', q => q.where('é', 'NOT IN', null).orderBy('title', 'asc').orderBy('id', 'asc')), and(cmp('createdAt', 'LIKE', null), cmp('id', 'NOT IN', '😀'), cmp('é', '>=', null)))).related('zsubq_b', q => q.where('closed', '!=', null).orderBy('createdAt', 'desc')).related('zsubq_b', q => q.where(authParam('sub'), '>', authParam(['a', 'b'])).orderBy('ownerId', 'desc').orderBy('id', 'asc'))).limit(1.5)","redacted":".where(?, '<=', ?).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('createdAt', 'NOT IN', ?).start(?, { inclusive: true }), {scalar: true}))).related('comments', q => q.where(({cmp, or}) => or())).limit(0).start(?)).related('zsubq_a', q => q.where(({exists, not}) => not(exists('b', q => q.orderBy('closed', 'desc').orderBy('id', 'asc'), {scalar: true}))).related('comments', q => q.where(({cmp, or}) => or(cmp('id', 'ILIKE', ?), cmp('ownerId', '<', ?)))).related('owner', q => q.where('é', '<=', authParam('sub')).start(?)).related('zsubq_b', q => q.whereExists('a', q => q.where('id', 'LIKE', authParam('sub')).orderBy('é', 'asc').orderBy('id', 'asc').limit(1.5)).orderBy('closed', 'desc').orderBy('id', 'asc')).orderBy('closed', 'asc').orderBy('id', 'asc').start(?)).related('zsubq_b', q => q.where(({and, cmp, exists, or}) => or(exists('b', q => q.where('é', 'NOT IN', ?).orderBy('title', 'asc').orderBy('id', 'asc')), and(cmp('createdAt', 'LIKE', ?), cmp('id', 'NOT IN', ?), cmp('é', '>=', ?)))).related('zsubq_b', q => q.where('closed', '!=', ?).orderBy('createdAt', 'desc')).related('zsubq_b', q => q.where(authParam('sub'), '>', authParam(['a', 'b'])).orderBy('ownerId', 'desc').orderBy('id', 'asc'))).limit(1.5)"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":[1]}},"related":[{"correlation":{"parentField":["createdAt"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":1}},"related":[{"correlation":{"parentField":["id"],"childField":["é"]},"subquery":{"table":"user","alias":"zsubq_a","schema":"public","where":{"type":"simple","op":"<=","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":null}},"start":{"row":{"id":0,"createdAt":1},"exclusive":true}},"hidden":true}]},"hidden":true},{"correlation":{"parentField":["createdAt"],"childField":["id"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":">","left":{"type":"column","name":"createdAt"},"right":{"type":"static","anchor":"authData","field":["a","b"]}},"limit":100}},{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"user","alias":"owner","related":[{"correlation":{"parentField":["title"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"and","conditions":[]}},"system":"client"},{"correlation":{"parentField":["title"],"childField":["a"]},"subquery":{"table":"comment","alias":"zsubq_a","schema":"public","orderBy":[["é","asc"],["id","asc"]],"start":{"row":{"id":"1","createdAt":1},"exclusive":false}},"system":"test"},{"correlation":{"parentField":["é"],"childField":["ownerId"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["title"],"childField":["closed"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"simple","op":"IS NOT","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},"orderBy":[["title","desc"],["id","asc"]]}},"flip":false}}}]}}]},"zql":".where('createdAt', 'NOT IN', [1]).related('zsubq_a', q => q.where('createdAt', '<=', null).start({\"id\":0,\"createdAt\":1})).related('zsubq_b', q => q.where('createdAt', '>', authParam(['a', 'b'])).limit(100)).related('owner', q => q.related('zsubq_b', q => q).related('zsubq_a', q => q.orderBy('é', 'asc').orderBy('id', 'asc').start({\"id\":\"1\",\"createdAt\":1}, { inclusive: true })).related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('ownerId', 'IS NOT', null).orderBy('title', 'desc').orderBy('id', 'asc'), {flip: false})))))","redacted":".where('createdAt', 'NOT IN', ?).related('zsubq_a', q => q.where('createdAt', '<=', ?).start(?)).related('zsubq_b', q => q.where('createdAt', '>', authParam(['a', 'b'])).limit(100)).related('owner', q => q.related('zsubq_b', q => q).related('zsubq_a', q => q.orderBy('é', 'asc').orderBy('id', 'asc').start(?, { inclusive: true })).related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('ownerId', 'IS NOT', ?).orderBy('title', 'desc').orderBy('id', 'asc'), {flip: false})))))"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":[1]}},"related":[{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"user","alias":"owner","related":[{"correlation":{"parentField":["é"],"childField":["ownerId"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["title"],"childField":["closed"]},"subquery":{"table":"issue","alias":"zsubq_a","where":{"type":"simple","op":"IS NOT","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},"orderBy":[["title","desc"],["id","asc"]]}},"op":"NOT EXISTS","flip":false}}},{"correlation":{"parentField":["title"],"childField":["a"]},"subquery":{"schema":"public","table":"comment","alias":"zsubq_a","start":{"row":{"id":"1","createdAt":1},"exclusive":false},"orderBy":[["é","asc"],["id","asc"]]},"system":"test"},{"correlation":{"parentField":["title"],"childField":["é"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"and","conditions":[]}},"system":"client"}]}},{"correlation":{"parentField":["createdAt"],"childField":["title"]},"hidden":true,"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":1}},"related":[{"correlation":{"parentField":["id"],"childField":["é"]},"hidden":true,"subquery":{"schema":"public","table":"user","alias":"zsubq_a","where":{"type":"simple","op":"<=","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":null}},"start":{"row":{"id":0,"createdAt":1},"exclusive":true}}}]}},{"correlation":{"parentField":["createdAt"],"childField":["id"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":">","left":{"type":"column","name":"createdAt"},"right":{"type":"static","anchor":"authData","field":["a","b"]}},"limit":100}}]},"zql":".where('createdAt', 'NOT IN', [1]).related('owner', q => q.related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('ownerId', 'IS NOT', null).orderBy('title', 'desc').orderBy('id', 'asc'), {flip: false})))).related('zsubq_a', q => q.orderBy('é', 'asc').orderBy('id', 'asc').start({\"id\":\"1\",\"createdAt\":1}, { inclusive: true })).related('zsubq_b', q => q)).related('zsubq_a', q => q.where('createdAt', '<=', null).start({\"id\":0,\"createdAt\":1})).related('zsubq_b', q => q.where('createdAt', '>', authParam(['a', 'b'])).limit(100))","redacted":".where('createdAt', 'NOT IN', ?).related('owner', q => q.related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('ownerId', 'IS NOT', ?).orderBy('title', 'desc').orderBy('id', 'asc'), {flip: false})))).related('zsubq_a', q => q.orderBy('é', 'asc').orderBy('id', 'asc').start(?, { inclusive: true })).related('zsubq_b', q => q)).related('zsubq_a', q => q.where('createdAt', '<=', ?).start(?)).related('zsubq_b', q => q.where('createdAt', '>', authParam(['a', 'b'])).limit(100))"}, +{"ast":{"table":"comment","related":[{"correlation":{"parentField":["createdAt"],"childField":["a"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"owner","limit":1.5}}},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"label","alias":"zsubq_a","schema":"public","where":{"type":"or","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":1.5}},{"type":"simple","op":"IS NOT","left":{"type":"column","name":"id"},"right":{"type":"literal","value":"é"}},{"type":"simple","op":">","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}},{"type":"simple","op":">","left":{"type":"column","name":"title"},"right":{"type":"literal","value":1e+21}}]}},"hidden":true},{"correlation":{"parentField":["id"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":["é",true]}},"limit":100},"system":"permissions"}],"orderBy":[["title","asc"]]},"hidden":true},{"correlation":{"parentField":["closed"],"childField":["a"]},"subquery":{"table":"issue","alias":"zsubq_b"}},{"correlation":{"parentField":["é"],"childField":["title"]},"subquery":{"table":"comment","alias":"comments","related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"zsubq_a"},"hidden":false},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"simple","op":"!=","left":{"type":"literal","value":1.5},"right":{"type":"literal","value":null}},"limit":100,"orderBy":[["ownerId","asc"]]}}],"orderBy":[["title","asc"]]}}],"start":{"row":{"id":"😀","createdAt":1},"exclusive":false}},"zql":".related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('a', '<', 1.5), cmp('id', 'IS NOT', 'é'), cmp('a', '>', null), cmp('title', '>', 1e+21)))).related('zsubq_b').related('comments', q => q.related('zsubq_a').related('zsubq_b', q => q.where(1.5, '!=', null).orderBy('ownerId', 'asc').limit(100)).orderBy('title', 'asc')).start({\"id\":\"😀\",\"createdAt\":1}, { inclusive: true })","redacted":".related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('a', '<', ?), cmp('id', 'IS NOT', ?), cmp('a', '>', ?), cmp('title', '>', ?)))).related('zsubq_b').related('comments', q => q.related('zsubq_a').related('zsubq_b', q => q.where(?, '!=', ?).orderBy('ownerId', 'asc').limit(100)).orderBy('title', 'asc')).start(?, { inclusive: true })"}, +{"ast":{"table":"comment","related":[{"correlation":{"parentField":["é"],"childField":["title"]},"subquery":{"table":"comment","alias":"comments","related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"hidden":false,"subquery":{"table":"comment","alias":"zsubq_a"}},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"simple","op":"!=","left":{"type":"literal","value":1.5},"right":{"type":"literal","value":null}},"limit":100,"orderBy":[["ownerId","asc"]]}}],"orderBy":[["title","asc"]]}},{"correlation":{"parentField":["createdAt"],"childField":["a"]},"hidden":true,"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"owner","limit":1.5}},"op":"NOT EXISTS"},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"hidden":true,"subquery":{"schema":"public","table":"label","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":1.5}},{"type":"simple","op":">","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}},{"type":"simple","op":"IS NOT","left":{"type":"column","name":"id"},"right":{"type":"literal","value":"é"}},{"type":"simple","op":">","left":{"type":"column","name":"title"},"right":{"type":"literal","value":1e+21}}]}}},{"correlation":{"parentField":["id"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_b","where":{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":["é",true]}},"limit":100},"system":"permissions"}],"orderBy":[["title","asc"]]}},{"correlation":{"parentField":["closed"],"childField":["a"]},"subquery":{"table":"issue","alias":"zsubq_b"}}],"start":{"row":{"id":"😀","createdAt":1},"exclusive":false}},"zql":".related('comments', q => q.related('zsubq_a').related('zsubq_b', q => q.where(1.5, '!=', null).orderBy('ownerId', 'asc').limit(100)).orderBy('title', 'asc')).related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('a', '<', 1.5), cmp('a', '>', null), cmp('id', 'IS NOT', 'é'), cmp('title', '>', 1e+21)))).related('zsubq_b').start({\"id\":\"😀\",\"createdAt\":1}, { inclusive: true })","redacted":".related('comments', q => q.related('zsubq_a').related('zsubq_b', q => q.where(?, '!=', ?).orderBy('ownerId', 'asc').limit(100)).orderBy('title', 'asc')).related('zsubq_a', q => q.where(({cmp, or}) => or(cmp('a', '<', ?), cmp('a', '>', ?), cmp('id', 'IS NOT', ?), cmp('title', '>', ?)))).related('zsubq_b').start(?, { inclusive: true })"}, +{"ast":{"table":"label","start":{"row":{"id":0,"createdAt":1},"exclusive":true}},"zql":".start({\"id\":0,\"createdAt\":1})","redacted":".start(?)"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"IS","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}},"related":[{"correlation":{"parentField":["title"],"childField":["createdAt"]},"subquery":{"table":"comment","alias":"zsubq_b","related":[{"correlation":{"parentField":["createdAt"],"childField":["closed"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"and","conditions":[{"type":"simple","op":"NOT ILIKE","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}}]},"orderBy":[["title","asc"]]},"hidden":true},{"correlation":{"parentField":["closed"],"childField":["ownerId"]},"subquery":{"table":"comment","alias":"comments","schema":"public","where":{"type":"simple","op":"<","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":"é"}}}},{"correlation":{"parentField":["é"],"childField":["closed"]},"subquery":{"table":"comment","alias":"zsubq_a","where":{"type":"simple","op":"IS","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},"orderBy":[["title","desc"]]}}],"limit":100},"hidden":true},{"correlation":{"parentField":["id"],"childField":["é"]},"subquery":{"table":"comment","alias":"owner","schema":"public","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"user","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[-1,2147483648]}},"limit":100,"orderBy":[["closed","asc"]]}},"scalar":true},"start":{"row":{"id":1.5,"createdAt":2.5},"exclusive":false}},"hidden":false}],"limit":100,"orderBy":[["closed","desc"],["id","asc"]],"start":{"row":{"id":"é","createdAt":2.5},"exclusive":false}},"zql":".where('a', 'IS', null).related('zsubq_b', q => q.where(authParam('sub'), 'NOT ILIKE', authParam('sub')).orderBy('title', 'asc')).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('é', [-1,2147483648]).orderBy('closed', 'asc').limit(100), {scalar: true}))).start({\"id\":1.5,\"createdAt\":2.5}, { inclusive: true })).orderBy('closed', 'desc').orderBy('id', 'asc').limit(100).start({\"id\":\"é\",\"createdAt\":2.5}, { inclusive: true })","redacted":".where('a', 'IS', ?).related('zsubq_b', q => q.where(authParam('sub'), 'NOT ILIKE', authParam('sub')).orderBy('title', 'asc')).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('é', ?).orderBy('closed', 'asc').limit(100), {scalar: true}))).start(?, { inclusive: true })).orderBy('closed', 'desc').orderBy('id', 'asc').limit(100).start(?, { inclusive: true })"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"IS","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}},"related":[{"correlation":{"parentField":["id"],"childField":["é"]},"hidden":false,"subquery":{"schema":"public","table":"comment","alias":"owner","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"user","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"column","name":"é"},"right":{"type":"literal","value":[-1,2147483648]}},"limit":100,"orderBy":[["closed","asc"]]}},"op":"NOT EXISTS","scalar":true},"start":{"row":{"id":1.5,"createdAt":2.5},"exclusive":false}}},{"correlation":{"parentField":["title"],"childField":["createdAt"]},"hidden":true,"subquery":{"table":"comment","alias":"zsubq_b","related":[{"correlation":{"parentField":["closed"],"childField":["ownerId"]},"subquery":{"schema":"public","table":"comment","alias":"comments","where":{"type":"simple","op":"<","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":"é"}}}},{"correlation":{"parentField":["é"],"childField":["closed"]},"subquery":{"table":"comment","alias":"zsubq_a","where":{"type":"simple","op":"IS","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},"orderBy":[["title","desc"]]}},{"correlation":{"parentField":["createdAt"],"childField":["closed"]},"hidden":true,"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"static","anchor":"preMutationRow","field":"sub"}},"orderBy":[["title","asc"]]}}],"limit":100}}],"start":{"row":{"id":"é","createdAt":2.5},"exclusive":false},"limit":100,"orderBy":[["closed","desc"],["id","asc"]]},"zql":".where('a', 'IS', null).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('é', [-1,2147483648]).orderBy('closed', 'asc').limit(100), {scalar: true}))).start({\"id\":1.5,\"createdAt\":2.5}, { inclusive: true })).related('comments', q => q.where('closed', '<', 'é')).orderBy('closed', 'desc').orderBy('id', 'asc').limit(100).start({\"id\":\"é\",\"createdAt\":2.5}, { inclusive: true })","redacted":".where('a', 'IS', ?).related('owner', q => q.where(({exists, not}) => not(exists('owner', q => q.where('é', ?).orderBy('closed', 'asc').limit(100), {scalar: true}))).start(?, { inclusive: true })).related('comments', q => q.where('closed', '<', ?)).orderBy('closed', 'desc').orderBy('id', 'asc').limit(100).start(?, { inclusive: true })"}, +{"ast":{"table":"comment","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},"related":[{"correlation":{"parentField":["title"],"childField":["a"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"=","left":{"type":"column","name":"id"},"right":{"type":"literal","value":2147483648}},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"zsubq_b","start":{"row":{"id":"😀","createdAt":1},"exclusive":true}},"system":"test","hidden":false}],"start":{"row":{"id":-2147483649,"createdAt":1},"exclusive":false}}},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":"é"}},"related":[{"correlation":{"parentField":["é"],"childField":["createdAt"]},"subquery":{"table":"label","alias":"comments","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":0}},"orderBy":[["é","asc"]]},"system":"test","hidden":true}],"orderBy":[["é","asc"]],"start":{"row":{"id":1e+21,"createdAt":1},"exclusive":false}}},{"correlation":{"parentField":["createdAt"],"childField":["ownerId"]},"subquery":{"table":"user","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["title"],"childField":["id"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":false}}}}}]},"orderBy":[["a","asc"],["id","asc"]]}}]},"zql":".where('ownerId', 'NOT LIKE', null).related('zsubq_b', q => q.where('id', 2147483648).related('zsubq_b').start({\"id\":-2147483649,\"createdAt\":1}, { inclusive: true })).related('owner', q => q.where('closed', 'ILIKE', 'é').orderBy('é', 'asc').start({\"id\":1e+21,\"createdAt\":1}, { inclusive: true })).related('zsubq_a', q => q.whereExists('b', q => q.where('createdAt', 'ILIKE', false)).orderBy('a', 'asc').orderBy('id', 'asc'))","redacted":".where('ownerId', 'NOT LIKE', ?).related('zsubq_b', q => q.where('id', ?).related('zsubq_b').start(?, { inclusive: true })).related('owner', q => q.where('closed', 'ILIKE', ?).orderBy('é', 'asc').start(?, { inclusive: true })).related('zsubq_a', q => q.whereExists('b', q => q.where('createdAt', 'ILIKE', ?)).orderBy('a', 'asc').orderBy('id', 'asc'))"}, +{"ast":{"table":"comment","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":"é"}},"related":[{"correlation":{"parentField":["é"],"childField":["createdAt"]},"hidden":true,"subquery":{"table":"label","alias":"comments","where":{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":0}},"orderBy":[["é","asc"]]},"system":"test"}],"start":{"row":{"id":1e+21,"createdAt":1},"exclusive":false},"orderBy":[["é","asc"]]}},{"correlation":{"parentField":["createdAt"],"childField":["ownerId"]},"subquery":{"table":"user","alias":"zsubq_a","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["title"],"childField":["id"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"simple","op":"ILIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":false}}}},"op":"EXISTS"},"orderBy":[["a","asc"],["id","asc"]]}},{"correlation":{"parentField":["title"],"childField":["a"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"=","left":{"type":"column","name":"id"},"right":{"type":"literal","value":2147483648}},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"hidden":false,"subquery":{"table":"issue","alias":"zsubq_b","start":{"row":{"id":"😀","createdAt":1},"exclusive":true}},"system":"test"}],"start":{"row":{"id":-2147483649,"createdAt":1},"exclusive":false}}}]},"zql":".where('ownerId', 'NOT LIKE', null).related('owner', q => q.where('closed', 'ILIKE', 'é').orderBy('é', 'asc').start({\"id\":1e+21,\"createdAt\":1}, { inclusive: true })).related('zsubq_a', q => q.whereExists('b', q => q.where('createdAt', 'ILIKE', false)).orderBy('a', 'asc').orderBy('id', 'asc')).related('zsubq_b', q => q.where('id', 2147483648).related('zsubq_b').start({\"id\":-2147483649,\"createdAt\":1}, { inclusive: true }))","redacted":".where('ownerId', 'NOT LIKE', ?).related('owner', q => q.where('closed', 'ILIKE', ?).orderBy('é', 'asc').start(?, { inclusive: true })).related('zsubq_a', q => q.whereExists('b', q => q.where('createdAt', 'ILIKE', ?)).orderBy('a', 'asc').orderBy('id', 'asc')).related('zsubq_b', q => q.where('id', ?).related('zsubq_b').start(?, { inclusive: true }))"}, +{"ast":{"table":"issue","orderBy":[["id","asc"]],"start":{"row":{"id":2147483648,"createdAt":null},"exclusive":true}},"zql":".orderBy('id', 'asc').start({\"id\":2147483648,\"createdAt\":null})","redacted":".orderBy('id', 'asc').start(?)"}, +{"ast":{"table":"issue","start":{"row":{"id":2147483648,"createdAt":null},"exclusive":true},"orderBy":[["id","asc"]]},"zql":".orderBy('id', 'asc').start({\"id\":2147483648,\"createdAt\":null})","redacted":".orderBy('id', 'asc').start(?)"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[]},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"user","alias":"zsubq_a","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":"é"}},"related":[{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"or","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}}]}},"system":"test","hidden":true},{"correlation":{"parentField":["closed"],"childField":["a"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"simple","op":"<","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":0}},"limit":4294967296,"orderBy":[["closed","desc"]],"start":{"row":{"id":"","createdAt":null},"exclusive":true}}}],"start":{"row":{"id":"😀","createdAt":2.5},"exclusive":true}},"hidden":true},{"correlation":{"parentField":["createdAt"],"childField":["id"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"or","conditions":[{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":null}},{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"<=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":null}}}}},{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"owner"},"system":"test"}},{"type":"or","conditions":[]}]}},"system":"client"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"zsubq_a","schema":"public","where":{"type":"or","conditions":[{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":1}},{"type":"or","conditions":[{"type":"simple","op":"IS NOT","left":{"type":"column","name":"id"},"right":{"type":"literal","value":null}}]},{"type":"simple","op":"<","left":{"type":"column","name":"title"},"right":{"type":"literal","value":false}},{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["title"],"childField":["closed"]},"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"simple","op":">=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":[2147483648]}}},"system":"client","hidden":true}}]}}}],"orderBy":[["createdAt","desc"]]},"zql":".related('comments', q => q.where('a', '<', null)).related('owner', q => q.where(({cmp, exists, not, or}) => or(cmp('createdAt', 'NOT ILIKE', null), not(exists('b', q => q.where('title', '<=', null))), not(exists('owner')), or()))).related('zsubq_a', q => q.where(({cmp, exists, or}) => or(cmp('closed', 'NOT ILIKE', 1), cmp('id', 'IS NOT', null), cmp('title', '<', false), exists('b', q => q.where('closed', '>=', [2147483648]))))).orderBy('createdAt', 'desc')","redacted":".related('comments', q => q.where('a', '<', ?)).related('owner', q => q.where(({cmp, exists, not, or}) => or(cmp('createdAt', 'NOT ILIKE', ?), not(exists('b', q => q.where('title', '<=', ?))), not(exists('owner')), or()))).related('zsubq_a', q => q.where(({cmp, exists, or}) => or(cmp('closed', 'NOT ILIKE', ?), cmp('id', 'IS NOT', ?), cmp('title', '<', ?), exists('b', q => q.where('closed', '>=', ?))))).orderBy('createdAt', 'desc')"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[]},"related":[{"correlation":{"parentField":["createdAt"],"childField":["id"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"or","conditions":[{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":null}},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"owner"},"system":"test"},"op":"NOT EXISTS"},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"zsubq_b","where":{"type":"simple","op":"<=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":null}}}},"op":"NOT EXISTS"}]}},"system":"client"},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"hidden":true,"subquery":{"table":"user","alias":"zsubq_a","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":"é"}},"related":[{"correlation":{"parentField":["ownerId"],"childField":["a"]},"hidden":true,"subquery":{"table":"comment","alias":"comments","where":{"type":"simple","op":"<","left":{"type":"column","name":"a"},"right":{"type":"literal","value":null}}},"system":"test"},{"correlation":{"parentField":["closed"],"childField":["a"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"simple","op":"<","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":0}},"start":{"row":{"id":"","createdAt":null},"exclusive":true},"limit":4294967296,"orderBy":[["closed","desc"]]}}],"start":{"row":{"id":"😀","createdAt":2.5},"exclusive":true}}},{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"schema":"public","table":"issue","alias":"zsubq_a","where":{"type":"or","conditions":[{"type":"simple","op":"NOT ILIKE","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":1}},{"type":"simple","op":"IS NOT","left":{"type":"column","name":"id"},"right":{"type":"literal","value":null}},{"type":"simple","op":"<","left":{"type":"column","name":"title"},"right":{"type":"literal","value":false}},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["title"],"childField":["closed"]},"hidden":true,"subquery":{"table":"label","alias":"zsubq_b","where":{"type":"simple","op":">=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":[2147483648]}}},"system":"client"},"op":"EXISTS"}]}}}],"orderBy":[["createdAt","desc"]]},"zql":".related('owner', q => q.where(({cmp, exists, not, or}) => or(cmp('createdAt', 'NOT ILIKE', null), not(exists('owner')), not(exists('b', q => q.where('title', '<=', null)))))).related('comments', q => q.where('a', '<', null)).related('zsubq_a', q => q.where(({cmp, exists, or}) => or(cmp('closed', 'NOT ILIKE', 1), cmp('id', 'IS NOT', null), cmp('title', '<', false), exists('b', q => q.where('closed', '>=', [2147483648]))))).orderBy('createdAt', 'desc')","redacted":".related('owner', q => q.where(({cmp, exists, not, or}) => or(cmp('createdAt', 'NOT ILIKE', ?), not(exists('owner')), not(exists('b', q => q.where('title', '<=', ?)))))).related('comments', q => q.where('a', '<', ?)).related('zsubq_a', q => q.where(({cmp, exists, or}) => or(cmp('closed', 'NOT ILIKE', ?), cmp('id', 'IS NOT', ?), cmp('title', '<', ?), exists('b', q => q.where('closed', '>=', ?))))).orderBy('createdAt', 'desc')"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":1}},{"type":"or","conditions":[{"type":"and","conditions":[{"type":"simple","op":"IN","left":{"type":"column","name":"é"},"right":{"type":"literal","value":0}},{"type":"simple","op":"LIKE","left":{"type":"column","name":"é"},"right":{"type":"literal","value":0}}]}]}]},"start":{"row":{"id":"b","createdAt":null},"exclusive":false}},"zql":".where('ownerId', '<', 1).where('é', 'IN', 0).where('é', 'LIKE', 0).start({\"id\":\"b\",\"createdAt\":null}, { inclusive: true })","redacted":".where('ownerId', '<', ?).where('é', 'IN', ?).where('é', 'LIKE', ?).start(?, { inclusive: true })"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[{"type":"simple","op":"<","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":1}},{"type":"simple","op":"IN","left":{"type":"column","name":"é"},"right":{"type":"literal","value":0}},{"type":"simple","op":"LIKE","left":{"type":"column","name":"é"},"right":{"type":"literal","value":0}}]},"start":{"row":{"id":"b","createdAt":null},"exclusive":false}},"zql":".where('ownerId', '<', 1).where('é', 'IN', 0).where('é', 'LIKE', 0).start({\"id\":\"b\",\"createdAt\":null}, { inclusive: true })","redacted":".where('ownerId', '<', ?).where('é', 'IN', ?).where('é', 'LIKE', ?).start(?, { inclusive: true })"}, +{"ast":{"table":"comment","where":{"type":"or","conditions":[]},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"comments","schema":"public","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"comment","alias":"zsubq_a","where":{"type":"simple","op":"IS","left":{"type":"column","name":"a"},"right":{"type":"literal","value":1.5}},"limit":0}},"flip":true,"scalar":false},"related":[{"correlation":{"parentField":["ownerId"],"childField":["ownerId"]},"subquery":{"table":"user","alias":"comments","where":{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":0}},"limit":0,"orderBy":[["createdAt","asc"]],"start":{"row":{"id":-2147483649,"createdAt":1},"exclusive":true}}},"scalar":true},"start":{"row":{"id":true,"createdAt":null},"exclusive":false}},"system":"permissions"}],"orderBy":[["ownerId","asc"],["id","asc"]]},"system":"test"}]},"zql":".where(({cmp, or}) => or()).related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('a', 'IS', 1.5).limit(0), {flip: true, scalar: false}))).related('comments', q => q.whereExists('comments', q => q.where('createdAt', 'NOT IN', 0).orderBy('createdAt', 'asc').limit(0).start({\"id\":-2147483649,\"createdAt\":1}), {scalar: true}).start({\"id\":true,\"createdAt\":null}, { inclusive: true })).orderBy('ownerId', 'asc').orderBy('id', 'asc'))","redacted":".where(({cmp, or}) => or()).related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('a', 'IS', ?).limit(0), {flip: true, scalar: false}))).related('comments', q => q.whereExists('comments', q => q.where('createdAt', 'NOT IN', ?).orderBy('createdAt', 'asc').limit(0).start(?), {scalar: true}).start(?, { inclusive: true })).orderBy('ownerId', 'asc').orderBy('id', 'asc'))"}, +{"ast":{"table":"comment","where":{"type":"or","conditions":[]},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"schema":"public","table":"comment","alias":"comments","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"comment","alias":"zsubq_a","where":{"type":"simple","op":"IS","left":{"type":"column","name":"a"},"right":{"type":"literal","value":1.5}},"limit":0}},"op":"NOT EXISTS","flip":true,"scalar":false},"related":[{"correlation":{"parentField":["ownerId"],"childField":["ownerId"]},"subquery":{"table":"user","alias":"comments","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"simple","op":"NOT IN","left":{"type":"column","name":"createdAt"},"right":{"type":"literal","value":0}},"start":{"row":{"id":-2147483649,"createdAt":1},"exclusive":true},"limit":0,"orderBy":[["createdAt","asc"]]}},"op":"EXISTS","scalar":true},"start":{"row":{"id":true,"createdAt":null},"exclusive":false}},"system":"permissions"}],"orderBy":[["ownerId","asc"],["id","asc"]]},"system":"test"}]},"zql":".where(({cmp, or}) => or()).related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('a', 'IS', 1.5).limit(0), {flip: true, scalar: false}))).related('comments', q => q.whereExists('comments', q => q.where('createdAt', 'NOT IN', 0).orderBy('createdAt', 'asc').limit(0).start({\"id\":-2147483649,\"createdAt\":1}), {scalar: true}).start({\"id\":true,\"createdAt\":null}, { inclusive: true })).orderBy('ownerId', 'asc').orderBy('id', 'asc'))","redacted":".where(({cmp, or}) => or()).related('comments', q => q.where(({exists, not}) => not(exists('a', q => q.where('a', 'IS', ?).limit(0), {flip: true, scalar: false}))).related('comments', q => q.whereExists('comments', q => q.where('createdAt', 'NOT IN', ?).orderBy('createdAt', 'asc').limit(0).start(?), {scalar: true}).start(?, { inclusive: true })).orderBy('ownerId', 'asc').orderBy('id', 'asc'))"}, +{"ast":{"table":"user","where":{"type":"simple","op":">=","left":{"type":"literal","value":"a"},"right":{"type":"literal","value":"é"}},"limit":1.5},"zql":".where('a', '>=', 'é').limit(1.5)","redacted":".where(?, '>=', ?).limit(1.5)"}, +{"ast":{"table":"comment","start":{"row":{"id":"😀","createdAt":1},"exclusive":false}},"zql":".start({\"id\":\"😀\",\"createdAt\":1}, { inclusive: true })","redacted":".start(?, { inclusive: true })"}, +{"ast":{"table":"issue","where":{"type":"or","conditions":[]},"orderBy":[["title","desc"]]},"zql":".where(({cmp, or}) => or()).orderBy('title', 'desc')","redacted":".where(({cmp, or}) => or()).orderBy('title', 'desc')"}, +{"ast":{"table":"label","where":{"type":"and","conditions":[]}},"zql":"","redacted":""}, +{"ast":{"table":"label","where":{"type":"and","conditions":[{"type":"and","conditions":[{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["title"],"childField":["createdAt"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":0}}},"system":"client"}},{"type":"and","conditions":[]},{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"table":"label","alias":"owner","schema":"public","where":{"type":"simple","op":">=","left":{"type":"literal","value":null},"right":{"type":"literal","value":-2147483649}},"limit":1,"orderBy":[["id","asc"]]}},"scalar":true}]}]},"orderBy":[["a","desc"],["id","asc"]]},"zql":".whereExists('owner', q => q.where('title', 0)).whereExists('owner', q => q.where(null, '>=', -2147483649).orderBy('id', 'asc').limit(1), {scalar: true}).orderBy('a', 'desc').orderBy('id', 'asc')","redacted":".whereExists('owner', q => q.where('title', ?)).whereExists('owner', q => q.where(?, '>=', ?).orderBy('id', 'asc').limit(1), {scalar: true}).orderBy('a', 'desc').orderBy('id', 'asc')"}, +{"ast":{"table":"label","where":{"type":"and","conditions":[{"type":"correlatedSubquery","related":{"correlation":{"parentField":["title"],"childField":["createdAt"]},"subquery":{"table":"comment","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":0}}},"system":"client"},"op":"EXISTS"},{"type":"correlatedSubquery","related":{"correlation":{"parentField":["createdAt"],"childField":["createdAt"]},"subquery":{"schema":"public","table":"label","alias":"owner","where":{"type":"simple","op":">=","left":{"type":"literal","value":null},"right":{"type":"literal","value":-2147483649}},"limit":1,"orderBy":[["id","asc"]]}},"op":"EXISTS","scalar":true}]},"orderBy":[["a","desc"],["id","asc"]]},"zql":".whereExists('owner', q => q.where('title', 0)).whereExists('owner', q => q.where(null, '>=', -2147483649).orderBy('id', 'asc').limit(1), {scalar: true}).orderBy('a', 'desc').orderBy('id', 'asc')","redacted":".whereExists('owner', q => q.where('title', ?)).whereExists('owner', q => q.where(?, '>=', ?).orderBy('id', 'asc').limit(1), {scalar: true}).orderBy('a', 'desc').orderBy('id', 'asc')"}, +{"ast":{"table":"label","where":{"type":"simple","op":"!=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":null}},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"title"},"right":{"type":"literal","value":null}}}},{"correlation":{"parentField":["a"],"childField":["ownerId"]},"subquery":{"table":"label","alias":"owner","where":{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["ownerId"],"childField":["title"]},"subquery":{"table":"comment","alias":"zsubq_b"},"hidden":true},"scalar":true}}}],"orderBy":[["a","desc"]]},"zql":".where('title', '!=', null).related('owner', q => q.where('title', 'NOT LIKE', null)).related('owner', q => q.where(({exists, not}) => not(exists('b', {scalar: true})))).orderBy('a', 'desc')","redacted":".where('title', '!=', ?).related('owner', q => q.where('title', 'NOT LIKE', ?)).related('owner', q => q.where(({exists, not}) => not(exists('b', {scalar: true})))).orderBy('a', 'desc')"}, +{"ast":{"table":"label","where":{"type":"simple","op":"!=","left":{"type":"column","name":"title"},"right":{"type":"literal","value":null}},"related":[{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"issue","alias":"owner","where":{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"title"},"right":{"type":"literal","value":null}}}},{"correlation":{"parentField":["a"],"childField":["ownerId"]},"subquery":{"table":"label","alias":"owner","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["ownerId"],"childField":["title"]},"hidden":true,"subquery":{"table":"comment","alias":"zsubq_b"}},"op":"NOT EXISTS","scalar":true}}}],"orderBy":[["a","desc"]]},"zql":".where('title', '!=', null).related('owner', q => q.where('title', 'NOT LIKE', null)).related('owner', q => q.where(({exists, not}) => not(exists('b', {scalar: true})))).orderBy('a', 'desc')","redacted":".where('title', '!=', ?).related('owner', q => q.where('title', 'NOT LIKE', ?)).related('owner', q => q.where(({exists, not}) => not(exists('b', {scalar: true})))).orderBy('a', 'desc')"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_a","related":[{"correlation":{"parentField":["id"],"childField":["é"]},"subquery":{"table":"user","alias":"zsubq_a","where":{"type":"and","conditions":[]},"orderBy":[["title","asc"],["id","asc"]]},"hidden":true},{"correlation":{"parentField":["ownerId"],"childField":["é"]},"subquery":{"table":"issue","alias":"owner","orderBy":[["id","asc"],["id","asc"]]}},{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"label","alias":"comments","where":{"type":"or","conditions":[{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},{"type":"simple","op":"<","left":{"type":"column","name":"title"},"right":{"type":"literal","value":2147483648}},{"type":"simple","op":"IS","left":{"type":"column","name":"id"},"right":{"type":"static","anchor":"preMutationRow","field":["a","b"]}},{"type":"simple","op":">","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":-2147483649}}]}}}]}},{"correlation":{"parentField":["createdAt"],"childField":["id"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"simple","op":"<","left":{"type":"column","name":"id"},"right":{"type":"literal","value":0}}}}],"limit":4106,"orderBy":[["closed","desc"]]},"zql":".related('zsubq_a', q => q.related('owner', q => q.orderBy('id', 'asc').orderBy('id', 'asc')).related('comments', q => q.where(({cmp, or}) => or(cmp('ownerId', 'NOT LIKE', null), cmp('title', '<', 2147483648), cmp('id', 'IS', authParam(['a', 'b'])), cmp('closed', '>', -2147483649))))).related('zsubq_a', q => q.where('id', '<', 0)).orderBy('closed', 'desc').limit(4106)","redacted":".related('zsubq_a', q => q.related('owner', q => q.orderBy('id', 'asc').orderBy('id', 'asc')).related('comments', q => q.where(({cmp, or}) => or(cmp('ownerId', 'NOT LIKE', ?), cmp('title', '<', ?), cmp('id', 'IS', authParam(['a', 'b'])), cmp('closed', '>', ?))))).related('zsubq_a', q => q.where('id', '<', ?)).orderBy('closed', 'desc').limit(4106)"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["a"],"childField":["title"]},"subquery":{"table":"user","alias":"zsubq_a","related":[{"correlation":{"parentField":["ownerId"],"childField":["a"]},"subquery":{"table":"label","alias":"comments","where":{"type":"or","conditions":[{"type":"simple","op":">","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":-2147483649}},{"type":"simple","op":"IS","left":{"type":"column","name":"id"},"right":{"type":"static","anchor":"preMutationRow","field":["a","b"]}},{"type":"simple","op":"NOT LIKE","left":{"type":"column","name":"ownerId"},"right":{"type":"literal","value":null}},{"type":"simple","op":"<","left":{"type":"column","name":"title"},"right":{"type":"literal","value":2147483648}}]}}},{"correlation":{"parentField":["ownerId"],"childField":["é"]},"subquery":{"table":"issue","alias":"owner","orderBy":[["id","asc"],["id","asc"]]}},{"correlation":{"parentField":["id"],"childField":["é"]},"hidden":true,"subquery":{"table":"user","alias":"zsubq_a","where":{"type":"and","conditions":[]},"orderBy":[["title","asc"],["id","asc"]]}}]}},{"correlation":{"parentField":["createdAt"],"childField":["id"]},"subquery":{"table":"label","alias":"zsubq_a","where":{"type":"simple","op":"<","left":{"type":"column","name":"id"},"right":{"type":"literal","value":0}}}}],"limit":4106,"orderBy":[["closed","desc"]]},"zql":".related('zsubq_a', q => q.related('comments', q => q.where(({cmp, or}) => or(cmp('closed', '>', -2147483649), cmp('id', 'IS', authParam(['a', 'b'])), cmp('ownerId', 'NOT LIKE', null), cmp('title', '<', 2147483648)))).related('owner', q => q.orderBy('id', 'asc').orderBy('id', 'asc'))).related('zsubq_a', q => q.where('id', '<', 0)).orderBy('closed', 'desc').limit(4106)","redacted":".related('zsubq_a', q => q.related('comments', q => q.where(({cmp, or}) => or(cmp('closed', '>', ?), cmp('id', 'IS', authParam(['a', 'b'])), cmp('ownerId', 'NOT LIKE', ?), cmp('title', '<', ?)))).related('owner', q => q.orderBy('id', 'asc').orderBy('id', 'asc'))).related('zsubq_a', q => q.where('id', '<', ?)).orderBy('closed', 'desc').limit(4106)"}, +{"ast":{"table":"label","where":{"type":"and","conditions":[{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"subquery":{"table":"label","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"literal","value":""}}},"system":"permissions","hidden":false},"scalar":true}]},"orderBy":[["a","asc"],["id","asc"]]},"zql":".whereExists('owner', q => q.where(authParam('sub'), ''), {scalar: true}).orderBy('a', 'asc').orderBy('id', 'asc')","redacted":".whereExists('owner', q => q.where(authParam('sub'), ?), {scalar: true}).orderBy('a', 'asc').orderBy('id', 'asc')"}, +{"ast":{"table":"label","where":{"type":"correlatedSubquery","related":{"correlation":{"parentField":["id","ownerId"],"childField":["issueId","authorId"]},"hidden":false,"subquery":{"table":"label","alias":"owner","where":{"type":"simple","op":"=","left":{"type":"static","anchor":"authData","field":"sub"},"right":{"type":"literal","value":""}}},"system":"permissions"},"op":"EXISTS","scalar":true},"orderBy":[["a","asc"],["id","asc"]]},"zql":".whereExists('owner', q => q.where(authParam('sub'), ''), {scalar: true}).orderBy('a', 'asc').orderBy('id', 'asc')","redacted":".whereExists('owner', q => q.where(authParam('sub'), ?), {scalar: true}).orderBy('a', 'asc').orderBy('id', 'asc')"}, +{"ast":{"table":"label","orderBy":[["é","asc"]]},"zql":".orderBy('é', 'asc')","redacted":".orderBy('é', 'asc')"}, +{"ast":{"table":"issue","aggregate":{"fn":"count"}},"zql":"","redacted":""}, +{"ast":{"table":"issue","where":{"type":"simple","op":"=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":false}},"aggregate":{"fn":"sum","field":"createdAt"}},"zql":".where('closed', false)","redacted":".where('closed', ?)"}, +{"ast":{"table":"issue","orderBy":[["createdAt","desc"]],"limit":10,"aggregate":{"fn":"max","field":"title"}},"zql":".orderBy('createdAt', 'desc').limit(10)","redacted":".orderBy('createdAt', 'desc').limit(10)"}, +{"ast":{"table":"issue","limit":10,"orderBy":[["createdAt","desc"]],"aggregate":{"fn":"max","field":"title"}},"zql":".orderBy('createdAt', 'desc').limit(10)","redacted":".orderBy('createdAt', 'desc').limit(10)"}, +{"ast":{"table":"issue","aggregate":{"fn":"count","field":"title"}},"zql":"","redacted":""}, +{"ast":{"table":"issue","aggregate":{"fn":"min","field":"ownerId"}},"zql":"","redacted":""}, +{"ast":{"table":"user","aggregate":{"fn":"avg","field":"metadata","path":["points"]}},"zql":"","redacted":""}, +{"ast":{"table":"user","aggregate":{"fn":"min","field":"metadata","path":["a",0]}},"zql":"","redacted":""}, +{"ast":{"table":"user","aggregate":{"fn":"max","field":"metadata","path":["0"]}},"zql":"","redacted":""}, +{"ast":{"table":"user","aggregate":{"fn":"max","field":"metadata","path":[0]}},"zql":"","redacted":""}, +{"ast":{"table":"user","aggregate":{"fn":"sum","field":"metadata","path":[2147483647]}},"zql":"","redacted":""}, +{"ast":{"table":"issue","groupBy":["ownerId"]},"zql":".distinct('ownerId')","redacted":".distinct('ownerId')"}, +{"ast":{"table":"issue","groupBy":["closed","ownerId"]},"zql":".distinct('closed', 'ownerId')","redacted":".distinct('closed', 'ownerId')"}, +{"ast":{"table":"issue","groupBy":["ownerId","closed"],"orderBy":[["closed","desc"]],"aggregate":{"fn":"count"}},"zql":".groupBy('ownerId', 'closed').count().orderBy('closed', 'desc')","redacted":".groupBy('ownerId', 'closed').count().orderBy('closed', 'desc')"}, +{"ast":{"table":"issue","orderBy":[["closed","desc"]],"aggregate":{"fn":"count"},"groupBy":["ownerId","closed"]},"zql":".groupBy('ownerId', 'closed').count().orderBy('closed', 'desc')","redacted":".groupBy('ownerId', 'closed').count().orderBy('closed', 'desc')"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":false}},"groupBy":["ownerId"],"aggregate":{"fn":"avg","field":"createdAt"}},"zql":".where('closed', false).groupBy('ownerId').avg('createdAt')","redacted":".where('closed', ?).groupBy('ownerId').avg('createdAt')"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"=","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":false}},"aggregate":{"fn":"avg","field":"createdAt"},"groupBy":["ownerId"]},"zql":".where('closed', false).groupBy('ownerId').avg('createdAt')","redacted":".where('closed', ?).groupBy('ownerId').avg('createdAt')"}, +{"ast":{"table":"issue","aggregate":{"fn":"count","distinct":["ownerId"]}},"zql":".distinct('ownerId').count()","redacted":".distinct('ownerId').count()"}, +{"ast":{"table":"issue","aggregate":{"fn":"count","distinct":["ownerId","closed"]}},"zql":".distinct('ownerId', 'closed').count()","redacted":".distinct('ownerId', 'closed').count()"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments"},"aggregate":{"fn":"count"}}]},"zql":".related('comments')","redacted":".related('comments')"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments","where":{"type":"simple","op":"=","left":{"type":"column","name":"authorId"},"right":{"type":"literal","value":"u1"}}},"aggregate":{"fn":"sum","field":"createdAt"}}]},"zql":".related('comments', q => q.where('authorId', 'u1'))","redacted":".related('comments', q => q.where('authorId', ?))"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["ownerId"],"childField":["id"]},"subquery":{"table":"user","alias":"owner"}},{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments"},"aggregate":{"fn":"max","field":"text"}}]},"zql":".related('owner').related('comments')","redacted":".related('owner').related('comments')"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments"},"aggregate":{"fn":"max","field":"text"}},{"correlation":{"parentField":["ownerId"],"childField":["id"]},"subquery":{"table":"user","alias":"owner"}}]},"zql":".related('comments').related('owner')","redacted":".related('comments').related('owner')"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"issueLabel","alias":"labels","related":[{"correlation":{"parentField":["labelId"],"childField":["id"]},"subquery":{"table":"comment","alias":"labels"}}]},"aggregate":{"fn":"min","field":"issueId"}}]},"zql":".related('labels', q => q.related('labels'))","redacted":".related('labels', q => q.related('labels'))"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments","related":[{"correlation":{"parentField":["authorId"],"childField":["id"]},"subquery":{"table":"user","alias":"author"},"aggregate":{"fn":"avg","field":"metadata","path":["n"]}}]}}]},"zql":".related('comments', q => q.related('author'))","redacted":".related('comments', q => q.related('author'))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["registrar"]},"right":{"type":"literal","value":"x"}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'registrar'), 'x'))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'registrar'), ?))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"LIKE","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["altContacts",0]},"right":{"type":"literal","value":"a%"}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'altContacts', 0), 'LIKE', 'a%'))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'altContacts', 0), 'LIKE', ?))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"IN","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["n"]},"right":{"type":"literal","value":[1,2.5,0]}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'IN', [1,2.5,0]))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'IN', ?))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"NOT IN","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["n"]},"right":{"type":"literal","value":null}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'NOT IN', null))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'NOT IN', ?))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"IN","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["n"]},"right":{"type":"literal","value":[]}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'IN', []))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'IN', ?))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"IS","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["n"]},"right":{"type":"literal","value":null}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'IS', null))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'n'), 'IS', ?))"}, +{"ast":{"table":"user","where":{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["login"]},"right":{"type":"static","anchor":"authData","field":"sub"}}},"zql":".where(({cmp, json}) => cmp(json('metadata', 'login'), authParam('sub')))","redacted":".where(({cmp, json}) => cmp(json('metadata', 'login'), authParam('sub')))"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[{"type":"simple","op":"=","left":{"type":"literal","value":1},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["b"]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["a",1]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["a","1"]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["a",0]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"id"},"path":["a"]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"column","name":"name"},"right":{"type":"literal","value":"n"}}]}},"zql":".where(1, 1).where(({cmp, json}) => cmp(json('metadata', 'b'), 1)).where(({cmp, json}) => cmp(json('metadata', 'a', 1), 1)).where(({cmp, json}) => cmp(json('metadata', 'a', '1'), 1)).where(({cmp, json}) => cmp(json('metadata', 'a', 0), 1)).where(({cmp, json}) => cmp(json('id', 'a'), 1)).where('name', 'n')","redacted":".where(?, ?).where(({cmp, json}) => cmp(json('metadata', 'b'), ?)).where(({cmp, json}) => cmp(json('metadata', 'a', 1), ?)).where(({cmp, json}) => cmp(json('metadata', 'a', '1'), ?)).where(({cmp, json}) => cmp(json('metadata', 'a', 0), ?)).where(({cmp, json}) => cmp(json('id', 'a'), ?)).where('name', ?)"}, +{"ast":{"table":"user","where":{"type":"and","conditions":[{"type":"simple","op":"=","left":{"type":"column","name":"name"},"right":{"type":"literal","value":"n"}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"id"},"path":["a"]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["a",0]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["a",1]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["a","1"]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"metadata"},"path":["b"]},"right":{"type":"literal","value":1}},{"type":"simple","op":"=","left":{"type":"literal","value":1},"right":{"type":"literal","value":1}}]}},"zql":".where('name', 'n').where(({cmp, json}) => cmp(json('id', 'a'), 1)).where(({cmp, json}) => cmp(json('metadata', 'a', 0), 1)).where(({cmp, json}) => cmp(json('metadata', 'a', 1), 1)).where(({cmp, json}) => cmp(json('metadata', 'a', '1'), 1)).where(({cmp, json}) => cmp(json('metadata', 'b'), 1)).where(1, 1)","redacted":".where('name', ?).where(({cmp, json}) => cmp(json('id', 'a'), ?)).where(({cmp, json}) => cmp(json('metadata', 'a', 0), ?)).where(({cmp, json}) => cmp(json('metadata', 'a', 1), ?)).where(({cmp, json}) => cmp(json('metadata', 'a', '1'), ?)).where(({cmp, json}) => cmp(json('metadata', 'b'), ?)).where(?, ?)"}, +{"ast":{"table":"issue","where":{"type":"simple","op":"=","left":{"type":"json","value":{"type":"column","name":"title"},"path":["a"]},"right":{"type":"literal","value":"x"}}},"zql":".where(({cmp, json}) => cmp(json('title', 'a'), 'x'))","redacted":".where(({cmp, json}) => cmp(json('title', 'a'), ?))"}, +{"ast":{"table":"issue","aggregate":{"fn":"sum","field":"title","path":["a"]}},"zql":"","redacted":""}, +{"ast":{"table":"issue","aggregate":{"fn":"sum","field":"nope"}},"zql":"","redacted":""}, +{"ast":{"table":"issue","groupBy":["nope"]},"zql":".distinct('nope')","redacted":".distinct('nope')"}, +{"ast":{"table":"issue","aggregate":{"fn":"count","distinct":["nope"]}},"zql":".distinct('nope').count()","redacted":".distinct('nope').count()"}, +{"ast":{"table":"issue","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"issueLabel","alias":"labels","related":[{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"label","alias":"labels","orderBy":[["name","asc"]],"limit":3}}]},"hidden":true},{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"comments","limit":0}},{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"owner","orderBy":[]}}]},"zql":".related('labels', q => q.orderBy('name', 'asc').limit(3)).related('comments').related('owner', q => q)","redacted":".related('labels', q => q.orderBy('name', 'asc').limit(3)).related('comments').related('owner', q => q)"}, +{"ast":{"table":"issue","where":{"type":"or","conditions":[{"type":"correlatedSubquery","op":"NOT EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"comment","alias":"zsubq_comments","where":{"type":"simple","op":"LIKE","left":{"type":"column","name":"body"},"right":{"type":"literal","value":"it's \\ \"quoted\"\n"}}}}},{"type":"and","conditions":[{"type":"simple","op":"=","left":{"type":"column","name":"ownerId"},"right":{"type":"static","anchor":"authData","field":"sub"}},{"type":"simple","op":"IN","left":{"type":"column","name":"id"},"right":{"type":"literal","value":["a",1,true]}},{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"user","alias":"zsubq_owner"}},"flip":true}]}]},"start":{"row":{"id":"x","n":1.5},"exclusive":false}},"zql":".where(({and, cmp, exists, not, or}) => or(not(exists('comments', q => q.where('body', 'LIKE', 'it\\'s \\\\ \"quoted\"\\n'))), and(cmp('ownerId', authParam('sub')), cmp('id', 'IN', [\"a\",1,true]), exists('owner', {flip: true})))).start({\"id\":\"x\",\"n\":1.5}, { inclusive: true })","redacted":".where(({and, cmp, exists, not, or}) => or(not(exists('comments', q => q.where('body', 'LIKE', ?))), and(cmp('ownerId', authParam('sub')), cmp('id', 'IN', ?), exists('owner', {flip: true})))).start(?, { inclusive: true })"}, +{"ast":{"table":"issue","where":{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"issueLabel","alias":"zsubq_labels","where":{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issueId"]},"subquery":{"table":"label","alias":"zsubq_zhidden_labels","where":{"type":"simple","op":"!=","left":{"type":"column","name":"name"},"right":{"type":"literal","value":null}}}}}}},"scalar":true},"limit":10,"start":{"row":{"id":"y"},"exclusive":true}},"zql":".whereExists('labels', q => q.where('name', '!=', null), {scalar: true}).limit(10).start({\"id\":\"y\"})","redacted":".whereExists('labels', q => q.where('name', '!=', ?), {scalar: true}).limit(10).start(?)"}, +{"ast":{"table":"issue","where":{"type":"and","conditions":[{"type":"simple","op":">","left":{"type":"json","value":{"type":"column","name":"meta"},"path":["a'b",0]},"right":{"type":"static","anchor":"preMutationRow","field":["x","y"]}},{"type":"or","conditions":[{"type":"simple","op":"IS","left":{"type":"column","name":"closed"},"right":{"type":"literal","value":false}}]}]}},"zql":".where(({cmp, json}) => cmp(json('meta', 'a\\'b', 0), '>', authParam(['x', 'y']))).where('closed', 'IS', false)","redacted":".where(({cmp, json}) => cmp(json('meta', 'a\\'b', 0), '>', authParam(['x', 'y']))).where('closed', 'IS', ?)"} +]} diff --git a/packages/zero-conformance/vectors/client-harden-mutations.json b/packages/zero-conformance/vectors/client-harden-mutations.json index e00e5972e8..7f983eacd1 100644 --- a/packages/zero-conformance/vectors/client-harden-mutations.json +++ b/packages/zero-conformance/vectors/client-harden-mutations.json @@ -9,7 +9,7 @@ {"name":"harden rebase: a mutator that throws only on rebase drops its writes for the next mutation","steps":[{"op":"materialize","view":"v","query":"issues.all"},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}],"failOnRebase":true}},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[{"op":"update","table":"issue","value":{"id":"mine","title":"edited"}}]}},{"op":"mutate","mutation":"m3","mutator":"harden.ops","args":{"ops":[],"read":["issue"]}},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","gotQueriesPatch":[],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i2","title":"I2","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]},{"op":"mutate","mutation":"m4","mutator":"harden.ops","args":{"ops":[],"read":["issue"]}},{"op":"receive","message":["pokeStart",{"pokeID":"p3","baseCookie":"02"}]},{"op":"receive","message":["pokePart",{"pokeID":"p3","lastMutationIDChanges":{"$clientID":2}}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p3","cookie":"03"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p4","baseCookie":"03"}]},{"op":"receive","message":["pokePart",{"pokeID":"p4","lastMutationIDChanges":{"$clientID":4},"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"mine","title":"server","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p4","cookie":"04"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}],"failOnRebase":true}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"update","table":"issue","value":{"id":"mine","title":"edited"}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":3,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"read":["issue"]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":4,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"read":["issue"]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}},"m2":{"client":{"type":"success"},"server":{"type":"success"}},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}},"m2":{"client":{"type":"success"},"server":{"type":"success"}},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}},"m2":{"client":{"type":"success"},"server":{"type":"success"}},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"server","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}},"m2":{"client":{"type":"success"},"server":{"type":"success"}},"m3":{"client":{"type":"success","data":{"mutationID":3,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":{"type":"success"}},"m4":{"client":{"type":"success","data":{"mutationID":4,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":{"type":"success"}}}}]}, {"name":"harden restart: a pending mutation that throws on rebase, after a restart","steps":[{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}],"failOnRebase":true}},{"op":"advance","ms":2000},{"op":"restart"},{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":0},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[],"read":["issue"]}},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","gotQueriesPatch":[],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i2","title":"I2","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p3","baseCookie":"02"}]},{"op":"receive","message":["pokePart",{"pokeID":"p3","lastMutationIDChanges":{"$clientID.0":1,"$clientID":1}}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p3","cookie":"03"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}],"failOnRebase":true}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie","01"],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"}},{"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"cached","notifications":1}}},{"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"cached","notifications":0}}},{"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"cached","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}],["push",{"timestamp":1700000002000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID.0","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"mine","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}],"failOnRebase":true}]}],"pushVersion":1,"requestID":"$requestID"}],["push",{"timestamp":1700000002000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000002000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"read":["issue"]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"cached","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"cached","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"cached","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m2":{"client":{"type":"success","data":{"mutationID":1,"read":{"issue":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},"server":{"type":"success"}}}}]}, {"name":"harden rebase: pending insert, delete and update over server changes to the same rows","steps":[{"op":"materialize","view":"v","query":"issues.all"},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"b","title":"B","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"c","title":"C","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[{"op":"delete","table":"issue","value":{"id":"b"}}]}},{"op":"mutate","mutation":"m3","mutator":"harden.ops","args":{"ops":[{"op":"update","table":"issue","value":{"id":"c","title":"edited"}}]}},{"op":"mutate","mutation":"m4","mutator":"harden.ops","args":{"ops":[{"op":"upsert","table":"issue","value":{"id":"d","title":"upserted"}}]}},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"a","title":"server a","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"update","tableName":"issues","id":{"id":"b"},"merge":{"title":"server b"}},{"op":"del","tableName":"issues","id":{"id":"c"}},{"op":"put","tableName":"issues","value":{"id":"d","title":"server d","description":"","closed":true,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]},{"op":"mutate","mutation":"m5","mutator":"harden.ops","args":{"ops":[],"read":["issue"]}},{"op":"receive","message":["pokeStart",{"pokeID":"p3","baseCookie":"02"}]},{"op":"receive","message":["pokePart",{"pokeID":"p3","lastMutationIDChanges":{"$clientID":4}}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p3","cookie":"03"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"b","title":"B","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"C","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"B","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"C","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"delete","table":"issue","value":{"id":"b"}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"C","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":3,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"update","table":"issue","value":{"id":"c","title":"edited"}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":4,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"upsert","table":"issue","value":{"id":"d","title":"upserted"}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":null,"closed":null,"ownerId":null,"createdAt":null}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":null,"closed":null,"ownerId":null,"createdAt":null}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"mine","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"c","title":"edited","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":null,"closed":null,"ownerId":null,"createdAt":null}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":5,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"read":["issue"]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"},"m5":{"client":{"type":"success","data":{"mutationID":5,"read":{"issue":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"},"m5":{"client":{"type":"success","data":{"mutationID":5,"read":{"issue":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"},"m4":{"client":{"type":"success"},"server":"pending"},"m5":{"client":{"type":"success","data":{"mutationID":5,"read":{"issue":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"server b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"server d","description":"","closed":true,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}},"m2":{"client":{"type":"success"},"server":{"type":"success"}},"m3":{"client":{"type":"success"},"server":{"type":"success"}},"m4":{"client":{"type":"success"},"server":{"type":"success"}},"m5":{"client":{"type":"success","data":{"mutationID":5,"read":{"issue":[{"id":"a","title":"server a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"upserted","description":"","closed":true,"ownerId":null,"createdAt":1}]}}},"server":"pending"}}}]}, -{"name":"harden reconnect: mutations the client gave up on are pushed again and late results ignored","options":{"disconnectTimeoutMs":10000},"steps":[{"op":"materialize","view":"v","query":"issues.all"},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"socketClose","code":1006},{"op":"advance","ms":5000},{"op":"advance","ms":5000},{"op":"advance","ms":1000},{"op":"mutate","mutation":"m3","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"c","title":"c","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pushResponse",{"mutations":[{"id":{"clientID":"$clientID","id":1},"result":{"error":"app","message":"late"}},{"id":{"clientID":"$clientID","id":2},"result":{"data":"late"}}]}]},{"op":"mutate","mutation":"m4","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","lastMutationIDChanges":{"$clientID":3},"gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"a","title":"A","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"b","title":"B","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"closed":[1],"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"sent":[["push",{"timestamp":1700000016000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}],["push",{"timestamp":1700000016000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"sent":[["push",{"timestamp":1700000016000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000016000,"id":3,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"A","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"B","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":{"type":"success"}}}}]}, +{"name":"harden reconnect: mutations the client gave up on are pushed again and late results ignored","options":{"disconnectTimeoutMs":10000},"steps":[{"op":"materialize","view":"v","query":"issues.all"},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"socketClose","code":1006},{"op":"advance","ms":5000},{"op":"advance","ms":5000},{"op":"advance","ms":1000},{"op":"mutate","mutation":"m3","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"c","title":"c","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pushResponse",{"mutations":[{"id":{"clientID":"$clientID","id":1},"result":{"error":"app","message":"late"}},{"id":{"clientID":"$clientID","id":2},"result":{"data":"late"}}]}]},{"op":"mutate","mutation":"m4","mutator":"harden.ops","args":{"ops":[{"op":"insert","table":"issue","value":{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}}]}},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","lastMutationIDChanges":{"$clientID":3},"gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"a","title":"A","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"b","title":"B","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connecting"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"closed":[1],"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"state":{"name":"disconnected","reason":"Zero was unable to connect for 10 seconds and was disconnected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"sent":[["push",{"timestamp":1700000016000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}],["push",{"timestamp":1700000016000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}}}},{"sent":[["push",{"timestamp":1700000016000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000016000,"id":3,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[{"op":"insert","table":"issue","value":{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}}]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"a","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"b","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"d","title":"d","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"unknown","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"a","title":"A","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"b","title":"B","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m2":{"client":{"type":"success"},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m3":{"client":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}},"server":{"type":"error","error":{"type":"zero","message":"Zero was unable to connect for 10 seconds and was disconnected"}}},"m4":{"client":{"type":"success"},"server":{"type":"success"}}},"logs":[{"level":"warn","args":["Slow query materialization (including server/network)","1y7zr0i1xir4ek",{"table":"issue","orderBy":[["id","asc"]]},16000]}]}]}, {"name":"harden result: what a mutator returns","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[]}},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[],"return":null}},{"op":"mutate","mutation":"m3","mutator":"harden.ops","args":{"ops":[],"return":0}},{"op":"mutate","mutation":"m4","mutator":"harden.ops","args":{"ops":[],"return":false}},{"op":"mutate","mutation":"m5","mutator":"harden.ops","args":{"ops":[],"return":""}},{"op":"mutate","mutation":"m6","mutator":"harden.ops","args":{"ops":[],"return":{"1":"one","a":[1,{"b":null}],"":"empty key"}}},{"op":"mutate","mutation":"m7","mutator":"harden.ops","args":{"ops":[],"return":0}},{"op":"mutate","mutation":"m8","mutator":"harden.ops","args":{"ops":[],"return":1e+21}},{"op":"receive","message":["pushResponse",{"mutations":[{"id":{"clientID":"$clientID","id":1},"result":{}},{"id":{"clientID":"$clientID","id":2},"result":{"data":null}},{"id":{"clientID":"$clientID","id":3},"result":{"data":0}},{"id":{"clientID":"$clientID","id":4},"result":{"data":false}},{"id":{"clientID":"$clientID","id":5},"result":{"data":""}},{"id":{"clientID":"$clientID","id":6},"result":{"data":{"x":1},"extra":"ignored"}},{"id":{"clientID":"$clientID","id":7},"result":{"data":0}},{"id":{"clientID":"$clientID","id":8},"result":{"data":5e-7}}]}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":null}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":3,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":0}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"},"m3":{"client":{"type":"success","data":0},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":4,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":false}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"},"m3":{"client":{"type":"success","data":0},"server":"pending"},"m4":{"client":{"type":"success","data":false},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":5,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":""}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"},"m3":{"client":{"type":"success","data":0},"server":"pending"},"m4":{"client":{"type":"success","data":false},"server":"pending"},"m5":{"client":{"type":"success","data":""},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":6,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":{"1":"one","a":[1,{"b":null}],"":"empty key"}}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"},"m3":{"client":{"type":"success","data":0},"server":"pending"},"m4":{"client":{"type":"success","data":false},"server":"pending"},"m5":{"client":{"type":"success","data":""},"server":"pending"},"m6":{"client":{"type":"success","data":{"1":"one","a":[1,{"b":null}],"":"empty key"}},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":7,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":0}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"},"m3":{"client":{"type":"success","data":0},"server":"pending"},"m4":{"client":{"type":"success","data":false},"server":"pending"},"m5":{"client":{"type":"success","data":""},"server":"pending"},"m6":{"client":{"type":"success","data":{"1":"one","a":[1,{"b":null}],"":"empty key"}},"server":"pending"},"m7":{"client":{"type":"success","data":0},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":8,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[],"return":1e+21}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success","data":null},"server":"pending"},"m3":{"client":{"type":"success","data":0},"server":"pending"},"m4":{"client":{"type":"success","data":false},"server":"pending"},"m5":{"client":{"type":"success","data":""},"server":"pending"},"m6":{"client":{"type":"success","data":{"1":"one","a":[1,{"b":null}],"":"empty key"}},"server":"pending"},"m7":{"client":{"type":"success","data":0},"server":"pending"},"m8":{"client":{"type":"success","data":1e+21},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}},"m2":{"client":{"type":"success","data":null},"server":{"type":"success","data":null}},"m3":{"client":{"type":"success","data":0},"server":{"type":"success","data":0}},"m4":{"client":{"type":"success","data":false},"server":{"type":"success","data":false}},"m5":{"client":{"type":"success","data":""},"server":{"type":"success","data":""}},"m6":{"client":{"type":"success","data":{"1":"one","a":[1,{"b":null}],"":"empty key"}},"server":{"type":"success","data":{"x":1}}},"m7":{"client":{"type":"success","data":0},"server":{"type":"success","data":0}},"m8":{"client":{"type":"success","data":1e+21},"server":{"type":"success","data":5e-7}}}}]}, {"name":"harden result: mutation args with unusual numbers and keys are pushed as JS writes them","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"2":"two","10":"ten","ops":[],"return":1,"n":[0,1e+21,1e-7,0.1,123456789012345680000,9007199254740994],"b":"b","a":"a","
":"ls","😀":"emoji"}}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"2":"two","10":"ten","ops":[],"return":1,"n":[0,1e+21,1e-7,0.1,123456789012345680000,9007199254740994],"b":"b","a":"a","
":"ls","😀":"emoji"}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success","data":1},"server":"pending"}}}]}, {"name":"harden push: results out of order, twice, and for unknown mutations","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"mutate","mutation":"m1","mutator":"harden.ops","args":{"ops":[]}},{"op":"mutate","mutation":"m2","mutator":"harden.ops","args":{"ops":[]}},{"op":"mutate","mutation":"m3","mutator":"harden.ops","args":{"ops":[]}},{"op":"receive","message":["pushResponse",{"mutations":[{"id":{"clientID":"$clientID","id":3},"result":{"data":"three"}},{"id":{"clientID":"$clientID","id":1},"result":{"data":"one"}},{"id":{"clientID":"$clientID","id":1},"result":{"error":"app","message":"second answer for 1"}},{"id":{"clientID":"$clientID","id":99},"result":{"error":"app","message":"unknown"}}]}]},{"op":"receive","message":["pushResponse",{"mutations":[{"id":{"clientID":"$clientID","id":2},"result":{"error":"alreadyProcessed"}}]}]},{"op":"receive","message":["pushResponse",{"mutations":[{"id":{"clientID":"$clientID","id":2},"result":{"data":"two"}}]}]},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","lastMutationIDChanges":{"$clientID":3}}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":1,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":2,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000000000,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000000,"id":3,"clientID":"$clientID","name":"harden.ops","args":[{"ops":[]}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success","data":"one"}},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":{"type":"success","data":"three"}}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success","data":"one"}},"m2":{"client":{"type":"success"},"server":"pending"},"m3":{"client":{"type":"success"},"server":{"type":"success","data":"three"}}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success","data":"one"}},"m2":{"client":{"type":"success"},"server":{"type":"success","data":"two"}},"m3":{"client":{"type":"success"},"server":{"type":"success","data":"three"}}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success","data":"one"}},"m2":{"client":{"type":"success"},"server":{"type":"success","data":"two"}},"m3":{"client":{"type":"success"},"server":{"type":"success","data":"three"}}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success","data":"one"}},"m2":{"client":{"type":"success"},"server":{"type":"success","data":"two"}},"m3":{"client":{"type":"success"},"server":{"type":"success","data":"three"}}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success","data":"one"}},"m2":{"client":{"type":"success"},"server":{"type":"success","data":"two"}},"m3":{"client":{"type":"success"},"server":{"type":"success","data":"three"}}}}]}, diff --git a/packages/zero-conformance/vectors/client-inspector.json b/packages/zero-conformance/vectors/client-inspector.json new file mode 100644 index 0000000000..c38c6a09ea --- /dev/null +++ b/packages/zero-conformance/vectors/client-inspector.json @@ -0,0 +1,14 @@ +{"formatVersion":1,"kind":"client-scenarios","description":"Inspector scenarios run against the JS zero-client like vectors/client.json (see src/client/harness.ts): the inspect step, the RPCs it sends and how their answers resolve, the query metrics, and the slow materialization logs.","shared":{"startTime":1700000000000},"cases":[ +{"name":"inspector: serverVersion sends version and resolves with the answer","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"v","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"version","id":"$inspect.0","value":"0.26.1"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["inspect",{"op":"version","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"v":"pending"}},{"state":{"name":"connected"},"inspector":{"v":{"resolved":"0.26.1"}}}]}, +{"name":"inspector: a request made before the connection is sent once connected","steps":[{"op":"advance","ms":0},{"op":"inspect","call":"v","method":"serverVersion"},{"op":"advance","ms":10},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["inspect",{"op":"version","id":"$inspect.0","value":"0.26.1"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connecting"},"inspector":{"v":"pending"}},{"state":{"name":"connecting"},"inspector":{"v":"pending"}},{"sent":[["inspect",{"op":"version","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"v":"pending"}},{"state":{"name":"connected"},"inspector":{"v":{"resolved":"0.26.1"}}}]}, +{"name":"inspector: an error answer rejects; answers to other IDs are ignored","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"a","method":"serverVersion"},{"op":"inspect","call":"b","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"version","id":"nobody","value":"x"}]},{"op":"receive","message":["inspect",{"op":"error","id":"$inspect.1","value":"Unknown inspector op"}]},{"op":"receive","message":["inspect",{"op":"version","id":"$inspect.0","value":"1.0.0"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["inspect",{"op":"version","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"a":"pending"}},{"sent":[["inspect",{"op":"version","id":"$inspect.1"}]],"state":{"name":"connected"},"inspector":{"a":"pending","b":"pending"}},{"state":{"name":"connected"},"inspector":{"a":"pending","b":"pending"}},{"state":{"name":"connected"},"inspector":{"a":"pending","b":{"rejected":"Unknown inspector op"}}},{"state":{"name":"connected"},"inspector":{"a":{"resolved":"1.0.0"},"b":{"rejected":"Unknown inspector op"}}}]}, +{"name":"inspector: metrics merges the client metrics with the server digests; slow materializations warn","options":{"slowMaterializeThreshold":50,"logLevel":"debug"},"steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"all","query":"issues.all"},{"op":"advance","ms":100},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i00","title":"I00","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i01","title":"I01","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i02","title":"I02","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i03","title":"I03","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i04","title":"I04","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i05","title":"I05","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i06","title":"I06","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i07","title":"I07","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i08","title":"I08","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i09","title":"I09","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i10","title":"I10","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i11","title":"I11","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i12","title":"I12","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i13","title":"I13","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i14","title":"I14","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i15","title":"I15","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i16","title":"I16","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i17","title":"I17","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i18","title":"I18","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i19","title":"I19","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i20","title":"I20","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i21","title":"I21","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i22","title":"I22","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i23","title":"I23","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i24","title":"I24","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i25","title":"I25","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i26","title":"I26","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i27","title":"I27","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i28","title":"I28","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i29","title":"I29","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i30","title":"I30","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i31","title":"I31","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i32","title":"I32","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i33","title":"I33","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i34","title":"I34","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i35","title":"I35","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i36","title":"I36","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i37","title":"I37","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i38","title":"I38","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i39","title":"I39","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"materialize","view":"users","query":"users.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","gotQueriesPatch":[{"op":"put","hash":"1864qec0oaacid"}],"rowsPatch":[{"op":"put","tableName":"users","value":{"id":"u1","name":"A","metadata":null}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p3","baseCookie":"02"}]},{"op":"receive","message":["pokePart",{"pokeID":"p3","gotQueriesPatch":[],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i30","title":"I30","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i31","title":"I31","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i32","title":"I32","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i33","title":"I33","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i34","title":"I34","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i35","title":"I35","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i36","title":"I36","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i37","title":"I37","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i38","title":"I38","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i39","title":"I39","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i40","title":"I40","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i41","title":"I41","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i42","title":"I42","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i43","title":"I43","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i44","title":"I44","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i45","title":"I45","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i46","title":"I46","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i47","title":"I47","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i48","title":"I48","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i49","title":"I49","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i50","title":"I50","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i51","title":"I51","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i52","title":"I52","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i53","title":"I53","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i54","title":"I54","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i55","title":"I55","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i56","title":"I56","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i57","title":"I57","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i58","title":"I58","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i59","title":"I59","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i60","title":"I60","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i61","title":"I61","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i62","title":"I62","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i63","title":"I63","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i64","title":"I64","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i65","title":"I65","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i66","title":"I66","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i67","title":"I67","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i68","title":"I68","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i69","title":"I69","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p3","cookie":"03"}]},{"op":"mutate","mutation":"m1","mutator":"issue.create","args":{"id":"j1"}},{"op":"inspect","call":"metrics","method":"metrics"},{"op":"receive","message":["inspect",{"op":"metrics","id":"$inspect.0","value":{"query-materialization-server":[100,5,1,7.5,2,40,1],"query-update-server":[100,0.5,3,1.25,1]}}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"],["debugPerf","true"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}},"logs":[{"level":"warn","args":["Slow query materialization (including server/network)","1y7zr0i1xir4ek",{"table":"issue","orderBy":[["id","asc"]]},100]}]},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1864qec0oaacid","name":"users.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":2}},"logs":[{"level":"debug","args":["Materialized query (including server/network)","1864qec0oaacid",{"table":"user","orderBy":[["id","asc"]]},10]}]},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i40","title":"I40","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i41","title":"I41","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i42","title":"I42","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i43","title":"I43","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i44","title":"I44","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i45","title":"I45","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i46","title":"I46","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i47","title":"I47","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i48","title":"I48","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i49","title":"I49","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i50","title":"I50","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i51","title":"I51","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i52","title":"I52","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i53","title":"I53","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i54","title":"I54","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i55","title":"I55","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i56","title":"I56","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i57","title":"I57","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i58","title":"I58","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i59","title":"I59","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i60","title":"I60","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i61","title":"I61","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i62","title":"I62","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i63","title":"I63","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i64","title":"I64","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i65","title":"I65","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i66","title":"I66","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i67","title":"I67","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i68","title":"I68","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i69","title":"I69","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":0}}},{"sent":[["push",{"timestamp":1700000000110,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000110,"id":1,"clientID":"$clientID","name":"issue.create","args":[{"id":"j1"}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i40","title":"I40","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i41","title":"I41","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i42","title":"I42","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i43","title":"I43","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i44","title":"I44","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i45","title":"I45","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i46","title":"I46","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i47","title":"I47","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i48","title":"I48","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i49","title":"I49","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i50","title":"I50","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i51","title":"I51","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i52","title":"I52","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i53","title":"I53","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i54","title":"I54","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i55","title":"I55","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i56","title":"I56","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i57","title":"I57","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i58","title":"I58","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i59","title":"I59","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i60","title":"I60","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i61","title":"I61","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i62","title":"I62","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i63","title":"I63","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i64","title":"I64","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i65","title":"I65","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i66","title":"I66","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i67","title":"I67","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i68","title":"I68","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i69","title":"I69","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"j1","title":"","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["inspect",{"op":"metrics","id":"$inspect.0"}]],"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i40","title":"I40","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i41","title":"I41","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i42","title":"I42","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i43","title":"I43","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i44","title":"I44","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i45","title":"I45","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i46","title":"I46","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i47","title":"I47","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i48","title":"I48","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i49","title":"I49","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i50","title":"I50","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i51","title":"I51","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i52","title":"I52","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i53","title":"I53","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i54","title":"I54","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i55","title":"I55","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i56","title":"I56","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i57","title":"I57","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i58","title":"I58","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i59","title":"I59","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i60","title":"I60","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i61","title":"I61","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i62","title":"I62","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i63","title":"I63","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i64","title":"I64","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i65","title":"I65","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i66","title":"I66","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i67","title":"I67","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i68","title":"I68","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i69","title":"I69","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"j1","title":"","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"metrics":"pending"}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i40","title":"I40","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i41","title":"I41","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i42","title":"I42","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i43","title":"I43","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i44","title":"I44","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i45","title":"I45","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i46","title":"I46","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i47","title":"I47","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i48","title":"I48","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i49","title":"I49","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i50","title":"I50","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i51","title":"I51","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i52","title":"I52","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i53","title":"I53","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i54","title":"I54","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i55","title":"I55","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i56","title":"I56","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i57","title":"I57","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i58","title":"I58","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i59","title":"I59","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i60","title":"I60","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i61","title":"I61","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i62","title":"I62","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i63","title":"I63","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i64","title":"I64","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i65","title":"I65","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i66","title":"I66","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i67","title":"I67","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i68","title":"I68","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i69","title":"I69","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"j1","title":"","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"metrics":{"resolved":{"query-materialization-client":[100,0,1,0,1],"query-materialization-end-to-end":[100,10,1,100,1],"query-update-client":[100,0,32,0,32,0,32,0,32],"query-materialization-server":[100,5,1,7.5,2,40,1],"query-update-server":[100,0.5,3,1.25,1]}}}}]}, +{"name":"inspector: slowMaterializeThreshold at its default logs nothing at warn","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"all","query":"issues.all"},{"op":"advance","ms":4990},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i00","title":"I00","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"materialize","view":"users","query":"users.all"},{"op":"advance","ms":5001},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","gotQueriesPatch":[{"op":"put","hash":"1864qec0oaacid"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1864qec0oaacid","name":"users.all","args":[],"ttl":300000}]}],["ping",{}]],"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0},"users":{"data":[],"resultType":"complete","notifications":1}},"logs":[{"level":"warn","args":["Slow query materialization (including server/network)","1864qec0oaacid",{"table":"user","orderBy":[["id","asc"]]},5001]}]}]}, +{"name":"inspector: queries of the client and of its group, with the client and server metrics","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"users","query":"users.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1864qec0oaacid"}],"rowsPatch":[{"op":"put","tableName":"users","value":{"id":"u1","name":"A","metadata":null}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"destroy","view":"users"},{"op":"advance","ms":10},{"op":"inspect","call":"version","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"version","id":"$inspect.0","value":"1"}]},{"op":"materialize","view":"all","query":"issues.all"},{"op":"advance","ms":25},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i00","title":"I00","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i01","title":"I01","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i02","title":"I02","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i03","title":"I03","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i04","title":"I04","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i05","title":"I05","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i06","title":"I06","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i07","title":"I07","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i08","title":"I08","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i09","title":"I09","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i10","title":"I10","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i11","title":"I11","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i12","title":"I12","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i13","title":"I13","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i14","title":"I14","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i15","title":"I15","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i16","title":"I16","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i17","title":"I17","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i18","title":"I18","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i19","title":"I19","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i20","title":"I20","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i21","title":"I21","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i22","title":"I22","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i23","title":"I23","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i24","title":"I24","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i25","title":"I25","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i26","title":"I26","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i27","title":"I27","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i28","title":"I28","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i29","title":"I29","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i30","title":"I30","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i31","title":"I31","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i32","title":"I32","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i33","title":"I33","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i34","title":"I34","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i35","title":"I35","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i36","title":"I36","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i37","title":"I37","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i38","title":"I38","description":"","closed":false,"owner_id":null,"createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i39","title":"I39","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]},{"op":"destroy","view":"all"},{"op":"advance","ms":10},{"op":"inspect","call":"client","method":"clientQueries"},{"op":"receive","message":["inspect",{"op":"queries","id":"$inspect.1","value":[{"clientID":"$clientID","queryID":"1y7zr0i1xir4ek","ast":{"table":"issues","orderBy":[["id","asc"]]},"name":"issues.all","args":[],"got":true,"deleted":false,"ttl":300000,"inactivatedAt":null,"rowCount":40,"metrics":{"query-hydration-server-ms":12.5,"query-update-server":[100,1,2,3,1,9,1]}},{"clientID":"$clientID","queryID":"1864qec0oaacid","ast":null,"name":"users.all","args":[],"got":true,"deleted":false,"ttl":60000,"inactivatedAt":1700000000123.5,"rowCount":1},{"clientID":"other-client","queryID":"q-unknown","ast":{"table":"issues","where":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"o'k"}},"limit":3},"name":null,"args":null,"got":false,"deleted":true,"ttl":-1,"inactivatedAt":null,"rowCount":0,"metrics":{"query-hydration-server-ms":40,"query-update-server":[100]}}]}]},{"op":"inspect","call":"group","method":"clientGroupQueries"},{"op":"receive","message":["inspect",{"op":"queries","id":"$inspect.2","value":[{"clientID":"other-client","queryID":"q-unknown","ast":{"table":"issues","where":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"o'k"}},"limit":3},"name":null,"args":null,"got":false,"deleted":true,"ttl":-1,"inactivatedAt":null,"rowCount":0,"metrics":{"query-hydration-server-ms":40,"query-update-server":[100]}},{"clientID":"$clientID","queryID":"1y7zr0i1xir4ek","ast":{"table":"issues","orderBy":[["id","asc"]]},"name":"issues.all","args":[],"got":true,"deleted":false,"ttl":300000,"inactivatedAt":null,"rowCount":40,"metrics":{"query-hydration-server-ms":12.5,"query-update-server":[100,1,2,3,1,9,1]}}]}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"users":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1864qec0oaacid","name":"users.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"users":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"users":{"data":[{"id":"u1","name":"A","metadata":null}],"resultType":"complete","notifications":2}}},{"state":{"name":"connected"}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"del","hash":"1864qec0oaacid"}]}]],"state":{"name":"connected"}},{"sent":[["inspect",{"op":"version","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"version":"pending"}},{"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":1}},"inspector":{"version":{"resolved":"1"}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}},"inspector":{"version":{"resolved":"1"}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}},"inspector":{"version":{"resolved":"1"}}},{"state":{"name":"connected"},"views":{"all":{"data":[],"resultType":"unknown","notifications":0}},"inspector":{"version":{"resolved":"1"}}},{"state":{"name":"connected"},"views":{"all":{"data":[{"id":"i00","title":"I00","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i01","title":"I01","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i02","title":"I02","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i03","title":"I03","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i04","title":"I04","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i05","title":"I05","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i06","title":"I06","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i07","title":"I07","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i08","title":"I08","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i09","title":"I09","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i10","title":"I10","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i11","title":"I11","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i12","title":"I12","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i13","title":"I13","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i14","title":"I14","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i15","title":"I15","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i16","title":"I16","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i17","title":"I17","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i18","title":"I18","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i19","title":"I19","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i20","title":"I20","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i21","title":"I21","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i22","title":"I22","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i23","title":"I23","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i24","title":"I24","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i25","title":"I25","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i26","title":"I26","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i27","title":"I27","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i28","title":"I28","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i29","title":"I29","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i30","title":"I30","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i31","title":"I31","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i32","title":"I32","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i33","title":"I33","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i34","title":"I34","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i35","title":"I35","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i36","title":"I36","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i37","title":"I37","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i38","title":"I38","description":"","closed":false,"ownerId":null,"createdAt":1},{"id":"i39","title":"I39","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":2}},"inspector":{"version":{"resolved":"1"}}},{"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"del","hash":"1y7zr0i1xir4ek"}]}]],"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"}}},{"sent":[["inspect",{"op":"queries","clientID":"$clientID","id":"$inspect.1"}]],"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"},"client":"pending"}},{"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"},"client":{"resolved":[{"name":null,"args":null,"got":false,"ttl":"forever","inactivatedAt":null,"rowCount":0,"deleted":true,"id":"q-unknown","clientID":"other-client","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100,40,1],"query-update-server":[100]},"clientZQL":null,"serverZQL":"issues.where('owner_id', 'o\\'k').limit(3)","hydrateClient":null,"hydrateServer":40,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null},{"name":"issues.all","args":[],"got":true,"ttl":"5m","inactivatedAt":null,"rowCount":40,"deleted":false,"id":"1y7zr0i1xir4ek","clientID":"$clientID","metrics":{"query-materialization-client":[100,0,1],"query-materialization-end-to-end":[100,25,1],"query-update-client":[100,0,32,0,32],"query-materialization-server":[100,12.5,1],"query-update-server":[100,1,2,3,1,9,1]},"clientZQL":"issue.orderBy('id', 'asc')","serverZQL":"issues.orderBy('id', 'asc')","hydrateClient":0,"hydrateServer":12.5,"hydrateTotal":25,"updateClientP50":0,"updateClientP95":0,"updateServerP50":2.3333333333333335,"updateServerP95":9},{"name":"users.all","args":[],"got":true,"ttl":"1m","inactivatedAt":1700000000123,"rowCount":1,"deleted":false,"id":"1864qec0oaacid","clientID":"$clientID","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100],"query-update-server":[100]},"clientZQL":null,"serverZQL":null,"hydrateClient":null,"hydrateServer":null,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null}]}}},{"sent":[["inspect",{"op":"queries","id":"$inspect.2"}]],"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"},"client":{"resolved":[{"name":null,"args":null,"got":false,"ttl":"forever","inactivatedAt":null,"rowCount":0,"deleted":true,"id":"q-unknown","clientID":"other-client","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100,40,1],"query-update-server":[100]},"clientZQL":null,"serverZQL":"issues.where('owner_id', 'o\\'k').limit(3)","hydrateClient":null,"hydrateServer":40,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null},{"name":"issues.all","args":[],"got":true,"ttl":"5m","inactivatedAt":null,"rowCount":40,"deleted":false,"id":"1y7zr0i1xir4ek","clientID":"$clientID","metrics":{"query-materialization-client":[100,0,1],"query-materialization-end-to-end":[100,25,1],"query-update-client":[100,0,32,0,32],"query-materialization-server":[100,12.5,1],"query-update-server":[100,1,2,3,1,9,1]},"clientZQL":"issue.orderBy('id', 'asc')","serverZQL":"issues.orderBy('id', 'asc')","hydrateClient":0,"hydrateServer":12.5,"hydrateTotal":25,"updateClientP50":0,"updateClientP95":0,"updateServerP50":2.3333333333333335,"updateServerP95":9},{"name":"users.all","args":[],"got":true,"ttl":"1m","inactivatedAt":1700000000123,"rowCount":1,"deleted":false,"id":"1864qec0oaacid","clientID":"$clientID","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100],"query-update-server":[100]},"clientZQL":null,"serverZQL":null,"hydrateClient":null,"hydrateServer":null,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null}]},"group":"pending"}},{"state":{"name":"connected"},"inspector":{"version":{"resolved":"1"},"client":{"resolved":[{"name":null,"args":null,"got":false,"ttl":"forever","inactivatedAt":null,"rowCount":0,"deleted":true,"id":"q-unknown","clientID":"other-client","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100,40,1],"query-update-server":[100]},"clientZQL":null,"serverZQL":"issues.where('owner_id', 'o\\'k').limit(3)","hydrateClient":null,"hydrateServer":40,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null},{"name":"issues.all","args":[],"got":true,"ttl":"5m","inactivatedAt":null,"rowCount":40,"deleted":false,"id":"1y7zr0i1xir4ek","clientID":"$clientID","metrics":{"query-materialization-client":[100,0,1],"query-materialization-end-to-end":[100,25,1],"query-update-client":[100,0,32,0,32],"query-materialization-server":[100,12.5,1],"query-update-server":[100,1,2,3,1,9,1]},"clientZQL":"issue.orderBy('id', 'asc')","serverZQL":"issues.orderBy('id', 'asc')","hydrateClient":0,"hydrateServer":12.5,"hydrateTotal":25,"updateClientP50":0,"updateClientP95":0,"updateServerP50":2.3333333333333335,"updateServerP95":9},{"name":"users.all","args":[],"got":true,"ttl":"1m","inactivatedAt":1700000000123,"rowCount":1,"deleted":false,"id":"1864qec0oaacid","clientID":"$clientID","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100],"query-update-server":[100]},"clientZQL":null,"serverZQL":null,"hydrateClient":null,"hydrateServer":null,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null}]},"group":{"resolved":[{"name":null,"args":null,"got":false,"ttl":"forever","inactivatedAt":null,"rowCount":0,"deleted":true,"id":"q-unknown","clientID":"other-client","metrics":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100,40,1],"query-update-server":[100]},"clientZQL":null,"serverZQL":"issues.where('owner_id', 'o\\'k').limit(3)","hydrateClient":null,"hydrateServer":40,"hydrateTotal":null,"updateClientP50":null,"updateClientP95":null,"updateServerP50":null,"updateServerP95":null},{"name":"issues.all","args":[],"got":true,"ttl":"5m","inactivatedAt":null,"rowCount":40,"deleted":false,"id":"1y7zr0i1xir4ek","clientID":"$clientID","metrics":{"query-materialization-client":[100,0,1],"query-materialization-end-to-end":[100,25,1],"query-update-client":[100,0,32,0,32],"query-materialization-server":[100,12.5,1],"query-update-server":[100,1,2,3,1,9,1]},"clientZQL":"issue.orderBy('id', 'asc')","serverZQL":"issues.orderBy('id', 'asc')","hydrateClient":0,"hydrateServer":12.5,"hydrateTotal":25,"updateClientP50":0,"updateClientP95":0,"updateServerP50":2.3333333333333335,"updateServerP95":9}]}}}]}, +{"name":"inspector: analyzeQuery, analyzeServerAST, and analyzeNamedQuery","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"named","method":"analyzeQuery","query":"issues.byOwner","args":"u1","options":{"vendedRows":true,"joinPlans":true}},{"op":"inspect","call":"ast","method":"analyzeServerAST","ast":{"table":"issues","where":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"orderBy":[["id","asc"]]},"options":{"syncedRows":false}},{"op":"inspect","call":"byName","method":"analyzeNamedQuery","name":"issues.byOwner","queryArgs":["u2"]},{"op":"receive","message":["inspect",{"op":"analyze-query","id":"$inspect.0","value":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}}]},{"op":"receive","message":["inspect",{"op":"analyze-query","id":"$inspect.1","value":{"warnings":[],"syncedRowCount":0,"start":1,"end":2}}]},{"op":"receive","message":["inspect",{"op":"error","id":"$inspect.2","value":"No query named issues.byOwner"}]},{"op":"inspect","call":"formatted","method":"formatPlannerEvents","events":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]},{"op":"inspect","call":"formattedMore","method":"formatPlannerEvents","events":[{"type":"attempt-start","attemptNumber":2,"totalAttempts":5},{"type":"node-cost","attemptNumber":2,"nodeType":"connection","node":"comments","branchPattern":[1,0],"downstreamChildSelectivity":1.25e-7,"costEstimate":{"startupCost":2.675,"scanEst":1e+21,"cost":0.125,"returnedRows":1.005,"selectivity":0.123456785},"filters":{"type":"and","conditions":[{"type":"simple","op":"IN","left":{"type":"column","name":"id"},"right":{"type":"literal","value":["a",1]}},{"type":"or","conditions":[{"type":"simple","op":">","left":{"type":"json","value":{"type":"column","name":"m"},"path":["a",0]},"right":{"type":"static","anchor":"authData","field":["x","y"]}},{"type":"correlatedSubquery","op":"EXISTS","related":{"correlation":{"parentField":["id"],"childField":["issue_id"]},"subquery":{"table":"issues","alias":"zsubq_issue"}}}]}]}},{"type":"node-constraint","attemptNumber":2,"nodeType":"connection","node":"comments","branchPattern":[1,0],"constraint":{},"from":"x"},{"type":"node-cost","attemptNumber":2,"nodeType":"join","node":"j","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":0,"scanEst":0,"cost":0,"returnedRows":0,"selectivity":0,"limit":0}},{"type":"node-cost","nodeType":"filter","node":"f","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":0,"scanEst":0,"cost":0,"returnedRows":0,"selectivity":0}},{"type":"plan-complete","attemptNumber":2,"totalCost":1.005,"flipPattern":1,"joinStates":[]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":1},{"type":"best-plan-selected","bestAttemptNumber":2,"totalCost":0.125,"flipPattern":1,"joinStates":[]}]},{"op":"inspect","call":"formattedNone","method":"formatPlannerEvents"}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["inspect",{"op":"analyze-query","name":"issues.byOwner","args":["u1"],"options":{"vendedRows":true,"joinPlans":true},"id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"named":"pending"}},{"sent":[["inspect",{"op":"analyze-query","ast":{"table":"issues","where":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"orderBy":[["id","asc"]]},"options":{"syncedRows":false},"id":"$inspect.1"}]],"state":{"name":"connected"},"inspector":{"named":"pending","ast":"pending"}},{"sent":[["inspect",{"op":"analyze-query","name":"issues.byOwner","args":["u2"],"id":"$inspect.2"}]],"state":{"name":"connected"},"inspector":{"named":"pending","ast":"pending","byName":"pending"}},{"state":{"name":"connected"},"inspector":{"named":{"resolved":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}},"ast":"pending","byName":"pending"}},{"state":{"name":"connected"},"inspector":{"named":{"resolved":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}},"ast":{"resolved":{"warnings":[],"syncedRowCount":0,"start":1,"end":2}},"byName":"pending"}},{"state":{"name":"connected"},"inspector":{"named":{"resolved":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}},"ast":{"resolved":{"warnings":[],"syncedRowCount":0,"start":1,"end":2}},"byName":{"rejected":"No query named issues.byOwner"}}},{"state":{"name":"connected"},"inspector":{"named":{"resolved":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}},"ast":{"resolved":{"warnings":[],"syncedRowCount":0,"start":1,"end":2}},"byName":{"rejected":"No query named issues.byOwner"},"formatted":{"resolved":"[Attempt 1/2] Pattern 0 (0)\n Connections:\n issues:\n cost=100.00, startup=0.00, scan=100.00\n rows=10.00, selectivity=0.10000000, limit=3\n downstreamChildSelectivity=0.12500000\n constraints={owner_id}\n filters=owner_id = 'u1'\n ordering=id asc\n Joins:\n join(issues,comments) (semi):\n cost=3.33, startup=1.00, scan=2.00\n rows=4.00, selectivity=1.00000000, limit=none\n downstreamChildSelectivity=1.00000000\n ✓ Plan complete: total cost = 103.34\n\n[Attempt 2/2] Pattern 1 (1)\n ✗ Plan failed: unflippable join\n\n────────────────────────────────────────────────────────────\n✓ Best plan: Attempt 1 (cost=103.34)\n Join types:\n join(issues,comments): semi\n────────────────────────────────────────────────────────────"}}},{"state":{"name":"connected"},"inspector":{"named":{"resolved":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}},"ast":{"resolved":{"warnings":[],"syncedRowCount":0,"start":1,"end":2}},"byName":{"rejected":"No query named issues.byOwner"},"formatted":{"resolved":"[Attempt 1/2] Pattern 0 (0)\n Connections:\n issues:\n cost=100.00, startup=0.00, scan=100.00\n rows=10.00, selectivity=0.10000000, limit=3\n downstreamChildSelectivity=0.12500000\n constraints={owner_id}\n filters=owner_id = 'u1'\n ordering=id asc\n Joins:\n join(issues,comments) (semi):\n cost=3.33, startup=1.00, scan=2.00\n rows=4.00, selectivity=1.00000000, limit=none\n downstreamChildSelectivity=1.00000000\n ✓ Plan complete: total cost = 103.34\n\n[Attempt 2/2] Pattern 1 (1)\n ✗ Plan failed: unflippable join\n\n────────────────────────────────────────────────────────────\n✓ Best plan: Attempt 1 (cost=103.34)\n Join types:\n join(issues,comments): semi\n────────────────────────────────────────────────────────────"},"formattedMore":{"resolved":"[Attempt 3/5] Pattern 2 (010)\n Connections:\n comments:\n cost=0.13, startup=2.67, scan=1e+21\n rows=1.00, selectivity=0.12345678, limit=none\n downstreamChildSelectivity=0.00000012\n constraints={}\n filters=(id IN [\"a\",1] AND (m.a[0] > @authData.x.y OR EXISTS(issues)))\n ordering=none\n Joins:\n j:\n cost=0.00, startup=0.00, scan=0.00\n rows=0.00, selectivity=0.00000000, limit=0\n downstreamChildSelectivity=1.00000000\n ✓ Plan complete: total cost = 1.00\n\n[Attempt 2/1] Pattern 1 (1)\n\n────────────────────────────────────────────────────────────\n✓ Best plan: Attempt 3 (cost=0.13)\n────────────────────────────────────────────────────────────"}}},{"state":{"name":"connected"},"inspector":{"named":{"resolved":{"warnings":["a warning"],"syncedRows":{"issues":[{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}]},"syncedRowCount":1,"start":1000,"end":1012.5,"elapsed":12.5,"afterPermissions":"issues.where('owner_id', 'u1')","vendedRowCounts":{"issues":{"SELECT 1":3}},"sqlitePlans":{"SELECT 1":["SCAN issues"]},"readRowCount":3,"joinPlans":[{"type":"attempt-start","attemptNumber":0,"totalAttempts":2},{"type":"node-cost","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"downstreamChildSelectivity":0.125,"costEstimate":{"startupCost":0,"scanEst":100,"cost":100.005,"returnedRows":10,"selectivity":0.1,"limit":3},"filters":{"type":"simple","op":"=","left":{"type":"column","name":"owner_id"},"right":{"type":"literal","value":"u1"}},"ordering":[["id","asc"]]},{"type":"node-constraint","attemptNumber":0,"nodeType":"connection","node":"issues","branchPattern":[0],"constraint":{"owner_id":null},"from":"join"},{"type":"node-cost","attemptNumber":0,"nodeType":"join","node":"join(issues,comments)","branchPattern":[],"downstreamChildSelectivity":1,"costEstimate":{"startupCost":1,"scanEst":2,"cost":3.333,"returnedRows":4,"selectivity":1},"joinType":"semi"},{"type":"plan-complete","attemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]},{"type":"attempt-start","attemptNumber":1,"totalAttempts":2},{"type":"plan-failed","attemptNumber":1,"reason":"unflippable join"},{"type":"best-plan-selected","bestAttemptNumber":0,"totalCost":103.338,"flipPattern":0,"joinStates":[{"join":"join(issues,comments)","type":"semi"}]}]}},"ast":{"resolved":{"warnings":[],"syncedRowCount":0,"start":1,"end":2}},"byName":{"rejected":"No query named issues.byOwner"},"formatted":{"resolved":"[Attempt 1/2] Pattern 0 (0)\n Connections:\n issues:\n cost=100.00, startup=0.00, scan=100.00\n rows=10.00, selectivity=0.10000000, limit=3\n downstreamChildSelectivity=0.12500000\n constraints={owner_id}\n filters=owner_id = 'u1'\n ordering=id asc\n Joins:\n join(issues,comments) (semi):\n cost=3.33, startup=1.00, scan=2.00\n rows=4.00, selectivity=1.00000000, limit=none\n downstreamChildSelectivity=1.00000000\n ✓ Plan complete: total cost = 103.34\n\n[Attempt 2/2] Pattern 1 (1)\n ✗ Plan failed: unflippable join\n\n────────────────────────────────────────────────────────────\n✓ Best plan: Attempt 1 (cost=103.34)\n Join types:\n join(issues,comments): semi\n────────────────────────────────────────────────────────────"},"formattedMore":{"resolved":"[Attempt 3/5] Pattern 2 (010)\n Connections:\n comments:\n cost=0.13, startup=2.67, scan=1e+21\n rows=1.00, selectivity=0.12345678, limit=none\n downstreamChildSelectivity=0.00000012\n constraints={}\n filters=(id IN [\"a\",1] AND (m.a[0] > @authData.x.y OR EXISTS(issues)))\n ordering=none\n Joins:\n j:\n cost=0.00, startup=0.00, scan=0.00\n rows=0.00, selectivity=0.00000000, limit=0\n downstreamChildSelectivity=1.00000000\n ✓ Plan complete: total cost = 1.00\n\n[Attempt 2/1] Pattern 1 (1)\n\n────────────────────────────────────────────────────────────\n✓ Best plan: Attempt 3 (cost=0.13)\n────────────────────────────────────────────────────────────"},"formattedNone":{"resolved":""}}}]}, +{"name":"inspector: authenticate, then a refused request presents the accepted password again","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"auth","method":"authenticate","password":"secret"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.0","value":true}]},{"op":"inspect","call":"v","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.1","value":false}]},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.2","value":true}]},{"op":"receive","message":["inspect",{"op":"version","id":"$inspect.3","value":"2.0.0"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["inspect",{"op":"authenticate","value":"secret","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"auth":"pending"}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true}}},{"sent":[["inspect",{"op":"version","id":"$inspect.1"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":"pending"}},{"sent":[["inspect",{"op":"authenticate","value":"secret","id":"$inspect.2"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":"pending"}},{"sent":[["inspect",{"op":"version","id":"$inspect.3"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":"pending"}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"2.0.0"}}}]}, +{"name":"inspector: unauthenticated without a password fails; a refused password resolves false","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"v1","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.0","value":false}]},{"op":"inspect","call":"wrong","method":"authenticate","password":"nope"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.1","value":false}]},{"op":"inspect","call":"v2","method":"metrics"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.2","value":false}]},{"op":"inspect","call":"right","method":"authenticate","password":"pw"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.3","value":true}]},{"op":"inspect","call":"v3","method":"metrics"},{"op":"receive","message":["inspect",{"op":"metrics","id":"$inspect.4","value":{"query-materialization-server":[100,5,1,7.5,2,40,1],"query-update-server":[100,0.5,3,1.25,1]}}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["inspect",{"op":"version","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"v1":"pending"}},{"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"}}},{"sent":[["inspect",{"op":"authenticate","value":"nope","id":"$inspect.1"}]],"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":"pending"}},{"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false}}},{"sent":[["inspect",{"op":"metrics","id":"$inspect.2"}]],"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false},"v2":"pending"}},{"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false},"v2":{"rejected":"Authentication failed"}}},{"sent":[["inspect",{"op":"authenticate","value":"pw","id":"$inspect.3"}]],"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false},"v2":{"rejected":"Authentication failed"},"right":"pending"}},{"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false},"v2":{"rejected":"Authentication failed"},"right":{"resolved":true}}},{"sent":[["inspect",{"op":"metrics","id":"$inspect.4"}]],"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false},"v2":{"rejected":"Authentication failed"},"right":{"resolved":true},"v3":"pending"}},{"state":{"name":"connected"},"inspector":{"v1":{"rejected":"Authentication failed"},"wrong":{"resolved":false},"v2":{"rejected":"Authentication failed"},"right":{"resolved":true},"v3":{"resolved":{"query-materialization-client":[100],"query-materialization-end-to-end":[100],"query-update-client":[100],"query-materialization-server":[100,5,1,7.5,2,40,1],"query-update-server":[100,0.5,3,1.25,1]}}}}]}, +{"name":"inspector: after a reconnect the accepted password is presented before retrying","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"auth","method":"authenticate","password":"secret"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.0","value":true}]},{"op":"socketClose","code":1006},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"v","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.1","value":false}]},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.2","value":true}]},{"op":"receive","message":["inspect",{"op":"version","id":"$inspect.3","value":"3.0.0"}]},{"op":"socketClose","code":1006},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"inspect","call":"v2","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.4","value":false}]},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.5","value":false}]},{"op":"inspect","call":"v3","method":"serverVersion"},{"op":"receive","message":["inspect",{"op":"authenticated","id":"$inspect.6","value":false}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"sent":[["inspect",{"op":"authenticate","value":"secret","id":"$inspect.0"}]],"state":{"name":"connected"},"inspector":{"auth":"pending"}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"inspector":{"auth":{"resolved":true}}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true}}},{"sent":[["inspect",{"op":"version","id":"$inspect.1"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":"pending"}},{"sent":[["inspect",{"op":"authenticate","value":"secret","id":"$inspect.2"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":"pending"}},{"sent":[["inspect",{"op":"version","id":"$inspect.3"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":"pending"}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[1],"state":{"name":"connecting"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"}}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"}}},{"sent":[["inspect",{"op":"version","id":"$inspect.4"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"},"v2":"pending"}},{"sent":[["inspect",{"op":"authenticate","value":"secret","id":"$inspect.5"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"},"v2":"pending"}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"},"v2":{"rejected":"Authentication failed"}}},{"sent":[["inspect",{"op":"version","id":"$inspect.6"}]],"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"},"v2":{"rejected":"Authentication failed"},"v3":"pending"}},{"state":{"name":"connected"},"inspector":{"auth":{"resolved":true},"v":{"resolved":"3.0.0"},"v2":{"rejected":"Authentication failed"},"v3":{"rejected":"Authentication failed"}}}]}, +{"name":"inspector: the clients, the map, and the rows of the local store","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"v","query":"issues.byOwner","args":"u1"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"0cswg7412kshtf"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":"u1","createdAt":1}},{"op":"put","tableName":"issues","value":{"id":"i2","title":"I2","description":"","closed":false,"owner_id":"u1","createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"mutate","mutation":"m1","mutator":"issue.create","args":{"id":"i3","ownerId":"u1"}},{"op":"inspect","call":"clients","method":"clients"},{"op":"inspect","call":"groupClients","method":"clientGroupClients"},{"op":"inspect","call":"rows","method":"clientRows","table":"issue"},{"op":"inspect","call":"none","method":"clientRows","table":"nope"},{"op":"inspect","call":"map","method":"clientMap"},{"op":"inspect","call":"withQueries","method":"clientsWithQueries"},{"op":"receive","message":["inspect",{"op":"queries","id":"$inspect.0","value":[{"clientID":"$clientID","queryID":"1y7zr0i1xir4ek","ast":{"table":"issues","orderBy":[["id","asc"]]},"name":"issues.all","args":[],"got":true,"deleted":false,"ttl":300000,"inactivatedAt":null,"rowCount":40,"metrics":{"query-hydration-server-ms":12.5,"query-update-server":[100,1,2,3,1,9,1]}}]}]},{"op":"inspect","call":"groupWithQueries","method":"clientGroupClientsWithQueries"},{"op":"receive","message":["inspect",{"op":"queries","id":"$inspect.1","value":[]}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"0cswg7412kshtf","name":"issues.byOwner","args":["u1"],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":2}}},{"sent":[["push",{"timestamp":1700000000010,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000010,"id":1,"clientID":"$clientID","name":"issue.create","args":[{"id":"i3","ownerId":"u1"}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]},"none":{"resolved":[]}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]},"none":{"resolved":[]},"map":{"resolved":[["e/issue/i1",{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i2",{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i3",{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],["g/0cswg7412kshtf",null]]}}},{"sent":[["inspect",{"op":"queries","clientID":"$clientID","id":"$inspect.0"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]},"none":{"resolved":[]},"map":{"resolved":[["e/issue/i1",{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i2",{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i3",{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],["g/0cswg7412kshtf",null]]},"withQueries":"pending"}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]},"none":{"resolved":[]},"map":{"resolved":[["e/issue/i1",{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i2",{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i3",{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],["g/0cswg7412kshtf",null]]},"withQueries":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]}}},{"sent":[["inspect",{"op":"queries","clientID":"$clientID","id":"$inspect.1"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]},"none":{"resolved":[]},"map":{"resolved":[["e/issue/i1",{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i2",{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i3",{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],["g/0cswg7412kshtf",null]]},"withQueries":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupWithQueries":"pending"}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],"resultType":"complete","notifications":0}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupClients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"rows":{"resolved":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1},{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}]},"none":{"resolved":[]},"map":{"resolved":[["e/issue/i1",{"id":"i1","title":"I1","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i2",{"id":"i2","title":"I2","description":"","closed":false,"ownerId":"u1","createdAt":1}],["e/issue/i3",{"id":"i3","title":"","description":"","closed":false,"ownerId":"u1","createdAt":1}],["g/0cswg7412kshtf",null]]},"withQueries":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"}]},"groupWithQueries":{"resolved":[]}}}]}, +{"name":"inspector: clients after a restart on the same storage","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"restart"},{"op":"inspect","call":"clients","method":"clients"},{"op":"inspect","call":"group","method":"clientGroupClients"}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"}},{"state":{"name":"connecting"},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"},{"id":"$clientID.0","clientGroupID":"$clientGroupID"}]}}},{"state":{"name":"connecting"},"inspector":{"clients":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"},{"id":"$clientID.0","clientGroupID":"$clientGroupID"}]},"group":{"resolved":[{"id":"$clientID","clientGroupID":"$clientGroupID"},{"id":"$clientID.0","clientGroupID":"$clientGroupID"}]}}}]} +]} diff --git a/packages/zero-conformance/vectors/harden-queries.json b/packages/zero-conformance/vectors/harden-queries.json index 15cc9ea4fd..c4f6daffa3 100644 --- a/packages/zero-conformance/vectors/harden-queries.json +++ b/packages/zero-conformance/vectors/harden-queries.json @@ -25,7 +25,7 @@ {"name":"lifecycle: a transformError after the query is complete","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p0","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p0","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p0","cookie":"00"}]},{"op":"receive","message":["transformError",[{"error":"app","id":"1y7zr0i1xir4ek","name":"issues.all","message":"late"}]]},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":"00"}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"run","run":"r","query":"issues.all","type":"complete"}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}},"runs":{"r":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}}]}, {"name":"poke: materialize between pokeStart and pokeEnd","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p0","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p0","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p0","cookie":"00"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":"00"}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"materialize","view":"w","query":"issues.all"},{"op":"destroy","view":"v"},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"advance","ms":10}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":1}}},{"state":{"name":"connected"},"views":{"w":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connected"},"views":{"w":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}}},{"state":{"name":"connected"},"views":{"w":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":0}}}]}, {"name":"poke: a got query deleted while views are complete and cached","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p0","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p0","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p0","cookie":"00"}]},{"op":"materialize","view":"w","query":"users.all"},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":"00"}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1864qec0oaacid"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"socketClose","code":1006},{"op":"materialize","view":"x","query":"users.all"},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"receive","message":["pokeStart",{"pokeID":"p2","baseCookie":"01"}]},{"op":"receive","message":["pokePart",{"pokeID":"p2","gotQueriesPatch":[{"op":"del","hash":"1864qec0oaacid"}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p2","cookie":"02"}]},{"op":"advance","ms":10}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":1}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie","01"],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000},{"op":"put","hash":"1864qec0oaacid","name":"users.all","args":[],"ttl":300000}],"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0}}},{"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"cached","notifications":1}}},{"state":{"name":"connecting"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"cached","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"cached","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"cached","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"cached","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0},"w":{"data":[],"resultType":"complete","notifications":0},"x":{"data":[],"resultType":"unknown","notifications":0}}}]}, -{"name":"run: complete pending over a dropped connection","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"run","run":"r","query":"issues.all","type":"complete"},{"op":"run","run":"c","query":"issues.all","type":"cached"},{"op":"advance","ms":10},{"op":"socketClose","code":1006},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"advance","ms":10}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"runs":{"r":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connecting"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]},"c":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"del","hash":"1y7zr0i1xir4ek"}]}]],"state":{"name":"connected"},"runs":{"r":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]},"c":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}}]}, +{"name":"run: complete pending over a dropped connection","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"run","run":"r","query":"issues.all","type":"complete"},{"op":"run","run":"c","query":"issues.all","type":"cached"},{"op":"advance","ms":10},{"op":"socketClose","code":1006},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"advance","ms":10}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"runs":{"r":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connecting"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":"pending","c":"pending"}},{"state":{"name":"connected"},"runs":{"r":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]},"c":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}},"logs":[{"level":"warn","args":["Slow query materialization (including server/network)","1y7zr0i1xir4ek",{"table":"issue","orderBy":[["id","asc"]]},5020]},{"level":"warn","args":["Slow query materialization (including server/network)","1y7zr0i1xir4ek",{"table":"issue","orderBy":[["id","asc"]]},5020]}]},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"del","hash":"1y7zr0i1xir4ek"}]}]],"state":{"name":"connected"},"runs":{"r":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]},"c":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}]}}}]}, {"name":"throttle: the batch timer fires while disconnected","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"a","query":"issues.all"},{"op":"socketClose","code":1006},{"op":"advance","ms":10},{"op":"materialize","view":"b","query":"users.all"},{"op":"advance","ms":10},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"advance","ms":10}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"a":{"data":[],"resultType":"unknown","notifications":1}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connecting"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connecting"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0},"b":{"data":[],"resultType":"unknown","notifications":1}}},{"state":{"name":"connecting"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0},"b":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connecting"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0},"b":{"data":[],"resultType":"unknown","notifications":0}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1864qec0oaacid","name":"users.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0},"b":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"a":{"data":[],"resultType":"unknown","notifications":0},"b":{"data":[],"resultType":"unknown","notifications":0}}}]}, {"name":"lifecycle: a removal deferred by a pending mutation over a reconnect","steps":[{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p0","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p0","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p0","cookie":"00"}]},{"op":"mutate","mutation":"m1","mutator":"issue.create","args":{"id":"i1"}},{"op":"destroy","view":"v"},{"op":"advance","ms":10},{"op":"socketClose","code":1006},{"op":"advance","ms":5000},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":"00"}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","lastMutationIDChanges":{"$clientID":1}}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]},{"op":"advance","ms":10}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"}},{"state":{"name":"connected"}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":1}}},{"sent":[["push",{"timestamp":1700000000010,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000010,"id":1,"clientID":"$clientID","name":"issue.create","args":[{"id":"i1"}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie","00"],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}],"activeClients":["$clientID"]}]}}],"closed":[0],"state":{"name":"connecting"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connecting"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"sent":[["push",{"timestamp":1700000005020,"clientGroupID":"$clientGroupID","mutations":[{"type":"custom","timestamp":1700000000010,"id":1,"clientID":"$clientID","name":"issue.create","args":[{"id":"i1"}]}],"pushVersion":1,"requestID":"$requestID"}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":"pending"}}},{"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"del","hash":"1y7zr0i1xir4ek"}]}]],"state":{"name":"connected"},"mutations":{"m1":{"client":{"type":"success"},"server":{"type":"success"}}}}]}, {"name":"error: a query that fails to hydrate throws from materialize and run","steps":[{"op":"preload","preload":"p","query":"issues.withFirstComment"},{"op":"advance","ms":0},{"op":"receive","message":["connected",{"wsid":"w1"}]},{"op":"materialize","view":"v","query":"issues.all"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p0","baseCookie":null}]},{"op":"receive","message":["pokePart",{"pokeID":"p0","gotQueriesPatch":[{"op":"put","hash":"1y7zr0i1xir4ek"}],"rowsPatch":[]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p0","cookie":"00"}]},{"op":"materialize","view":"w","query":"issues.withFirstComment"},{"op":"run","run":"r","query":"issues.withFirstComment"},{"op":"run","run":"c","query":"issues.withFirstComment","type":"complete"},{"op":"advance","ms":10},{"op":"receive","message":["pokeStart",{"pokeID":"p1","baseCookie":"00"}]},{"op":"receive","message":["pokePart",{"pokeID":"p1","gotQueriesPatch":[],"rowsPatch":[{"op":"put","tableName":"issues","value":{"id":"i1","title":"I1","description":"","closed":false,"owner_id":null,"createdAt":1}}]}]},{"op":"receive","message":["pokeEnd",{"pokeID":"p1","cookie":"01"}]}],"expect":[{"opened":[{"url":{"origin":"ws://zero.test","path":"/sync/v57/connect","query":[["clientID","$clientID"],["clientGroupID","$clientGroupID"],["userID","u1"],["baseCookie",""],["lmid","0"],["wsid","$wsid"],["profileID","$profileID"]]},"protocol":{"initConnectionMessage":["initConnection",{"desiredQueriesPatch":[{"op":"put","hash":"1w6spz31r53810","name":"issues.withFirstComment","args":[],"ttl":0}],"clientSchema":{"tables":{"comments":{"columns":{"authorId":{"type":"string"},"createdAt":{"type":"number"},"id":{"type":"string"},"issue_id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"issueLabel":{"columns":{"issueId":{"type":"string"},"labelId":{"type":"string"}},"primaryKey":["issueId","labelId"]},"issues":{"columns":{"closed":{"type":"boolean"},"createdAt":{"type":"number"},"description":{"type":"string"},"id":{"type":"string"},"owner_id":{"type":"string"},"title":{"type":"string"}},"primaryKey":["id"]},"label":{"columns":{"id":{"type":"string"},"name":{"type":"string"}},"primaryKey":["id"]},"revision":{"columns":{"authorId":{"type":"string"},"commentId":{"type":"string"},"id":{"type":"string"},"text":{"type":"string"}},"primaryKey":["id"]},"users":{"columns":{"id":{"type":"string"},"metadata":{"type":"json"},"name":{"type":"string"}},"primaryKey":["id"]}}},"activeClients":["$clientID"]}]}}],"state":{"name":"connecting"},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connecting"},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":1}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1w6spz31r53810","name":"issues.withFirstComment","args":[],"ttl":0},{"op":"put","hash":"1y7zr0i1xir4ek","name":"issues.all","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"unknown","notifications":0}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":1}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"threw":"Partitioned take does not allow unpartitioned fetches","state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}},"runs":{"r":{"rejected":{}}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}},"runs":{"r":{"rejected":{}},"c":{"rejected":{}}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"sent":[["changeDesiredQueries",{"desiredQueriesPatch":[{"op":"put","hash":"1w6spz31r53810","name":"issues.withFirstComment","args":[],"ttl":300000}]}]],"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}},"runs":{"r":{"rejected":{}},"c":{"rejected":{}}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}},"runs":{"r":{"rejected":{}},"c":{"rejected":{}}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[],"resultType":"complete","notifications":0}},"runs":{"r":{"rejected":{}},"c":{"rejected":{}}},"preloads":{"p":{"cached":"pending","complete":"pending"}}},{"state":{"name":"connected"},"views":{"v":{"data":[{"id":"i1","title":"I1","description":"","closed":false,"ownerId":null,"createdAt":1}],"resultType":"complete","notifications":1}},"runs":{"r":{"rejected":{}},"c":{"rejected":{}}},"preloads":{"p":{"cached":"pending","complete":"pending"}}}]}, diff --git a/packages/zero-conformance/vectors/tdigest.json b/packages/zero-conformance/vectors/tdigest.json new file mode 100644 index 0000000000..8d796ab5c5 --- /dev/null +++ b/packages/zero-conformance/vectors/tdigest.json @@ -0,0 +1,74 @@ +{"formatVersion":1,"kind":"tdigest","description":"TDigest (shared/src/tdigest.ts): each case runs `ops` on `compressions.length` digests; `expect` holds each op result (null for add, merge, and reset). NaN and the infinities are strings.","cases":[ +{"name":"empty","compressions":[100],"ops":[{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1]},{"op":"toJSON","d":0}],"expect":[0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0],[100]]}, +{"name":"one value","compressions":[100],"ops":[{"op":"add","d":0,"values":[[5,1]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[4,5,6]},{"op":"toJSON","d":0}],"expect":[null,[5,5,5,5,5,5,5,5,5,5,5,5,"NaN","NaN",5],[0,0,1],[100,5,1]]}, +{"name":"two values, sampled weight","compressions":[100],"ops":[{"op":"add","d":0,"values":[[0,32],[3,32]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[-1,0,1,1.5,3,4]},{"op":"count","d":0},{"op":"toJSON","d":0}],"expect":[null,[0,0,0,0,0,1.5,3,3,3,3,3,3,"NaN","NaN","NaN"],[0,0,0.4166666666666667,0.5,1,1],64,[100,0,32,3,32]]}, +{"name":"ignored values","compressions":[100],"ops":[{"op":"add","d":0,"values":[["NaN",1],[1,0],[1,-1],[1,"NaN"],[1,"Infinity"],[2,1],[0,1],[0,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":[null,3,[0,0,0,0,0,0,1.5,2,2,2,2,2,"NaN","NaN","NaN"],[100,0,1,0,1,2,1]]}, +{"name":"fromJSON","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,1,2,3,4,10,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0},{"op":"fromJSON","d":0,"json":[100,1]},{"op":"fromJSON","d":0,"json":[50]},{"op":"count","d":0},{"op":"toJSON","d":0},{"op":"fromJSON","d":0,"json":[1000,5,1,2,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[1,1,1,1,1.5,2.6666666666666665,6.5,9.440000000000001,10,10,10,10,"NaN","NaN","NaN"],[100,1,2,3,4,10,1],{"threw":"Invalid centroids array"},"ok",0,[50],"ok",[2,2,2,2,2,3.5,5,5,5,5,5,5,"NaN","NaN","NaN"],[1000,2,1,5,1]]}, +{"name":"merge into itself","compressions":[100],"ops":[{"op":"add","d":0,"values":[[1,1],[2,1],[3,1]]},{"op":"merge","d":0,"from":0},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":[null,null,6,[1,1,1,1,1,2,3,3,3,3,3,3,"NaN","NaN","NaN"],[100,1,1,1,1,2,1,2,1,3,1,3,1]]}, +{"name":"random 0","compressions":[100,1000],"ops":[{"op":"merge","d":0,"from":0},{"op":"merge","d":1,"from":1},{"op":"toJSON","d":1},{"op":"add","d":1,"values":[[15,7.52],[13,1],[13,6.1499999999999995],[8,1],[15,1],[3,1],[3,1],[13,1],[17,32],[15,1],[13,1],[17,1],[2,1],[9,4.609999999999999],[6,1],[11,32],[10,1],[17,32],[7,2.53],[7,1],[10,1],[12,6.33],[18,"Infinity"],[6,32],[8,1],[6,1],[17,1.23],[4,3.38],[14,5.1],[14,4.21],[12,1],[4,4.109999999999999],[16,9.12],[1,"Infinity"],[9,32],[6,-1],[10,1.05],[18,1],[17,1],[2,6.029999999999999],[12,32],[7,1],[4,1],[7,1],[17,"Infinity"],[10,1],[5,32],[3,1],[3,1],[1,0.37],[18,1],[6,1],[19,2.61],[3,5.92],[14,1],[3,1],[1,32],[1,9.01],[5,32],[14,5.46],[1,1],[17,1],[2,1],[12,1],[5,8.629999999999999],[10,1],[18,32],[7,32],[18,1],[13,"NaN"],[11,1],[1,1],[8,32],[17,1.3],[17,6.569999999999999],[19,0.81],[0,1],[12,32],[4,1],[10,1],[18,1],[12,32],[6,2.0399999999999996],[16,1],[18,1],[15,3.9699999999999998],[15,32],[13,9.17],[8,1],[14,1],[7,32],[14,1],[14,1],[9,-1],[7,1],[4,1],[3,1],[17,32],[6,32],[18,1.4],[6,"Infinity"],[1,32],[17,7.7299999999999995],[1,4.96],[7,"Infinity"],[14,1],[19,1],[2,1],[17,1],[15,1],[8,32],[16,1],[2,1],[12,1],[9,0],[12,1],[0,4],[8,4.52],[13,1],[5,32],[14,5.43],[6,1],[5,5.63],[4,3.88],[6,1],[15,32],[1,32],[9,1],[19,1],[18,7.75],[7,32],[9,1],[14,0.99],[3,1.82],[17,32],[1,32],[18,32],[1,1],[4,5.54],[7,1],[11,32],[4,1],[18,1],[15,1],[1,1],[0,1],[13,1],[3,3.0599999999999996],[3,32],[18,32],[8,1],[13,1],[18,-1],[3,1],[18,"NaN"],[16,5.14],[10,1],[1,32],[4,1],[12,1],[8,1],[17,1],[13,32],[12,1],[9,8.42],[1,"NaN"],[13,1],[9,"Infinity"],[7,4.54],[7,4.21],[10,1],[0,1],[11,1],[17,1],[16,32],[15,3.4099999999999997],[17,1],[14,1],[4,9.58],[16,1],[6,0],[10,8.37],[5,0],[13,4.2],[18,1],[13,6.6],[8,"Infinity"],[2,1],[17,32],[6,32],[4,1],[0,"NaN"],[7,8.54],[2,1],[9,1],[0,1],[9,1],[9,5.52],[13,1],[17,6.1899999999999995],[12,1],[3,32],[12,9.02],[9,1],[13,1],[18,-1],[13,32],[1,32],[15,5.6],[19,1],[12,1],[7,2.69],[8,1],[9,0],[10,1],[4,0.29000000000000004],[11,1],[5,6.51],[13,32],[8,3.57],[0,1],[18,1],[1,1],[0,32],[19,32],[4,1],[2,1],[16,8.52],[6,32],[8,1],[8,3.19],[12,32],[3,1],[16,1],[19,6.7299999999999995],[12,1],[15,1],[9,32],[9,32],[3,"NaN"],[9,1],[7,1],[10,6.79],[14,1],[5,32],[1,1],[7,1],[5,32],["NaN",1],[4,32],[4,1],[14,-1],[14,1],[18,32],[12,"NaN"],[10,"NaN"],[0,1],[18,1],[8,1],[3,32],[15,1],[7,8.49],[3,32],[9,1],[3,0],[4,"Infinity"],[8,1],[18,32],[9,32],[7,1],[5,1],[0,1],[15,32],[7,8.97],[15,32],[16,2.84],[4,1],[2,9.84],[4,32],[18,1],[10,8.19],[14,1],[12,32],[14,1],[0,32],[9,3.34],[3,1],[14,32],[18,7.64],[17,1],[9,1],[14,1],[16,32],[18,32],[13,32],[19,1],[12,32],[6,1],[0,1],[19,0.42]]},{"op":"add","d":1,"values":[[178.623,3.75],[318.261,32],[554.362,1],[67.178,1],[948.62,1],[164.903,1],[435.295,1],[698.061,4.46],[488.023,0.39],[550.228,7.04],[785.312,0.6900000000000001],[637.649,32],[28.784,32],[843.491,1],[475.967,1],[736.961,1],[920.51,6.3],[80.863,1.96],[466.049,32],[779.257,1],[343.806,4.29],[588.774,1],[936.542,0.54],[572.85,"NaN"],[721.101,1],[184.407,1],[305.998,32],[694.182,1],[260.025,32],[975.96,1],[564.264,32],[685.316,32],[965.712,1],[681.016,1],[628.995,1],[374.088,-1],[910.496,9.58],[833.777,1],[778.464,1],[233.883,32],[701.092,1],[406.753,1],[526.723,32],[183.806,0.05],[139.999,1],[235.919,32],["NaN",1],[927.533,1],[763.975,32],[89.232,1],[638.056,2.53],[84.756,0],[4.647,1],[762.206,1],[199.688,"Infinity"],[836.591,1],[653.625,32],[346.045,1],[990.194,32],[51.482,1],[915.837,2.84],[250.337,1],[962.939,32],[778.296,1],[976.547,1],[884.734,1],[426.143,"NaN"],[62.216,32],[560.194,1],[351.555,"Infinity"],[755.275,1],[711.057,1],[449.346,1],[337.08,0.83],[694.094,1],[981.798,3.8099999999999996],[227.777,1],[29.708,1],[765.735,4.7299999999999995],[933.456,1],[354.122,32],[571.74,1],[387.904,"NaN"],[647.012,1],[651.062,4.7299999999999995],[536.986,32],[802.228,1],[358.499,1],[591.541,1],[135.844,32],[308.723,32],[750.366,3.5199999999999996],[169.58,4.64],[20.309,32],[968.756,1],[53.989,1],[972.265,32],[366.953,1],[770.571,32],[920.127,1],[520.919,1],[241.968,1],[767.622,2.8299999999999996],[875.32,1],[326.402,1],[125.802,2.75],[790.905,32],[843.523,1],[414.898,32],[401.741,1],[588.333,1],[292.551,2.2899999999999996],[702.791,1],[82.357,32],[311.007,1],[894.368,9.16],[830.236,1],[644.283,32],[857.499,1],[998.084,32],[324.751,1],[560.971,32],[269.333,1],[927.357,1],[219.04,32],[743.495,3.03],[31.643,32],[99.405,1],[555.639,1],[168.775,32],[503.209,1],[281.636,"NaN"],[144.541,1],[480.969,32],[602.209,1],[191.837,2.98],[519.281,32],[370.308,1],[825.594,32],[847.568,1],[905.662,32],[314.477,1],[719.224,32],[654.366,32],[582.558,1],[930.163,32],[68.506,1],[262.106,1],[707.963,1],[157.426,8.4],[780.737,1],[284.367,1],[326.843,1],[162.762,32],[55.177,1],[242.644,2.28],[926.795,"Infinity"],[746.334,-1],[38.425,32],[959.781,1],[495.982,1],[492.18,1],[697.605,1],[497.274,0.47000000000000003],[98.827,9.64],[188.799,1],[287.524,1],[776.617,32],[838.936,0.4],[647.382,0.5700000000000001],[884.665,1],["NaN",1],[615.447,1],[196.097,1],[133.267,1],[869.152,1],[35.699,1],[511.183,1],[773.556,1],[996.05,1],[535.642,32],[425.953,-1],[955.535,4.109999999999999],[937.084,0.17],[542.182,6],[385.375,3.2899999999999996],[469.86,32],[150.929,1],[948.463,1],[803.511,32],[663.906,1],[399.627,"NaN"],[277.92,1.51],[626.713,1],[806.86,1.45],[827.737,1],[246.375,1],[681.992,3],[131.131,1],[241.063,2.32],[535.726,32],[880.507,1.9],[746.582,32],[276.715,1],[538.376,1],[296.94,32],[908.174,8.73],[999.422,"Infinity"],[229.078,9.98],[762.724,1],[878.566,1],[213.129,7.04],[21.2,1],[999.228,0],[931.836,1],[828.225,1],[846.229,7.74],[240.015,1],[159.574,8.04],[655.691,32],[535.423,1],[137.553,1],[678.185,1],[603.023,-1],[983.095,6.569999999999999],[470.011,32],[473.473,1],[279.968,32],[785.873,1],[372.779,1],[416.321,1],[310.862,1],[920.92,32],[858.026,1],[214.287,1],[796.997,1],[427.606,32],[491.829,8.61],[565.862,32],[64.311,1],[602.61,1],[822.078,1],[146.986,1],[658.309,1],[413.018,1],[316.664,32],[996.328,32],[602.367,1],[598.071,32],[840.871,1],[979.245,32],[450.318,32],[446.546,1],[35.969,1.25],[624.556,5.3999999999999995],[787.471,32],[764.442,32],[965.252,32],[264.608,1],[435.804,1],[284.41,1],[157.655,"Infinity"],[636.05,1],[945.619,32],[936.523,1],[448.988,8.68],[532.296,32],[838.318,1],[78.879,3.6999999999999997],[982.529,1],[853.245,1],[920.399,0.98],[945.742,1],[193.474,32],[968.377,32],[735.756,1],[617.95,1],[54.837,1],[781.966,0.18000000000000002],[325.516,1],[579.136,32],[638.011,1],[877.313,32],[718.444,2.07],[630.886,1],[794.048,1],[786.56,32],["NaN",32],[641.086,1],[481.582,32],["NaN",0.91],[67.44,4.7],[798.34,32],[683.779,1],[617.934,1],[548.264,1],[466.989,1],[878.353,5.1499999999999995],[464.837,1],[721.724,32],[225.316,9.73],[670.75,8.47],[288.588,0.77],[318.634,1],[653.03,1],[703.998,32],[418.219,7.97],[175.814,1],[103.135,1],[721.148,32],[77.06,4.05],[444.712,1],[276.411,8.27],[569.425,32],[118.851,4.71],[208.162,1],[128.699,1],[190.1,1.45],[585.881,8.83],[993.999,1],[478.279,2.8899999999999997],[139.046,32],[984.646,1],[151.082,1],[499.324,1],[947.66,1],[384.126,1],[703.791,1],[288.134,"Infinity"],[206.413,2.5],[505.661,32],[158.665,9.129999999999999],[751.382,1],["NaN",1],[832.473,1.56],[740.42,5.72],[643.547,0],[299.599,32],[217.197,1],[149.575,1],[893.929,7.74],[966.003,1],[247.197,"Infinity"],[229.517,1],[879.322,4.97],[163.156,1],[190.161,1],[958.716,0.5],[988.317,-1],[307.459,1],[30.857,1],[847.18,1],[353.841,1],[861.805,1.83],[235.658,1],[85.031,7.87],[894.487,1],[942.565,32],[471.707,1],[977.221,8.15],[885.828,1],[701.256,2.7399999999999998],[237.289,1],[25.031,32],[469.441,1],[386.862,1],[803.301,"NaN"],[769.021,32],[578.018,1],[823.313,8.06],[156.224,1],[938.896,2.0599999999999996],[659.186,4.56],[32.823,1],[629.274,9.209999999999999],[862.187,1],[363.202,1],[128.841,1.7],[455.367,1],[947.902,9.69],["NaN",0.9400000000000001],[472.01,1],[760.725,32],[54.028,32],[999.695,3.8699999999999997],[717.718,1],[608.532,1],[259.353,32],[637.78,6.12],[584.274,1],[646.112,9.799999999999999],[934.579,2.86],[444.782,9.379999999999999],[653.755,32],[698.55,1],[581.296,32],[971.046,1],[756.84,3.6199999999999997],[96.531,1],[520.795,0.66],[975.217,1],[506.478,8.6],[808.194,1],[169.325,0],[464.458,32],[15.787,1],[775.767,32],[555.85,"NaN"],[648.377,7.93],[563.077,1],[325.528,1],[382.265,"Infinity"],[377.694,1],[857.751,32],[628.453,1],[823.104,0.78],[895.499,1],[654.719,1],[959.193,32],[764.754,1],[66.432,1],[863.936,1],[909.307,1],[59.244,32],[114.005,32],[467.819,1],[334.453,9.12],[860.33,1],[979.256,32],[517.475,10],[803.483,1],[149.602,1],[468.323,32],[825.075,1],[810.539,8.379999999999999],[710.205,1],[931.178,32],[982.658,1],[846.785,1],[804.114,32],[420.596,1],[27.563,1],[172.581,1],[463.102,32],[418.863,4.81],[144.73,1],[220.673,32],[897.63,1],[338.726,32],[498.408,4.1],[394.972,1],[654.509,1],[765.873,1],[980.273,32],[710.417,1],[312.472,1],[718.745,1],[498.886,32],[647.286,8.66],[566.912,1],[786.502,0],[253.457,1],[582.034,1],[669.437,1],[189.761,1],[695.315,8.57],[3.08,1],[241.843,1],[586.092,5],[329.145,8.82],[961.347,1],[700.765,0.09],["NaN",32],[221.312,9.6],[752.662,8.299999999999999],[704.153,1],[172.438,1],[457.279,3.2899999999999996],[225.771,32],[323.352,1],[546.147,1],[967.482,8.91],[634.679,1],[7.719,1],[946.783,1],[252.213,32],[356.403,1],[19.696,1],[54.972,1],[19.463,1],[602.211,1],[7.976,1],[531.709,1],[281.164,2.51],[676.984,1],[856.531,9.02],[707.734,1],[626.986,1],[326.26,32],[408.574,3.21],[557.399,1],[191.663,7.52],[851.334,1],[630.279,0.38],[805.026,32],[513.425,1],[960.103,5.14],[490.727,3.32],[352.249,1],[797.402,32],[198.36,1.91],[771.472,32],[268.315,32],[804.944,1],[221.694,0],[107,1],[32.797,32],[525.305,1],[378.717,32],[102.213,6.14],[346.666,1],[431.659,32],[589.039,3.15],[197.015,32],[913.05,6.97],[987.365,1],[530.682,32],[679.149,1],[60.727,1],[231.585,1],[732.085,2.4499999999999997],[534.814,1],[274.259,32],[857.93,0],[115.293,32],[504.293,1],[933.425,32],[2.134,1.76],[9.436,1.52],[821.914,1],[269.62,32],[459.389,32],[929.783,32],[377.878,1],[382.278,1],[345.379,1],[217.928,32],[290.049,1],[832.792,32],[757.176,1],[543.143,8.6],[958.325,1],["NaN",1],[349.255,1],[430.933,1.91],[531.827,1],[201.016,1],[566.94,1.56],[152.148,1],[318.389,1],[841.792,32],[147.252,7.7299999999999995],[558.063,-1],[10.062,1],[775.873,3.96],[229.272,1],[247.506,8.1],[181.771,1],[113.795,32],[917.943,8.69],[828.168,8.39],[151.251,8.93],["NaN",0.3],[978.619,1],[462.092,3.9699999999999998],[653.949,32],[942.177,1],[799.567,1],[96.765,1],[648.898,1],[108.678,6.38],[295.685,1],[234.515,1],["NaN",2.3099999999999996],[903.562,1],[636.751,1],[481.2,9.299999999999999],[543.649,32],[476.941,1],[476.308,1],[451.797,5.38],[726.695,32],[414.328,1],[195.915,1],[602.671,1],[934.859,7.27],[131.6,5.14],[496.957,1],[873.9,7.609999999999999],[49.966,32],[755.425,9.7],[548.06,9.799999999999999],[714.298,"Infinity"],[499.434,32],[491.94,7.79],[71.03,32],[536.775,3.8699999999999997],[675.174,32],[338.077,2.9899999999999998],[210.716,1],[573.786,6.04],[511.841,2.38],[696.382,1],[462.357,0.36],[242.19,1],[875.953,1],[235.614,1.37],[382.607,1],[429.833,32],[541.509,9.14],[971.41,32],[829.209,1],[731.909,32],[460.091,1],[792.749,32],[667.747,6.14],[814.709,1],[329.266,32],[487.415,1],[335.192,32],[71.67,8.92],[787.746,1],[948.595,1],[495.607,1],[628.872,1],[809.823,1.46],[322.139,1],[755.237,32],[91.027,8.72],[372.51,1],[725.812,0.91],[21.805,0],[185.885,1],[568.955,1],[455.758,32],[440.257,1],[571.276,3.25],[328.4,1],[172.607,1],[323.757,1],[513.728,1],[80.547,32],[552.337,8.03],[15.68,1],[78.167,7.25],[438.635,1],[897.164,32],[441.856,8.78],[149.523,1],[601.244,1.78],[492.788,4.42],[870.513,6.68],[366.607,4.3999999999999995],[711.853,8.64],[535.289,1],[400.933,1],[331.525,32],[373.774,32],["NaN",6.88],[658.159,1],[262.786,1],[70.078,9.08],[42.788,1],[30.064,9.5],[354.325,32],[246.937,32],[696.786,32],[452.888,32],[67.11,6.01],[180.021,1],[354.52,6.56],[348.758,32],[735.386,1],[226.985,32],[43.106,1],[194.899,32],[821.593,1],[930.81,0.98],[161.235,0.73],[642.937,1],[976.809,32],[394.017,8.57],[901.148,9],[241.546,1.98],[474.359,1],[391.002,4.6],[249.437,1],[155.362,1],[42.16,1],[641.218,1.82],[382.378,5.64],[528.577,1],[470.543,1],[109.441,32],[77.814,1],[898.634,9.49],[810.397,32],[627.194,1],[831.883,1],[184.574,1],[49.741,32],[998.343,0.41000000000000003],[115.3,1],[895.043,1],[727.32,1],[160.629,"Infinity"],[196.15,1],[691.842,1],[400.509,1],[259.399,1],[6.382,7.069999999999999],[9.767,1],[658.493,8.57],["NaN",1],[473.774,1],[144.949,32],[618.132,1],["NaN",1],[930.899,1],[178.177,4.859999999999999],[787.814,1.91],[630.634,32],[37.328,7.97],[649.647,1],[840.048,1],[552.029,1.08],[833.253,1],[590.649,1],[716.886,1],[60.508,1],[711.223,1],[615.849,32],[568.366,1],[886.428,7.21],[735.491,1],[171.962,1],[356.81,6.91],[954.604,1],[337.64,3.42],[309.32,1],[271.039,32],[207.222,1],[67.946,32],[790.306,1],[613.107,1],[102.171,1],[730.071,1],[25.531,1],[202.399,1],[854.81,2.8299999999999996],[738.161,1],[487.767,0],[490.79,1],[659.179,0.64],[488.688,0.39],[758.374,1],[59.642,1],[480.244,32],[547.313,0.05],[94.349,1],[83.889,1],[277.379,1],[365.661,1],[474.532,1],[423.887,1],[395.998,1],[560.713,1],[698.246,32],[670.631,1],[457.319,2.63],[816.173,1],[582.148,1],[81.596,32],[552.123,1],[993.411,1],[226.74,32],[0.839,1],[52.816,32],[509.757,32],[713.131,1],[336.762,1],[564.627,1],[948.345,1],[547.859,1],[936.642,32],[336.424,7.05],[161.359,1],[212.913,1],[41.838,5.2],[106.245,5.09],[2.331,1],[597.097,1],[364.129,5.01],[635.696,1],[826.955,0.93],[1.555,32],[283.861,32],[389.422,0.97],[374.286,1],[956.755,7.779999999999999],[77.125,8.75],[489.632,1.98],[573.397,1],[523.539,32],[761.297,9.99],[617.401,-1],[943.277,8.42],[631.517,1],[213.903,1],[877.318,32],[376.747,4.3999999999999995],[928.689,0.8],[869.038,1.1300000000000001],[416.96,32],[351.996,32],[494.863,1],[411.293,1],[956.583,1],[584.381,1],[93.68,32],[712.553,1],[243.536,1],[370.844,1],[105.664,1],[275.003,1],[348.09,1],[226.69,1],[585.489,1],[35.451,1],[214.674,1],[984.572,1],[349.008,32],[656.406,32],[426.962,32],[794.998,4.029999999999999],[759.832,1],[610.152,1],[107.755,32],[523.753,"NaN"],[898.132,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1}],"expect":[null,null,[1000],null,null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],9577.929999999993,[0,0,1,7,18,329.5233142187498,659.7104067472876,879.308919782801,956.3382483409972,987.927681891428,998.2550482030236,999.695,"NaN","NaN","NaN"],[0,0.03010462594736026,0.13916420353876058,0.3416937670254601,0.6294292047066633,0.999683117963433],[1000,0,1,0,4,0,1,0,1,0,1,0,1,0,32,0,1,0,1,0,32,0.510126582278481,2.37,1,32,1,9.01,1,2,1,32,1,4.96,1,32,1,32,1,2,1,32,1,32,1,2,1.555,32,2,1,2,6.029999999999999,2,5,2,1,2,9.84,2.539252100840336,4.76,3,2,3,5.92,3,3.8200000000000003,3,3.0599999999999996,3,32,3,1,3,32,3,1,3,32,3,32,3.6431226765799254,5.38,4,6.109999999999999,4,4.88,4,6.54,4,1,4,9.58,4,2.29,4,32,4,2,4,32,4.647,1,5,32,5,32,5,8.629999999999999,5,32,5,5.63,5,6.51,5,32,5,32,5.5,2,6,32,6,4.039999999999999,6,32,6,2,6,32,6,32,6.334664188351921,8.07,7,5.529999999999999,7,32,7,32,7,1,7,32,7,5.54,7,4.21,7,8.54,7,4.6899999999999995,7,8.49,7,1,7,8.97,7.92375,4,8,32,8,1,8,32,8,7.52,8,9.76,9,4.609999999999999,9,32,9,2,9,9.42,9,7.52,9,32,9,32,9,2,9,32,9.452040363269425,9.91,10,5,10,9.37,10,6.79,10.006746463547334,9.19,11,32,11,1,11,32,11.785637727759914,9.33,12,32,12,1,12,32,12,32,12,5,12,10.02,12,32,12,1,12,32,12,32,13,9.149999999999999,13,11.17,13,1,13,32,13,5.2,13,8.6,13,32,13,32,13,32,14,10.309999999999999,14,9.46,14,11.42,14,32,14.904942965779467,10.52,15,3.9699999999999998,15,32,15,1,15,32,15,12.01,15,32,15,32,15.956023102310231,12.12,16,6.14,16,32,16,10.52,16,2.84,16,32,17,32,17,1,17,32,17,11.1,17,32,17,8.73,17,32,17,3,17,32,17.217627856365613,9.19,18,32,18,12.15,18,32,18,1,18,32,18,2,18,32,18,1,18,32,18,8.64,18,32,19,6.42,19,32,19.114187192118226,10.15,20.309,32,21.2,1,25.031,32,26.546999999999997,2,28.784,32,30.102,11.5,31.643,32,32.797,32,36.53342144026187,12.219999999999999,38.425,32,42.14775609756098,8.2,49.741,32,49.966,32,51.482,1,52.816,32,53.989,1,54.028,32,54.995333333333335,3,59.244,32,60.29233333333333,3,62.216,32,66.97447848285923,13.71,67.946,32,69.92204761904762,10.08,71.03,32,73.35307632999229,12.969999999999999,77.19566666666667,9.75,78.40758447488585,10.95,80.547,32,80.863,1.96,81.596,32,82.357,32,85.3409290780142,9.870000000000001,91.027,8.72,93.68,32,98.22157478005865,13.64,103.9595832747716,14.23,107,1,107.755,32,108.678,6.38,109.441,32,113.795,32,114.005,32,115.293,32,123.34731990131579,12.16,131.8714983713355,6.14,135.844,32,137.553,1,139.046,32,143.08999999999997,3,144.949,32,148.28513911143483,13.73,152.08763034367144,11.93,157.426,8.4,158.665,9.129999999999999,159.88080962128967,9.77,162.762,32,164.02949999999998,2,168.775,32,173.66851172413791,14.5,184.15475849056605,13.25,191.71238285714287,10.5,193.474,32,194.899,32,196.054,3,197.015,32,205.3148991354467,10.41,213.81242391304346,11.04,217.928,32,219.04,32,220.673,32,221.312,9.6,225.316,9.73,225.771,32,226.69,1,226.74,32,226.985,32,229.2095450643777,13.98,233.883,32,235.30094362017803,3.37,235.919,32,241.82412076583213,13.58,246.937,32,247.97748514851486,10.1,252.213,32,253.457,1,259.353,32,259.399,1,260.025,32,263.1666666666667,3,268.315,32,269.333,1,269.62,32,271.039,32,274.259,32,276.578651799687,12.78,279.968,32,281.164,2.51,283.861,32,289.6016811414392,8.059999999999999,296.94,32,299.599,32,305.998,32,307.459,1,308.723,32,311.62760000000003,5,316.664,32,318.261,32,322.75825,8,326.26,32,328.6551522842639,11.82,329.266,32,331.525,32,334.453,9.12,335.192,32,336.83385365853655,12.3,338.077,2.9899999999999998,338.726,32,345.1275922798552,8.29,348.758,32,349.008,32,349.255,1,351.996,32,353.045,2,354.122,32,354.325,32,355.7436973047685,14.469999999999999,365.16169951422626,14.41,372.0443333333333,3,373.774,32,376.6952432432433,7.3999999999999995,378.717,32,384.0365474820144,13.9,393.10563796753706,14.17,406.431359500446,11.21,414.898,32,416.321,1,416.96,32,418.972899864682,14.78,426.962,32,427.606,32,429.833,32,430.933,1.91,431.659,32,440.7981625544267,13.78,444.9519421965318,10.379999999999999,449.0249834710744,9.68,450.318,32,451.797,5.38,452.888,32,455.367,1,455.758,32,457.29677027027026,5.92,459.389,32,461.7344765478424,5.33,463.102,32,464.458,32,464.837,1,466.049,32,467.404,2,468.323,32,469.441,1,469.86,32,470.011,32,474.9294266873546,12.89,480.244,32,480.969,32,481.2,9.299999999999999,481.582,32,489.8276349009901,8.08,491.829,8.61,492.42635890218156,14.209999999999999,497.4554266842801,7.57,498.886,32,499.324,1,499.434,32,503.751,2,505.661,32,506.478,8.6,509.757,32,512.3638624535316,5.38,517.475,10,519.281,32,520.8696987951807,1.6600000000000001,523.539,32,525.305,1,526.723,32,528.577,1,530.682,32,531.768,2,532.296,32,535.1753333333334,3,535.642,32,535.726,32,536.775,3.8699999999999997,536.986,32,541.2000256410256,10.14,542.182,6,543.143,8.6,543.649,32,547.9084552529182,12.849999999999998,550.6490614035088,9.120000000000001,554.3801312356101,13.03,560.971,32,563.077,1,564.264,32,564.627,1,565.862,32,567.6884649122808,4.5600000000000005,569.425,32,573.2684654190399,12.29,579.136,32,581.296,32,583.4806666666667,6,585.881,8.83,588.7701026615969,13.15,598.071,32,605.7068942486086,10.780000000000001,615.849,32,624.2415223880597,13.399999999999999,629.283716713881,10.59,630.634,32,634.2631666666667,6,637.649,32,638.9417995545656,13.47,644.283,32,646.1953333333333,10.799999999999999,647.2919284940411,9.23,648.5573625377643,9.93,651.4054554973821,5.7299999999999995,653.625,32,653.755,32,653.949,32,654.366,32,654.614,2,655.691,32,656.406,32,658.4859562890277,11.21,664.503759055118,12.7,670.737434002112,9.47,675.174,32,680.636125,8,685.316,32,694.9363206046141,12.57,696.786,32,697.9774835164835,5.46,698.246,32,701.4252254758419,6.83,703.998,32,708.9645714285714,7,712.4553195876289,11.64,718.3395773955773,4.07,719.224,32,721.101,1,721.148,32,721.724,32,725.812,0.91,726.695,32,728.6955,2,731.909,32,734.9480872483222,7.449999999999999,741.4848285714286,8.75,746.582,32,750.5907787610619,4.52,752.662,8.299999999999999,755.237,32,755.4109813084111,10.7,757.5744410876133,6.619999999999999,760.725,32,761.37971155596,10.99,762.724,1,763.975,32,764.442,32,766.2054194560669,9.559999999999999,769.021,32,770.571,32,771.472,32,773.556,1,775.767,32,775.873,3.96,776.617,32,781.1322248722317,5.87,786.56,32,787.471,32,788.4339488491048,3.91,790.905,32,792.749,32,795.1719635157546,6.029999999999999,797.402,32,798.34,32,801.7593333333333,3,803.511,32,804.114,32,804.944,1,805.026,32,808.3075652173914,3.91,810.397,32,810.9835628997868,9.379999999999999,820.8742928870292,4.78,823.507481236203,9.06,825.594,32,827.3601813471503,1.9300000000000002,828.17407028754,9.39,831.1372543859649,4.5600000000000005,832.792,32,837.2550625000001,6.4,841.792,32,843.5070000000001,2,846.2926155606408,8.74,851.8944802342605,6.83,856.531,9.02,857.499,1,857.751,32,863.410438442211,7.96,870.513,6.68,874.0649245063879,8.61,875.953,1,877.313,32,877.318,32,878.3876341463414,6.1499999999999995,880.7883472378804,8.87,886.3549183922046,8.21,893.929,7.74,894.368,9.16,895.0096666666667,3,897.164,32,897.881,2,898.634,9.49,901.148,9,903.562,1,905.662,32,908.174,8.73,909.307,1,910.496,9.58,913.05,6.97,915.837,2.84,917.943,8.69,920.4506062801933,8.28,920.92,32,927.8004285714285,2.8,929.783,32,930.163,32,930.8549494949494,1.98,931.178,32,931.836,1,933.425,32,934.2880673575129,3.86,934.859,7.27,936.5296623376623,1.54,936.642,32,939.8164210526315,3.2299999999999995,942.565,32,943.277,8.42,945.619,32,946.7283333333334,3,947.902,9.69,949.7254,5,955.7400880626222,5.109999999999999,956.755,7.779999999999999,958.4553333333333,1.5,959.193,32,960.0505570032573,6.14,961.347,1,962.939,32,965.252,32,965.8575000000001,2,967.482,8.91,968.377,32,969.9010000000001,2,971.41,32,972.265,32,975.908,3,976.809,32,977.221,8.15,978.619,1,979.245,32,979.256,32,980.273,32,981.798,3.8099999999999996,982.5935,2,983.095,6.569999999999999,985.5276666666666,3,990.194,32,993.7049999999999,2,996.05,1,996.328,32,998.084,32,998.343,0.41000000000000003,999.695,3.8699999999999997]]}, +{"name":"random 1","compressions":[100],"ops":[{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[8,-1],[11,1],[9,0],[6,1],[5,1],[4,1.98],[1,3.8899999999999997],[13,1],[2,32],[8,1],[14,1],[3,1],[17,32],[1,2.5],[12,1.51],[9,32],[19,1],[9,1],[11,3.7399999999999998],[13,1],[3,1],[19,1],[0,1],[12,5.08],[16,1],[0,1],[18,6.319999999999999],[8,1],[2,32],[9,32],[1,32],[8,1],[18,-1],[17,32],[5,1],[13,1],[18,1],[8,"NaN"],[0,1],[2,1],[3,5.72],[18,32],[4,32],[13,1],[9,1],[18,32],[8,"NaN"],[13,0],[0,32],[16,2.55]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],null,409.29,[0,0,0,1,2,9,17,18,18,18.84285454545455,19,"NaN","NaN","NaN","NaN"],[0,0.14021842703217766,0.602300340416609,1,1,1],[100,0,1,0,1,0,1,0,32,1,3.8899999999999997,1,2.5,1,32,2,32,2,32,2.6666666666666665,3,3,5.72,4,1.98,4,32,6.666666666666667,6,9,32,9,1,9,32,10.651567944250871,5.74,12,1.51,12.164473684210526,6.08,13.8,5,16,2.55,17,32,17,32,18,6.319999999999999,18,1,18,32,18,32,19,1,19,1]]}, +{"name":"random 2","compressions":[1000],"ops":[{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"add","d":0,"values":[[837.594,1.2],[68.297,32],[417.446,1],[232.75,32],[477.663,32],[544.412,32],[607.016,8.1],[633.365,0.33],[76.922,1],[688.127,2.2899999999999996],[924.989,32],[452.02,1],[335.338,32],[0.094,1],[551.089,1],[761.832,32],[329.637,1],[602.809,32],[73.576,"Infinity"],[153.705,1],[659.713,1],[303.916,32],[135.173,1],[815.237,1],[445.003,1],[494.683,1],[863.981,32],[574.973,1],[289.356,32],[179.83,32],[805.151,32],[373.831,1],[970.435,1],[389.68,1],[376.969,9.69],[607.275,1],[469.077,32],[956.313,32],[775.472,32],[135.538,1],[668.908,1],[564.801,1],[472.483,1],[390.369,-1],[924.883,3.94],[83.593,9.08],[602.758,32],[423.449,1],[823.168,1],[631.822,1]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[-75837.5,1],[-941267.7,6.75],[202649.2,32],[293318,1],[634255.8,32],[-428906.5,1],[-180001.1,1],[-3179.8,1],[-872367.8,1],[663305.7,1],[350925.3,1],[11169.8,1],[505912.9,1],[918359.7,-1],[-159433.6,32],[-462720,1],[-724465.5,1],[-624040.7,32],[-137073.7,32],[130914.4,1],[544799.7,1],[-286397.7,1],[78729.8,2.51],[-847187.4,32],[43556.5,9.67],[-38330.8,1],[-556706.2,3.4299999999999997],[-150268.8,6.029999999999999],[162395.1,1.62],[549348.9,32],[-4798.9,32],[-296549.6,7.2],[-102044.9,1],[-390486.3,1],[-60115.6,32],[85801.3,1],[51418.4,1],[-148171,1],[-555517.5,3.8499999999999996],[57313.4,1],[-469627.6,2.34],[-726675.7,1],[298025.9,1],[268339.1,32],[456392.3,1],[-782109.5,1],[80996.6,1],[-382878.8,32],[-956366.9,32],[-606157.2,1],[-656147.9,1],[-121528.5,4.8],[-537621.9,6.609999999999999],[943609.2,1.82],[-427085.6,1],[669195.8,1],[250947.6,1.43],[587446.1,9.17],[941913.4,32],[853253.1,4.43],[-543088.3,5.569999999999999],[818643.7,9.75],[810004.1,7.4399999999999995],[-977093.1,1],[-261051.8,1],[-353394,1],[164893.2,3.38],[-748854.4,4.04],[123889.8,1],[-825526.2,32],[336366,1],[983700.2,5.52],[493510.4,1],[479221.9,0.29000000000000004],[-659376.8,1],[370230.3,8.69],[-222206.1,1],[-221944.6,1],[379932.7,1],[-302640.1,8.52],[16389.9,1],[-143685.4,1],[863697,32],[27038.3,1],[-751495.7,1],[62830.6,1],[876105.3,1.86],[456882.7,5.3],[371204.8,32],[180747.6,1],[554807.8,1],[91439.8,1],[286965,1],[640860.1,4.2299999999999995],[-951110.3,7.22],[-187946.8,32],[-5166.7,1],[-585577.6,1],[-255596,1],[-785978.8,1],[269068,1],[476853.3,1],[-194708.2,"NaN"],[970989.9,1],[523931.1,32],[616184.2,32],[923940,1],[-280744.2,1],[858160.2,1],[719644.3,1],[-206181.2,1.82],[-83250,1],[252591.4,6.01],[765904,1],[870527,1],[-314044.9,1],[-650438.5,32],[-194691,32],[-155371.6,1],[887462.7,1],[170132.7,32],[-542466.6,6.12],[-316810.8,1],[770601.2,32],[204572.8,1],[889463.8,32],[-349381,9.799999999999999],[-516426.9,1],[-876695.6,9.89],[-495004.1,1],[488349.1,1.54],[364306.2,1],[221622.8,0.51],[613792.6,1],[112808.5,1],[168286.4,32],[198445.2,1],[31144.4,7.63],[135153.9,32],[767667.6,1.17],[101607.8,9.549999999999999],[619473.8,6.6899999999999995],[155676.1,1],[759916.4,1],[79719.5,32],["NaN",1],[599141.1,1],[-659298.5,1],[-739263.5,8.2],[446778.2,0.27],[381244.2,1.39],[-370576.4,1.56],[44933.3,9.15],[-558894.9,1],[-357059.4,32],[-852924.4,1],[635476.9,1],[498294.8,9.32],[399748.6,1],[552961.1,32],[-131213.5,1],[-678314.3,1],[987729.8,32],[845208.1,1],[634694.2,1],[-437739.7,"Infinity"],[-782154.8,1],[701028.5,6.9399999999999995],[-273051.7,1],[-409780.3,1],[945722.8,1],[822899.6,8.83],[19173.1,32],[-425621.4,32],[528089.7,32],[-871396.2,1],[255263.4,1],[411108.3,1],[-600273.2,1],[521506.2,1],[-920336.3,9.2],[-934389.5,4.4399999999999995],[-241911.8,1],[-271794.7,32],[555683,1],[-969929.1,1],[-480704.6,1],[923955.3,9.67],[518744.9,1],[-214844.9,32],[-750304.6,1],[790073.8,2.92],[-181767.9,1],[-442734.3,32],[-553549,0.5],[775068.2,5.8999999999999995],[676757.7,1],[239089.4,1],[-48689.4,0.73],[472074.2,1],[552904.8,32],[-749458,32],[-355117,1],[-659939,1],[-606374.5,1],[238682.5,8.67],[305588.5,1],[-89167.7,1],[-637948,1],[823892.4,1],[-666931.5,7.3],[-455549.6,32],[144774.4,5.77],[644886.6,1],[-716474.5,32],[-837356,32],[-539724.2,1],[-268522.5,32],[266110,1],[856608.3,1],[570794.9,1],[-983515.9,32],[-754333.9,1],[-695137.5,1],[-595844.7,1],[907100.1,1],[102610.8,2.5999999999999996],[395935.1,8.36],[-369127.9,1],[-643505.8,1],[-818737.2,3.8],[432579.7,32],[765639.3,1],[-869585.7,1],[737545,1],[867365,1],[-417713.5,1],[-462779.2,1],[-440271.6,1],[818124,3.09],[505090.9,1],[-198618,1],[-932046.3,32],[-988659.5,1],[-170101.7,32],[-534394.2,4.64],[471304.5,4.7],[-820225.6,32],[-261996.4,1],[153575.7,2.67],[-719859,1],[350360.2,5.49],[-647554,1],[756542.5,32],[544013.7,1],[-973349.2,1],[-889344.2,1],[656508,32],[78595.6,32],[-246974.2,1],[312343.1,5.01],[608757.1,0.04],[734480,1],[-656124.4,1],[887313.6,1],[433910.2,3.6999999999999997],[-890571.5,6.91],[-501463,1],[297765.9,4],[-306978.7,1],[-560537.1,32],[149185.8,6.26],[-12299.6,0],[-538542,1],[558903.4,32],[-162306.6,9.24],[-414656.4,1],[-617084.4,6.16],[-292743.2,1],[842263.5,1],[347734.6,1],[-761041.2,9.86],[-631219.5,1],[-452978.4,1],[765186,1.22],[768729.1,1],[379128.1,1],[594718,1],[-204684.1,1],[-361474.5,"Infinity"],[-959248.2,1],[-586123.9,32],[381355.1,1],[224542.4,1],[972201.5,5],[209914.8,1],[-162322.3,32],[887858.3,32],[-975350.5,1],[-328437.8,8.41]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],null,[0.094,0.51822266,22.93704478181818,176.95308333333332,300.53876249999996,533.9990487878789,776.846972421875,924.9225627156372,943.4589029374998,965.7051570545455,970.3471611599999,970.435,"NaN","NaN","NaN"],null,[-988659.5,-987901.7542000001,-978725.0750909091,-758389.4994940979,-357010.33175000007,483.50653333333355,373690.83749263344,756742.2103703644,887622.4644632352,984871.3830490403,987729.8,987729.8,"NaN","NaN","NaN"],[-988659.5,-987901.7542000001,-978725.0750909091,-758389.4994940979,-357010.33175000007,483.50653333333355,373690.83749263344,756742.2103703644,887622.4644632352,984871.3830490403,987729.8,987729.8,"NaN","NaN","NaN"],2930.75,[-988659.5,-987901.7542000001,-978725.0750909091,-758389.4994940979,-357010.33175000007,483.50653333333355,373690.83749263344,756742.2103703644,887622.4644632352,984871.3830490403,987729.8,987729.8,"NaN","NaN","NaN"],[0.4108981634529996,0.41090166166666897,0.410933145589693,0.41907094189564414,0.5042989582227132,0.605188887804341],[1000,-988659.5,1,-983515.9,32,-977093.1,1,-975350.5,1,-973349.2,1,-969929.1,1,-959248.2,1,-956366.9,32,-951110.3,7.22,-941267.7,6.75,-934389.5,4.4399999999999995,-932046.3,32,-920336.3,9.2,-890571.5,6.91,-889344.2,1,-876695.6,9.89,-871882,2,-861255.05,2,-847187.4,32,-837356,32,-825526.2,32,-820225.6,32,-818737.2,3.8,-784066.8,2,-782109.5,1,-761041.2,9.86,-752914.8,2,-750304.6,1,-749458,32,-748854.4,4.04,-739263.5,8.2,-725570.6,2,-719859,1,-716474.5,32,-686725.9,2,-666931.5,7.3,-659538.1,3,-656136.15,2,-650438.5,32,-643002.6,3,-631219.5,1,-624040.7,32,-617084.4,6.16,-604268.2999999999,3,-595844.7,1,-586123.9,32,-585577.6,1,-560537.1,32,-558894.9,1,-556706.2,3.4299999999999997,-555517.5,3.8499999999999996,-553549,0.5,-543088.3,5.569999999999999,-542466.6,6.12,-539133.1,2,-537621.9,6.609999999999999,-534394.2,4.64,-504298,3,-472944.06706586824,3.34,-462749.6,2,-455549.6,32,-452978.4,1,-442734.3,32,-432087.89999999997,3,-425621.4,32,-414050.06666666665,3,-390486.3,1,-382878.8,32,-370010.5796875,2.56,-357059.4,32,-354255.5,2,-349381,9.799999999999999,-328437.8,8.41,-312611.4666666667,3,-302640.1,8.52,-296549.6,7.2,-283234.2,4,-271794.7,32,-268522.5,32,-256404.59999999998,4,-228687.5,3,-214844.9,32,-203809.39371727747,3.8200000000000003,-194691,32,-187946.8,32,-180884.5,2,-170101.7,32,-162322.3,32,-162306.6,9.24,-159433.6,32,-155371.6,1,-150268.8,6.029999999999999,-145928.2,2,-137073.7,32,-131213.5,1,-121528.5,4.8,-87575.025,4,-60115.6,32,-28952.66007326008,2.73,-4798.9,32,-1589.853,2,68.297,32,76.922,1,83.593,9.08,141.472,3,179.83,32,232.75,32,289.356,32,303.916,32,329.637,1,335.338,32,373.831,1,376.969,9.69,418.8945,4,452.02,1,469.077,32,472.483,1,477.663,32,494.683,1,544.412,32,563.621,3,602.758,32,602.809,32,607.016,8.1,641.276778290993,4.33,688.127,2.2899999999999996,761.832,32,775.472,32,805.151,32,826.0993125,3.2,863.981,32,924.883,3.94,924.989,32,956.313,32,9510.045,3,19173.1,32,27038.3,1,31144.4,7.63,43556.5,9.67,44933.3,9.15,57187.46666666667,3,78595.6,32,78729.8,2.51,79719.5,32,86079.23333333334,3,101607.8,9.549999999999999,105443.49444444444,3.5999999999999996,127402.1,2,135153.9,32,144774.4,5.77,149185.8,6.26,154148.0160762943,3.67,162395.1,1.62,164893.2,3.38,168286.4,32,170132.7,32,189596.40000000002,2,202649.2,32,214261.43247863246,3.51,238682.5,8.67,246067.68230452674,2.4299999999999997,252591.4,6.01,260686.7,2,268339.1,32,283117,3,297765.9,4,301807.2,2,312343.1,5.01,342050.3,2,350360.2,5.49,357615.75,2,370230.3,8.69,371204.8,32,380233.1085545723,3.3899999999999997,381355.1,1,395935.1,8.36,405428.44999999995,2,432579.7,32,433910.2,3.6999999999999997,454348.35748031497,1.27,456882.7,5.3,471304.5,4.7,480407.1710182768,3.83,493510.4,1,498294.8,9.32,509916.23333333334,3,521506.2,1,523931.1,32,528089.7,32,544406.7,2,549348.9,32,552904.8,32,552961.1,32,555245.4,2,558903.4,32,570794.9,1,587446.1,9.17,602632.2315789474,3.04,616184.2,32,619473.8,6.6899999999999995,634255.8,32,635085.55,2,640860.1,4.2299999999999995,644886.6,1,656508,32,666250.75,2,676757.7,1,701028.5,6.9399999999999995,727062.15,2,737545,1,756542.5,32,762812.3063063063,2.2199999999999998,765771.65,2,768156.7705069124,2.17,770601.2,32,775068.2,5.8999999999999995,790073.8,2.92,810004.1,7.4399999999999995,818124,3.09,818643.7,9.75,822899.6,8.83,833077.95,2,845208.1,1,853253.1,4.43,857384.25,2,863697,32,868946,2,876105.3,1.86,887388.1499999999,2,887858.3,32,889463.8,32,907100.1,1,923940,1,923955.3,9.67,941913.4,32,943609.2,1.82,945722.8,1,970989.9,1,972201.5,5,983700.2,5.52,987729.8,32]]}, +{"name":"random 3","compressions":[100,20,100],"ops":[{"op":"add","d":2,"values":[[1.155,3.86]]},{"op":"add","d":1,"values":[[16,0.52],[9,5.26],[18,1],[7,1],[10,1]]},{"op":"add","d":1,"values":[[43.012,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],9.78,[7,7,7,7.3054313099041535,8.242811501597444,9.402555910543132,14.539473684210522,31.056264000000006,43.012,43.012,43.012,43.012,"NaN","NaN","NaN"],[0,0,0.6912065439672803,1,1,1],[20,7,1,9,5.26,10,1,16,0.52,18,1,43.012,1],3.86,[1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,"NaN","NaN",1.155],[0,0,1,1,1,1],[100,1.155,3.86]]}, +{"name":"random 4","compressions":[100],"ops":[{"op":"add","d":0,"values":[[3,1],[11,1],[15,32],[10,"Infinity"],[11,0.05]]},{"op":"add","d":0,"values":[[17.735,32],[38.204,32],[42.207,0.63],[76.897,1],[15.81,4.7299999999999995],[4.162,1],[23.259,1],[60.369,"Infinity"],[15.613,32],[18.538,8.95],[18.595,32],[21.955,3.1799999999999997],[3.074,32],[2.985,-1],[6.69,0],[15.589,1],[38.86,1],[48.379,32],[76.497,1],[58.342,1],[12.301,1],[125.879,32],[0.035,32],[23,3.5399999999999996],[19.851,1],[40.932,1],[18.192,1],[59.773,1],[10.159,5.55],[11.278,1],[68.88,3.2899999999999996],[2.806,1],[43.132,1],[167.806,1],[125.621,5.99],[9.811,8.31],[22.239,1],[21.636,32],[16.48,1],[18.558,7.7299999999999995],[60.82,1],[25.932,2.67],[9.597,1],[68.153,"NaN"],[25.885,3.9],[15.883,32],[8.378,4.31],[26.675,0.85],[72.755,32],[19.867,1.77]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[null,null,[0.035,0.035,0.035,3.0452820588235294,15.45129893939394,18.553107913669066,40.38984456214739,75.03788176470589,125.78972887601999,157.09682778787882,167.806,167.806,"NaN","NaN","NaN"],471.45000000000005,[0.035,0.035,0.035,3.0452820588235294,15.45129893939394,18.553107913669066,40.38984456214739,75.03788176470589,125.78972887601999,157.09682778787882,167.806,167.806,"NaN","NaN","NaN"],[0,0.04607066273624222,0.1701743703394882,0.9192127674846612,1,1],[100,0.035,32,2.903,2,3.074,32,4.162,1,8.378,4.31,9.597,1,9.811,8.31,10.159,5.55,11.517704918032788,3.05,15,32,15.589,1,15.613,32,15.81,4.7299999999999995,15.883,32,16.48,1,17.735,32,18.192,1,18.538,8.95,18.558,7.7299999999999995,18.595,32,19.861223826714802,2.77,21.636,32,22.022942583732057,4.18,23.05704845814978,4.539999999999999,25.904100456621006,6.57,26.675,0.85,38.204,32,41.188542699724515,3.63,48.379,32,59.645,3,68.88,3.2899999999999996,72.755,32,76.697,2,125.621,5.99,125.879,32,167.806,1]]}, +{"name":"random 5","compressions":[100,100,100],"ops":[{"op":"add","d":1,"values":[[5.808,32],[31.08,1],[3.365,32],[44.204,1],[12.252,3.2699999999999996],[16.587,32],[5.442,1],[53.122,32],[5.689,32],[4.318,8.36],[11.478,1],[2.687,1],[9.386,1],[78.989,1],[15.899,6.22],[34.61,1],[16.252,1],[0.418,-1],[33.548,6.62],[11.924,1.83],[56.374,1.72],[10.959,0],[9.258,1],[3.824,1],[13.921,1],[2.524,32],[17.725,1],[24.796,9.459999999999999],[10.668,32],[44.306,0.56],[3.719,1],[14.318,32],[6.058,6.029999999999999],[14.069,1],[41.192,1],[16.218,3.73],[63.583,1],[53.421,1.37],[11.266,1],[10.611,1],[20.708,32],[1.613,1],[49.145,1],[4.145,32],[21.904,1],[12.533,1],[23.823,1],[12.875,1.69],[25.597,32],[9.25,1]]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,[0,0,0,0,0,0],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],427.86,[1.613,1.613,1.8216245212121212,3.0685701818181816,4.986876068376069,11.453435417758213,20.931791617647043,36.5937499569545,53.048967818181794,53.66259171521022,78.989,78.989,"NaN","NaN","NaN"],[0,0,0.4390405351501202,1,1,1],[100,1.613,1,2.524,32,2.687,1,3.365,32,3.7714999999999996,2,4.145,32,4.318,8.36,5.442,1,5.689,32,5.808,32,6.058,6.029999999999999,9.62625,4,10.668,32,11.635749347258486,3.83,12.475803691275168,5.959999999999999,13.995000000000001,2,14.318,32,15.899,6.22,16.22518816067653,4.73,16.587,32,17.725,1,20.708,32,22.863500000000002,2,24.796,9.459999999999999,25.597,32,31.08,1,33.548,6.62,40.679033707865166,3.56,49.145,1,53.122,32,53.421,1.37,56.374,1.72,63.583,1,78.989,1],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100]]}, +{"name":"random 6","compressions":[100,5,100],"ops":[{"op":"add","d":2,"values":[[15,1],[2,8.37],[6,1],[5,1],[6,1],[4,1],[0,7.45],[4,7.7299999999999995],[10,1],[0,1],[16,4.62],[10,1],[1,8.41],[3,2.4099999999999997],[10,1],[10,9.98],[10,1],[5,1],[9,1],[15,1],[7,1],[3,1],[12,1.4],[19,1],[17,"Infinity"],[0,32],[10,1],[11,1],[14,7.27],[2,32],[9,4.2299999999999995],[16,1],[4,1],[4,0.45],[4,8.44],[17,1.27],[2,1],[13,8.47],[17,"NaN"],["NaN",7.38],[19,1],[12,1],[19,1],[14,1],[9,32],[0,1],[8,32],[15,0],[2,7.37],[1,9.03],[14,1],[11,1],[17,6.9799999999999995],[11,5.77],[18,1],[5,32],[15,3.0599999999999996],[11,1],[16,32],[16,1],[17,32],[7,1],[16,32],[17,3.3099999999999996],[19,1],[17,1],[10,32],[2,1],[1,32],[4,1],[3,0.4],[7,2.0599999999999996],[17,0.41000000000000003],[9,1],[9,1],[7,1],[1,1],[5,32],[6,1.72],[18,1],[13,1],[3,0],[18,32],[4,1],[2,1.83],[4,4.1899999999999995],[10,32],[4,-1],[7,32],[13,32],[9,1],[12,7.779999999999999],[4,4.95],[14,1],[9,1],[10,32],[0,32],[8,1],[18,1],[16,32],[7,1],[18,32],[3,1],[16,6.42],[16,"Infinity"],[7,1],[3,0.17],[18,0.15000000000000002],[3,1],[15,32],[12,1],[17,7.63],[5,1],[17,1],[14,1],[15,1],[7,1],[11,-1],[12,1],[1,1],[3,8.78],[6,0],[3,32],[6,2.2199999999999998],[3,1],[8,1],[19,32],[11,1],[18,32],[10,1],[2,32],[8,1],[10,1],[5,1],[13,1],[15,1],[15,1],[5,1],[4,1],[11,32],[3,32],[10,1],[9,1],[15,32],[0,1],[4,32],[12,32],[3,32],[0,4.79],[5,1],[16,1],[14,1],[15,8.78],[19,32],[3,1],[6,"Infinity"],[8,1],[11,7.2299999999999995],[10,32],[19,1],[5,1.99],[9,1],[5,1],[17,1],[11,1],[3,1],[5,1.42],[19,1],[0,32],[3,1],[11,1],[16,1],[5,32],[0,1],[5,-1],[7,6.069999999999999],[12,32],[7,"NaN"],[7,1],[3,1],[11,1],[19,32],[6,7.9799999999999995],[14,1],[0,1],[13,2.59],[3,32],[5,3.13],[12,32],[19,1],[15,1],[7,1],[3,7.18],[2,6.1],[2,32],[14,1],[4,1],[14,1],[10,32],[11,32],[8,1],[0,32],[8,1],[16,5.7],[13,4.109999999999999],[7,1],[12,2.1999999999999997],[4,1],[2,1],[11,1],[12,32],[19,2.7199999999999998],[5,1],[15,1],[5,1],[15,32],[19,1],[14,1],[14,32],[19,7.14],[8,1],[5,1],[3,"NaN"],[14,1],[11,1],[0,32],[12,3.2199999999999998],[8,"NaN"],[4,1],[1,1],[16,1],[16,"NaN"],[1,"NaN"],[15,1],[19,1],[7,1.47],[12,9.93],[11,4.29],[2,32],[12,32],[9,1],[7,1],[1,2.7399999999999998],[3,1],[19,32],[2,5.25],[7,"NaN"],[3,1],[18,2.07],[18,7.029999999999999],[19,1],[19,5.34],[6,32],[2,32],[2,32],[8,0.56],[4,1],[14,1],[18,1],[15,32],[2,1],[15,1],[18,6.37],[16,32],[16,1],[14,1],[3,1.8],[13,1],[9,8.52],[1,1],[6,1],[11,1],[14,1],[9,1],[5,1],[11,1],[11,32],[15,1],[1,1],[10,32],[12,32],[13,32],[9,32],[15,32],[2,6.2299999999999995],[19,32],[7,1],[19,2.1399999999999997],[15,1],[0,32],[11,32],[4,32],[13,1],[18,5.84],[3,1],[13,1],[11,32],[2,1],[11,6],[1,32],[19,1],[12,1],[10,4.06],[1,32],[0,1],[2,1],[19,1],[7,1],[4,1],[10,32],[16,32],[13,32],[8,1],[7,1],[10,6.81],[0,1.25],[7,1],[16,1],[1,1],[18,1],[7,-1],[1,32],[16,7.529999999999999],[14,1.18],[6,1],[17,32],[17,1],["NaN",2.5999999999999996],[18,32],[10,1],[19,32],[18,32],[19,1],[12,1],[16,1],[18,32],[18,3.17],[6,1],[9,1],[11,1],[14,1],[0,32],[4,1],[19,1.26],[9,1],[1,1],[10,-1],[15,5.13],[14,1],[13,7.819999999999999],[6,5.2],[19,1],[16,1],[13,1],[7,1],[12,1],[6,1],[12,1],[0,0.95],[19,2.34],[12,5.34],[16,-1],[17,32],[8,32],[2,0],[14,32],[12,32],[0,1],[13,"NaN"],[14,1],[18,32],[19,32],[18,9.85],[4,1],[1,1],[1,1],[4,1],[15,32],[17,32],[7,1],[14,1],[13,32],[19,9.79],[0,32],[11,9.86],[0,1],[10,32],[19,1],[18,6.63],[7,32],[15,1],[7,32],[0,3.9499999999999997],[2,"NaN"],[4,1],[7,"NaN"],[7,0.45],[6,1],[3,1],[9,1],[15,1],[0,0.29000000000000004],[12,1],[18,5.81],[11,32],[6,1],[8,1],[14,"Infinity"],[14,1],[3,1],[0,32],[1,1.3],[4,4.55],[2,1],[17,1],[5,1],[4,1],[10,1],[9,3.4899999999999998],[6,1],[11,1],[0,1],[17,32],[11,3.6599999999999997],[10,1],[19,4.569999999999999],[14,8.22],[9,1],[13,32],[1,0.17],[7,"NaN"],[4,6.7299999999999995],[11,32],[0,1],[1,1],[12,2.78],[14,32],[12,1],[19,1],[6,32],[18,-1],[14,6.6499999999999995],[2,32],[12,2.82],[3,1],[3,3.03],[13,1],[10,1],[2,32],[19,1],[7,9.01],[4,1],[6,32],[6,1.42],[7,32],[13,0],[16,1],[11,2.26],[17,32],[7,1],[0,1],[0,32],[17,7.92],[14,32],[17,4.05],[15,1],[13,32],[18,1],[10,0],[13,32],[1,4.3999999999999995],[0,9.07],[16,1],[19,1],[11,1],[5,6.55],[4,32],[12,1],[5,1],[14,1],[14,1],[15,9.95],[5,1],[11,7.43],[12,32],[5,2.3099999999999996],[2,1],[18,1],[11,1.12],[7,1],[7,4.58],[10,32],[7,1],[17,1],[8,1],[1,1],[3,1],[3,32],[17,32],[19,1],[17,7.58],[4,0],[11,1.99],[6,5.609999999999999],[13,1],[13,1],[4,6.8],[1,1],[6,1],[1,1],[15,9.23],[9,0.15000000000000002],[15,1],[19,"Infinity"],[9,8.94],[2,2.0799999999999996],[18,1.25],[11,32],[8,32],[2,1],[3,32],[16,7.5],[18,1],[12,4.51],[6,32],[9,1],[11,32],[11,32],[18,32],[4,32],[4,0],[10,1],[19,"NaN"],[16,1],[8,1],[11,0],[7,3.6399999999999997],[18,6.84],[14,9.799999999999999],[16,1],[19,"Infinity"],[19,1],[12,1],[1,8.97],[14,7.88],[15,1],[2,9.91],[7,1],[10,32],[18,9.209999999999999],[8,32],[3,3.73],[15,1],[1,1],[7,7.6899999999999995],[0,1],[4,5.01],[6,0.97],[1,1],[4,9.44],[11,1],[17,7.55],[0,1],[8,1],[12,1],[8,6.77],[9,32],[15,1],[12,32],[6,32],[8,32],[3,1],[19,32],[1,1],[2,1],[11,2.15],[14,8.19],[6,9.29],[7,1],[18,1],[15,1],[15,1],[12,-1],[1,1],[11,7.84],[10,1],[13,5.859999999999999],[4,1],[3,32],[18,32],[15,32],[6,32],[18,3.4699999999999998],[16,8.629999999999999],[8,1],[5,7.6899999999999995],[14,1],[2,0],[7,1],[13,1],[7,6.9399999999999995],[18,"Infinity"],[18,1],[11,32],[12,9.25],[4,0.58],[11,8.67],[4,1],[9,1],[13,9.94],[12,1],[3,1],[1,32],[19,1],[0,1],[1,1],[12,7.58],[12,1],[10,1],[16,1],[15,1],[18,1],[1,5.779999999999999],[18,32],[5,1],[10,1],[17,1],[11,32],[11,32],[14,1],[14,2.8499999999999996],[1,1],[4,"Infinity"],[6,1],[13,1],[11,32],[1,7.779999999999999],[10,"Infinity"],[7,1],[9,6.68],[2,"Infinity"],[10,0],[3,1],[17,8.58],[3,32],[11,1],[0,7.819999999999999],[3,3.05],[13,32],[8,0],[7,1],[4,1],[6,1],[17,32],[7,-1],[19,1],[4,1],[9,2.28],[14,1],[14,1.24],[6,1],[9,1.14],[1,4.7299999999999995],[3,7.7299999999999995],[12,6.85],[15,1],[13,1],[15,1],[12,1],[15,1],[11,1],[19,1.4],["NaN",1],[11,1],[12,1],[18,1],[18,32],[0,1.55],[13,3.05],[9,32],[8,1],[5,1],[17,1],[15,1],[9,1],[7,1],[5,1],[13,1],[0,1],[7,1],[4,1],[2,1],[10,32],[19,32],[14,2.7699999999999996],[6,-1],[0,5.24],[17,4.68],[16,1],[14,1],[4,32],[16,1],["NaN",7.59],[4,1],[3,32],[8,1],[7,-1],[16,1],[8,32],[12,32],[11,0],[0,0],[17,0],[7,1],[14,6.109999999999999],[13,1],[11,4.6499999999999995],[13,1],[11,1],[14,0],[15,1],[15,32],[13,32],[12,5.45],[14,4.68],[11,7.55],[3,32],[11,1],[8,1],[15,6.75],[15,9.91],[10,3.13],[4,1],[2,6.06],[7,1],[6,32],[11,32],[3,32],[4,3.8299999999999996],[1,-1],[1,5.859999999999999],[11,1],[14,3.6399999999999997],[8,1],[19,6.05],[4,1],[14,32],[11,1],[2,32],[17,1],[11,1.51],[17,32],[12,32],[3,1],[19,1],[1,1],[2,4.51],[5,1],[19,32],[12,9.22],[13,1],[13,-1],[12,32],[13,1],[7,1],[16,1],[6,32],[8,5.64],[6,1],[10,1],[14,1],[7,32],[19,1],[9,32],[8,1],[13,1],[5,1],[2,32],[7,6.51],[9,1],[18,4.41],[4,0.91],[9,1],[6,1],[12,1],[9,1],[13,1],[7,4.7],[3,1],[18,1],[4,32],[7,1],[16,1],[18,"Infinity"],[16,32],[12,1],[14,1],[5,1],[1,1],[8,1],[5,"NaN"],[8,2.4299999999999997],[0,8.85],[3,8.92],[12,9.23],[12,32],["NaN",1],[7,1],[19,1],[16,1],[18,1],[10,1],[19,1],[19,1],[8,1],[3,"Infinity"],[0,1],[15,32],[6,1],[5,1],[0,1],[6,32],[19,1],[8,1],[3,1],["NaN",1],[7,1],[19,3.9299999999999997],[3,4.51],[5,1],[0,0.64],[4,1],[4,0.88],[10,1],[18,1],[11,1],[8,7.88],[13,1],[5,1],[2,8.6],[6,1],[13,1],[10,4.63],[18,1],[14,1],[12,2.6999999999999997],[3,32],[0,5.4799999999999995],[2,9.27],[4,2.26]]},{"op":"add","d":0,"values":[[1,8.73],[6.434,1],["NaN",1],[27.689,9.09],[31.449,"Infinity"],[4.176,1],[24.591,32],[28.155,1],[32.288,32],[14.362,1],[74.363,1],[2.312,32],[2.524,3.7699999999999996],[44.143,32],[6.599,1],[1.597,0.36],[36.028,1],[115.13,1],[0.872,1],[7.818,1],[5.572,-1],[17.214,6.029999999999999],[22.597,1],[4.815,8.95],[46.752,32],[46.833,9.82],[20.579,1],[18.716,1],[66.619,3.2699999999999996],[35.791,3.8899999999999997],[57.904,1],["NaN",1],[87.96,1],[85.335,32],[13.943,1],[69.162,1],[38.663,1],[36.697,1],[36.864,1],[102.921,9.24],[10.344,1],[54.05,1],[29.218,32],[78.827,32],[28.925,1],[0.037,32],[16.373,6.859999999999999],[51.029,1],[5.167,"NaN"],[11.63,"NaN"]]},{"op":"merge","d":2,"from":0},{"op":"add","d":0,"values":[[396.444,32],[706.505,0],[13.419,1.31],[543.576,7.4799999999999995],[384.663,0.83],[371.644,1],["NaN",32],[24.845,0],[729.532,1],[813.446,1],[55.256,1],[396.649,1],[362.041,2.3099999999999996],[197.785,1],[842.995,9.65],[165.507,1],[922.005,32],[653.455,0.15000000000000002],[930.915,1],[89.552,1],[722.874,32],[534.693,1],[58.074,7.3999999999999995],[84.619,32],[12.645,32],[990.056,32],[634.041,1],[914.55,1],[979.867,1],[571.318,1],[9.102,32],[402.135,1],[189.981,32],[494.907,1],[261.017,1],[742.443,1],[877.197,32],[230.705,1],[112.529,4.92],[390.96,32],[579.608,2.0199999999999996],[930.897,1],[184.017,1],[286.797,1],[997.731,1],[548.488,1],[141.878,32],[126.306,2.38],[398.969,1],[174.993,32]]},{"op":"toJSON","d":0},{"op":"add","d":2,"values":[[-264768.5,1.49]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,null,null,[100,0.037,32,0.872,1,1,8.73,1.597,0.36,2.312,32,2.870331236897275,4.77,4.815,8.95,9.0276,5,9.102,32,12.645,32,15.731697928026174,9.17,18.349105204872647,9.03,24.591,32,27.84247159603246,11.09,29.218,32,32.288,32,36.435866920152094,7.89,44.143,32,46.752,32,48.586822152886114,12.82,60.93210181531175,12.669999999999998,74.363,1,78.827,32,84.619,32,85.335,32,100.40053736654805,11.24,116.79288674698795,8.3,141.878,32,165.507,1,174.993,32,184.017,1,189.981,32,307.55933660933664,8.139999999999999,390.96,32,396.444,32,445.4706,5,547.0205147679325,9.48,600.2736309148265,3.1699999999999995,722.874,32,761.807,3,842.995,9.65,877.197,32,914.55,1,922.005,32,947.2263333333333,3,990.056,32,997.731,1],null,829.46,[0.037,0.037,0.037,4.704726508914442,27.059220837925782,82.13024999999999,391.634360625,881.8468825454547,937.1767129142856,994.1053300000001,997.5777511818181,"NaN","NaN","NaN","NaN"],[0,0.0450473802232778,0.14095995069077685,0.5805285408806456,0.8108259264375963,1],[100,0.037,32,0.872,1,1,8.73,1.597,0.36,2.312,32,2.870331236897275,4.77,4.815,8.95,9.0276,5,9.102,32,12.645,32,15.731697928026174,9.17,18.349105204872647,9.03,24.591,32,27.84247159603246,11.09,29.218,32,32.288,32,36.435866920152094,7.89,44.143,32,46.752,32,48.586822152886114,12.82,60.93210181531175,12.669999999999998,74.363,1,78.827,32,84.619,32,85.335,32,100.40053736654805,11.24,116.79288674698795,8.3,141.878,32,165.507,1,174.993,32,184.017,1,189.981,32,307.55933660933664,8.139999999999999,390.96,32,396.444,32,445.4706,5,547.0205147679325,9.48,600.2736309148265,3.1699999999999995,722.874,32,761.807,3,842.995,9.65,877.197,32,914.55,1,922.005,32,947.2263333333333,3,990.056,32,997.731,1],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[5],7270.49,[-264768.5,0,0,1.9358499875608886,4.01330210517072,11,15,18,19,65.69899618072643,98.09815216992446,"NaN","NaN","NaN","NaN"],[0.052201433465969976,0.08787784592235187,0.4668302961698591,0.9990895202779558,1,1],[100,-264768.5,1.49,0,7.45,0,1,0,32,0,1,0,32,0,5.79,0,32,0,2,0,32,0,32,0,34.25,0,33.95,0,37.24,0,35,0,44.07,0,32.58,0.3865186360031721,50.44,1,39.74,1,32,1,33,1,57.839999999999996,1,60.15,1.8536913946587537,60.66,2,38.1,2,65,2,70.25,2,74.23,2,57.559999999999995,2,49.870000000000005,2.5607506307005625,51.529999999999994,3,65,3,82.98,3,72.76,3,76.78,3,64,3.112349630283633,90.61000000000001,4,92.58,4,90.09,4,90.89999999999999,4.980137356046066,83.36,5.170588235294118,81.60000000000001,6,76.2,6,73,6,76.28999999999999,6.019607843137255,102,7,87.6,7,104.31,7.44197450147107,91.77000000000001,8,106.77,8.055531960076449,94.17999999999999,9,98.1,9,108.1,9.909611404920671,86.98,10,99,10,108.87,10,108.13,10.952228642179117,96.92,11,103,11,92.32000000000001,11,106.99000000000001,11,104.67,11.124425375421392,97.89,12,98.2,12,77.15,12,81.94,12,98.18999999999998,12,78.67,12.108352402745995,87.4,13,74.7,13,72.82,13,99,13,94.85,14,98.66999999999999,14,90.33,14.072739468741615,74.53999999999999,15,77.78,15,67,15,92.31,15,82.75,15.479572830001242,80.53,16,79.12,16,85.03,16.16695675007723,64.74,17,79.35,17,65,17,76.97,17,56.709999999999994,17,70.68,17.884485010967584,41.03,18,66.22,18,53.239999999999995,18,67.17,18,58.540000000000006,18,49.050000000000004,18,37.47,18,33,18.090069804098178,44.41,19,32,19,34,19,43.86,19,39.34,19,36.14,19,37.599999999999994,19,52.36,19,35.4,19,39.05,19.111358980195767,43.93,25.27634485276223,41.09,29.178117647058823,34,32.288,32,36.435866920152094,7.89,44.143,32,46.752,32,54.40863405196241,18.09,78.827,32,85.335,32,87.96,1,102.921,9.24,115.13,1]]}, +{"name":"random 7","compressions":[1000,33.5],"ops":[{"op":"merge","d":0,"from":1},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"merge","d":0,"from":1},{"op":"merge","d":1,"from":0},{"op":"merge","d":1,"from":0},{"op":"add","d":1,"values":[[4,1],[5,1],[8,1],[14,9.68],[17,1],[13,1],[11,1],[5,1],[19,1],[10,8.81],[19,1],["NaN",1],[4,1],[15,1],[2,7.359999999999999],[11,1],[9,32],[11,1],[7,6.96],[10,32],[7,6.1499999999999995],[4,1],[13,1],[11,1],[18,1],[6,1],[14,2.71],[17,9.44],[13,6.39],[0,1],[13,32],[8,32],[11,5.84],[1,1],[13,1],[12,"NaN"],[6,1],[10,1],[15,1],[6,1],[17,8.959999999999999],[0,1],[8,1.33],[11,1],[11,32],[15,6.88],[18,1],[16,32],[4,9.89],[4,7.56],[8,32],[8,1],[16,1],[4,1.18],[18,1],[4,1],[4,1],[2,3.3699999999999997],[10,1],[5,1],[3,5.33],[3,32],[19,1],[5,1],[17,1],[2,2.5999999999999996],[7,3.3299999999999996],[1,32],[18,1],[10,7.359999999999999],[0,32],[8,1],[4,1],[1,32],[15,1],[19,6.99],[4,1],[8,8.2],[8,1],[11,3.2399999999999998],[13,32],[14,4.43],[0,3.5799999999999996],[14,1],[3,1],[13,1],[4,5.71],[17,32],[1,32],[7,6.89],[13,8.64],[2,32],[7,1],[18,1],[13,1],[11,32],[6,32],[3,8.14],[7,32],[16,1],[16,1],[3,1],[17,"NaN"],[15,2.63],[12,1],[6,1],[6,1],[8,7.66],[19,1],[10,1],[13,1],[2,9.59],[11,1],[16,1.31],[3,1],[12,32],[14,0],[10,1],[4,6.4799999999999995],[19,32],[16,1],[18,32],[1,32],[16,5.13],[0,2.9299999999999997],[12,1],[0,1],[0,1],[6,0],[9,32],[9,1],[19,9.209999999999999],[16,32],[13,1],[3,1],[5,1],[18,32],[14,1],[19,"NaN"],[4,32],[10,0.8200000000000001],[12,32],[10,32],[2,1],["NaN",32],[6,1],[10,8.09],[17,1],[9,32],[12,2.5399999999999996],[15,1],[6,1],[11,1],[5,1],[0,32],[10,32],[17,32],[10,1],[3,4.83],[2,1],[11,1],[3,1],[15,1],[15,32],[3,1],[8,6.17],[10,6.76],[19,32],[7,32],[9,32],[18,1],[9,1],[13,32],[3,2.0799999999999996],[1,1],[8,1],[1,32],[17,32],[1,32],[16,0.78],[4,32],[0,1],[6,7.92],[9,1],[1,1],[3,0],[17,4.04],[10,1],[5,1],[18,32],[19,32],[4,0],[19,1],[0,32],[3,32],[9,1],[2,5.99],[11,8.32],[3,1],[3,1],[1,32],[18,1],[10,32],[2,1],[19,1],[3,1],[3,1],[13,1],[9,"NaN"],[17,1],[9,1],[3,1],[17,9.17],[0,"Infinity"],[0,1],[2,1],[9,4.89],[6,1.34],[9,6.6],[17,1],[2,32],[13,8.74],[10,1],[16,7.3],[12,7.319999999999999],[2,4.26],[17,32],[19,32],[2,1],[10,1],[8,1],[10,1],[18,1],[12,1],[2,3.38],[9,1],[9,1],[11,8.01],[7,"NaN"],[0,1],[2,2.5999999999999996],[2,1],[0,"Infinity"],[6,1],[1,1],[19,1],[7,1],[5,8.83],[6,5.7299999999999995],[15,"NaN"],[9,32],[3,8.67],[6,1],[8,7.79],[2,1],[12,1],[6,32],[8,1],[19,1],[15,0.53],[5,1],[6,2.46],[16,3.3],[19,0.84],[1,1],[12,32],[9,6.7299999999999995],[11,1],[12,32],[7,0.22],[9,1],[19,1],[18,1],[4,1],[1,1],[14,1],[1,1],[9,5.72],[6,32],[2,7.1],[17,6.43],[4,1],[1,32],[4,1],[3,8.68],[13,32],[17,32],[16,2.42],[19,5.279999999999999],[6,4.09],[2,1],[15,1],[15,1],[2,7.09],[17,1],[7,9.35],[9,32],[2,1],[3,1],[12,1]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1}],"expect":[null,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],null,null,null,null,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[1000],2481.0999999999995,[0,0,0,1,3.6333768406934737,9.289817663783134,13.848178282686582,17.72283632762387,18.976230897824994,19,19,19,"NaN","NaN","NaN"],[0,0.12333642336060621,0.5558723953085326,1,1,1],[33.5,0,2,0,32,0,8.51,0,33,0.02857142857142857,35,1,32,1,32,1,32,1,65,1,69,1.5914719775309587,78.33,2.0733148019457954,86.33999999999999,3,90.05,3.800963634277848,87.17,5.174462825632251,105.18,6.315149246748385,106.86999999999999,7.344851833249623,99.55,8.320577038669605,99.82000000000001,9,32,9,112.49,9.52757865392274,100.43999999999998,10,80.85000000000001,10.568327577701035,81.08,11.40077865567388,87.33,12,75.86,12.56397329336422,73.39,13,86.38,13.773306014927556,68.33,15.579661454968344,77.39,16.330348873108985,64.78,17,65,17,47.21,17.04085523627945,73.43,18,67,18.31733957480008,51.27,19,41.21,19,32,19,32,19,2,19,32,19,2.84,19,1]]}, +{"name":"random 8","compressions":[1000],"ops":[{"op":"add","d":0,"values":[[720738.4,32],[-668431.1,9.03],[-497329.5,3.34],[-982025.8,9.31],[922430.9,32],[-798341.1,2.71],[-528687.9,3.03],[322021,1.65],[-947921.3,32],[660562.6,32],[176381.1,32],[214412.6,1],[-595523.2,0.96],[-552631.3,1],[951643.2,1],[327335.6,1],[69584.4,-1],[407493.9,1],[527581.4,1],[962085.1,32],[940283.3,32],[757319.2,1],[-283234.6,1],[815863.2,1],[64735.5,1],[708744,3.6799999999999997],[554985.7,32],[-564286,32],[162213.6,1],[190690,1],[-105562.2,"Infinity"],[466764.5,1],[886862.7,1],[-296107.8,1],[717481.6,1],[-388122.9,1.8800000000000001],[700488.5,1],[505892.6,"Infinity"],[732012.2,8.75],[825513.6,"NaN"],[-837263.2,1],[254242.6,1],[-505525,1],[-183560.5,1],[168421,1],[-309820,1],[-600453.9,4.7299999999999995],[769439.3,1],[-790279.5,32],[426419,1]]},{"op":"toJSON","d":0},{"op":"add","d":0,"values":[[12,1],[11,32],[2,1],[13,1],[11,1]]},{"op":"add","d":0,"values":[[699.041,5.24],[157.419,32],[101.516,32],[224.64,1],[205.094,32]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[9.444,1]]},{"op":"add","d":0,"values":[[-661926.4,1],[-682683.2,32],[-223541.2,1],[942965.7,1],[786472.1,32]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[null,[1000,-982025.8,9.31,-947921.3,32,-837263.2,1,-798341.1,2.71,-790279.5,32,-668431.1,9.03,-600453.9,4.7299999999999995,-595523.2,0.96,-564286,32,-552631.3,1,-528687.9,3.03,-505525,1,-497329.5,3.34,-388122.9,1.8800000000000001,-309820,1,-296107.8,1,-283234.6,1,-183560.5,1,64735.5,1,162213.6,1,168421,1,176381.1,32,190690,1,214412.6,1,254242.6,1,322021,1.65,327335.6,1,407493.9,1,426419,1,466764.5,1,527581.4,1,554985.7,32,660562.6,32,700488.5,1,708744,3.6799999999999997,717481.6,1,720738.4,32,732012.2,8.75,757319.2,1,769439.3,1,815863.2,1,886862.7,1,922430.9,32,940283.3,32,951643.2,1,962085.1,32],null,null,[-982025.8,-982025.8,-980922.6667901234,-793897.5813828867,-386627.53211805696,219.50473272727268,719292.0847272726,937922.8779875,955367.1612454546,962085.1,962085.1,962085.1,"NaN","NaN","NaN"],null,null,600.31,[-982025.8,-982025.8,-979799.8848971195,-790738.902039758,-557690.4993181818,218.3201266666666,725537.0272638038,934687.1304875001,953215.4970030304,962085.1,962085.1,962085.1,"NaN","NaN","NaN"],[0.28733485883048504,0.28733486790535595,0.2988220867376191,0.3743189469148594,0.5119037899454446,0.5141087349464115],[1000,-982025.8,9.31,-947921.3,32,-837263.2,1,-798341.1,2.71,-790279.5,32,-682683.2,32,-668431.1,9.03,-661926.4,1,-600453.9,4.7299999999999995,-595523.2,0.96,-564286,32,-552631.3,1,-528687.9,3.03,-505525,1,-497329.5,3.34,-388122.9,1.8800000000000001,-309820,1,-296107.8,1,-283234.6,1,-223541.2,1,-183560.5,1,2,1,9.444,1,11,32,11,1,12,1,13,1,101.516,32,157.419,32,205.094,32,224.64,1,699.041,5.24,64735.5,1,162213.6,1,168421,1,176381.1,32,190690,1,214412.6,1,254242.6,1,322021,1.65,327335.6,1,407493.9,1,426419,1,466764.5,1,527581.4,1,554985.7,32,660562.6,32,700488.5,1,708744,3.6799999999999997,717481.6,1,720738.4,32,732012.2,8.75,757319.2,1,769439.3,1,786472.1,32,815863.2,1,886862.7,1,922430.9,32,940283.3,32,942965.7,1,951643.2,1,962085.1,32]]}, +{"name":"random 9","compressions":[20,5],"ops":[{"op":"add","d":0,"values":[[3,1],[2,6.46],[7,3.17],[13,3.25],[9,1],[19,2.0799999999999996],[19,1],[9,1],[13,2.6199999999999997],[10,1],[0,1],[13,3.01],[14,1],[18,0],[7,1],[10,1],[15,1],[11,1],[8,1],[19,-1],[4,1],[13,6.49],[8,1.18],[9,1.91],[12,1.03],[14,2.1399999999999997],[7,4.81],[5,1],[15,1],[6,1],[19,32],[13,1],[15,32],[3,2.2199999999999998],[10,1],[5,32],[3,1],[1,9.41],[13,5.77],[15,2.7199999999999998],[6,1],[8,32],[2,32],[10,32],[5,1],[15,1],[10,0.41000000000000003],[4,1],[1,32],[10,9.1],[15,1],[2,"NaN"],[3,1],[3,32],[5,1],[1,1],[2,32],[15,1],[17,1],[10,0.29000000000000004],[16,1],[17,2.5799999999999996],[8,6.58],[4,4.12],[7,1],[3,1],[7,1],[2,1],[12,2.8699999999999997],[16,1],[9,1],[3,1],[19,1],[6,1],[1,1],[11,1],[9,3.2399999999999998],[2,32],[18,1],[7,1],[15,1],[16,7.1],[4,5.93],[0,1],[12,1],[19,1],[9,32],[14,1],[6,1],[4,1],[17,1],[10,1],[13,0],[3,1.48],[13,2.98],[14,-1],[17,-1],[17,6.819999999999999],[18,1],[19,32],[19,32],[10,1],[1,1],[2,0],[18,1],[14,1],[18,32],[10,1],[8,32],[14,3.96],[13,1],[12,1],[7,1],[8,1],[0,1],[17,32],[15,32],[2,0.36],[5,1],[11,1],[11,1],[1,32],[3,1],[10,1],[10,1],[12,32],[18,32],[15,1],[18,5.84],[15,1],[0,32],[7,3.59],[10,32],[13,1],[17,1],[1,2.8699999999999997],[1,1],[16,1],[9,1],[8,1.03],[10,1],[12,1],[1,1],[8,1],[8,1],[15,32],[0,1],["NaN",1],[14,1],[8,6.529999999999999],[18,0.31],[4,1],[0,32],[18,5.71],[15,32],[0,32],[9,1],[14,1],[1,1],[1,1],[1,32],[4,0],[9,32],[16,1],[5,1],[7,1],[1,1],[19,3.4499999999999997],[1,2.38],[3,1],[18,1],[14,1],[19,1],[14,32],[6,32],[16,1],[10,1],[17,32],[5,1],[3,1],[14,1],[7,1],[4,1.71],[9,1],[7,7.41],[2,1],[11,1],[10,1],[6,32],[2,1],[8,9.24],[16,32],[7,0.5],[2,32],[7,1],[18,5.59],[8,1],[5,1],[10,32],[17,1],[9,1],[5,1],[7,1],[5,3.8099999999999996],[13,3.6599999999999997],[3,1],[18,1],[0,32],[14,1],[14,1],[11,32],[17,32],[6,1],[6,1],[11,4.1899999999999995],[13,1],[13,0.88],[5,32],[17,1],[3,1],[5,4.74],[8,1],[1,1],[5,"NaN"],[9,1],[5,32],[15,32],[2,1],[16,32],[3,1],[7,1],[9,32],[18,"NaN"],[18,"Infinity"],[4,1],[7,4.04],[8,1],[9,1],[19,1],[3,1],[4,1],[8,1],[19,1],[14,1],[14,32],[5,1],[15,5.81],[12,1],[14,32],[2,7.08],[3,1],[6,1],[13,1],[18,32],[16,1],[10,1],[7,8.61],[11,9.9],[13,1],[7,3.17],[19,1],[18,-1],[7,32],[6,1.53],[5,32],[18,1],[4,7.56],[9,32],[16,32],[12,9.83],[8,1],[10,1],[7,0.15000000000000002],[12,1],[15,32],[3,1],[19,5.41],[5,"Infinity"],[10,1],[9,32],[10,32],[12,1],[14,"Infinity"],[15,32],[17,5.859999999999999],[8,1],[14,1],[0,1],[11,1],[6,32],[3,9.94],[17,32],[18,32],[19,7.62],[3,1.9],[13,1],[6,32],[9,1],[7,3.7899999999999996],[18,2.8899999999999997],[19,5.08],[8,1],[4,2.6999999999999997],[16,2.7199999999999998],[12,1],[15,1],[7,1],[9,8.5],[5,4.3],[7,2.63],[7,1],[8,1],[17,0.43],[17,1.14],[3,1],[8,1],[0,1],[5,5.779999999999999],["NaN",1],[10,1],[14,"Infinity"],[11,32],[1,1],[13,1],[18,0.6900000000000001],[10,1],[2,1],[15,6.74],[14,1],[5,1],[17,3.38],[13,32],[5,1],[7,1],[1,1],[14,32],[17,"Infinity"],[13,32],[13,1],[4,1],[13,6.77],[12,1],[11,1],[9,2.98],[15,1],[16,1],[8,5.83],[11,1],[8,1],[11,1],[5,2.3299999999999996],[6,4.14],[16,0.44],[18,1],[3,9.22],[0,1],[0,1],[13,8.64],[2,2.1399999999999997],[3,1],[3,1],[19,0.89],[13,32],[18,5.71],[5,1],[17,1],[4,3.7399999999999998],[7,1],[18,9.76],[16,1],[10,6.37],[4,32],[9,1.22],[19,6.04],[11,1],[4,2.1999999999999997],[1,1],[14,9.92],[18,1],[18,1],[10,4.4399999999999995],[12,32],[19,1],[0,3.88],[19,1],[18,1],[6,1],[15,1],[1,32],[11,32],[19,32],[3,1],[5,32],[11,6.9399999999999995],[0,32],[4,1],[2,32],[10,8.31],[1,"NaN"],[7,8.12],[6,1],[4,32],[10,1],[14,"NaN"],[1,1],[8,1.75],["NaN",6.46],[10,1],[14,32],[12,1.11],[13,32],[9,1],[4,2.86],[17,1],[8,1],[19,1],[5,2.07],[2,4.5],[9,6.91],[19,1],["NaN",0.05],[15,3.98],[12,1],[18,1],[7,32],[18,1],[14,1],[5,1],[14,1],[1,1],[0,1],[6,32],[15,1],[12,1],[1,1],[4,1],[16,3.73],[13,8.15],[3,1],[13,1],[15,1],[14,32],[17,32],[7,1],[12,1],[16,8.03],[8,4.42],[9,1],[5,1],[13,32],[2,1],[19,2.05],[16,8.99],[7,9.73],[8,6.6899999999999995],[10,1],[17,9.36],[19,5.66],[18,1],[7,32],[6,32],[1,1],[15,32],[13,1],[6,1],[13,1],[1,-1],[18,32],[13,1],[15,1],[3,32],[12,8.59],[8,"NaN"],[8,1],[18,1],[16,32],[14,1],[7,8.45],[5,1],[0,1],[16,1],[19,1],[0,1],[15,32],[7,1],[17,1],[10,32],[14,1],[0,0.81],[15,1],[14,1],[2,32],[18,1],[2,1],[9,1],[9,"Infinity"],[2,1],[8,1],[5,32],[18,32],[12,2.6199999999999997],[2,32],[11,32],[16,1],[13,32],[12,-1],[12,4.97],[7,7.819999999999999],[5,7.6499999999999995],[9,1],[0,32],[6,1],[3,"Infinity"],[4,3.3299999999999996],[0,1],[14,1],[0,1],[18,1],[2,1],[9,7.9399999999999995],[16,"Infinity"],[3,7.37],[15,1],[7,0.95],[17,1],[6,1],[9,32],[1,32],[17,1],[12,1.52],[10,1],[3,8.74],[16,2.1199999999999997],[3,"Infinity"],[5,1],[2,32],[17,1],[3,32],[17,7.2299999999999995],[12,7.45],[4,32],[0,32],[18,1],[6,5.8999999999999995],[6,7.1499999999999995],[15,32],[11,-1],[10,1],[14,7.06],[14,3.5199999999999996],[14,1],[13,1],[2,32],[11,1],[16,1],[2,1],[10,1],[6,1],[8,1],[9,1],[11,"NaN"],[9,0.54],[10,1],[8,1],[6,1],[15,8.85],[2,1],[1,1],[13,6.39],[4,8.08],[6,1],[7,32],[13,1],[14,2.0599999999999996],[0,"NaN"],[13,32],[11,5.819999999999999],[8,1.8],[5,32],[13,1],[7,1],[1,1],[18,6.93],[6,1],[17,1],[11,1],[2,1],[6,32],[16,1],[3,7.51],[19,0],[0,1],[8,1],[7,1],[4,5.17],[2,1],[19,1],[2,32],[11,6.66],[1,5.34],[2,32],["NaN",1],[19,1],[12,1],[0,1.32],[12,1],[12,32],[19,3.32],[17,1],[19,1],[13,1],[9,1],[11,9.959999999999999],[9,32],[11,1],[11,32],[7,1],[7,6.49],[5,3.6599999999999997],[0,3.51],[17,1],[14,1],[16,1],[10,1],[3,1],[13,32],[8,"Infinity"],[1,32],[17,32],[5,1],[9,1],[1,1],[14,32],[13,32],[18,0],[17,1],[6,1],[1,1.04],[14,1],[0,1],[16,9.11],[14,1],[8,32],[14,8.1],[2,32],[17,1],[14,7.3],[19,32],[1,1],[16,1],[0,9.26],[3,1],[0,4.72],[6,-1],[1,1],[19,1],[7,0.97],[4,1],[12,1],[16,1],[9,1],[12,5.67],[2,1],[1,1],[6,-1],[2,32],[12,1],[18,32],[2,32],[6,1],[19,"NaN"],[16,1],[16,32],[0,1],[17,1],[11,1],[5,1],[3,4.17],[17,1],[14,32],[0,1],[19,32],[18,"NaN"],[15,32],[16,32],[14,1.1],[10,1],[6,1],[13,1],[4,1],[10,9.51],[1,1],[1,1],[6,1],[4,-1],[17,"Infinity"],[4,6.12],[11,1],[12,1],[7,1],[7,6.77],[10,32],[6,32],[1,32],[9,1],[0,1],[9,32],[16,1],[17,1],[4,6.01],[8,1],[9,1.44],["NaN",1],[10,1],[15,7.279999999999999],[16,"NaN"],[19,1],[1,1],[2,6.9799999999999995],[19,1],["NaN",32],[16,5.569999999999999],[15,2.4099999999999997],[17,1],[19,32],[11,1],[7,1],[2,1],[2,32],[7,4.79],[0,0],[16,32],[11,8.5],[8,9.53],[16,1],[18,1],[17,32],[4,1],[0,32],[1,0],[12,32],[1,1],[0,1],[18,1],[12,4.08],[12,2.2199999999999998],[2,32],[2,1],[1,6.67],[16,2.4699999999999998],[19,1],[2,1],[14,1],[11,32],[19,1],[1,1],[7,3.0399999999999996],[10,1],[4,1],["NaN",1.86],[19,1],[17,1],[12,7.95],[2,1],[18,0],[0,1],[1,32],[4,32],[1,1],[3,32],[8,1],[12,6.67],[17,8.74],[7,"NaN"],[2,1],[5,8.35],[7,1],[3,"NaN"],[9,32],[19,6.68],[7,1],[4,1],[2,32],[10,1],[14,1],[10,1.65],[17,"NaN"],[12,1],[15,"Infinity"],[10,1],[6,32],[7,32],[9,7.74],[18,32],[8,-1],[9,1],[14,4.85],[2,32],[0,1],[3,32],[4,1],["NaN",1],[10,1],[1,7.04],[13,32],[8,6.17],[14,1],[0,8.73],[8,5.96],[4,1],[8,1],[3,1],[6,32],[0,1],[14,32],[18,2.23],[5,1],[5,9.03],[15,1],[6,1],[5,1],[15,32],[19,5.62],[5,1],[5,1],[5,1],[2,1],[1,32],[10,0],[14,1],[7,32],[9,1.06],[7,1],[10,"NaN"],[12,5.54],[12,32],[1,1],[10,2.09],[12,9.61],[10,1],[5,1],[7,1],[7,32],[19,3.8299999999999996],[10,1],[16,1],[17,0.78],[2,1],[1,1],[11,9.4]]},{"op":"merge","d":0,"from":1},{"op":"merge","d":1,"from":0},{"op":"add","d":0,"values":[[1,0.12],[4,9.17],[11,9.74],[7,1],[11,1],[9,32],[5,0],[8,32],[14,"NaN"],[15,2.0999999999999996],[4,1],[2,1],[16,1],[3,5.59],[11,1],[17,8.93],[15,32],[14,1],[19,32],[6,4.069999999999999],[14,32],[1,"Infinity"],[15,1],[15,3.6999999999999997],[7,9.66],[14,1],[16,32],[14,0],[12,1.06],[13,1],[2,8.31],[12,1],[9,1],[11,8.65],[13,1],[6,1],[7,32],[1,1],[18,1],[3,6.25],[17,1],[16,32],[1,32],[8,32],[1,9.34],[11,1],[1,1.49],[6,1],[4,1],[2,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1}],"expect":[null,null,null,null,6901.060000000001,[0,0,0,1.407208654383849,4.0487490052680615,9.546061545163283,14.659607893907442,17.425017939047688,18.442361868984058,19,19,"NaN","NaN","NaN","NaN"],[0,0.07204472936041709,0.5200007232343731,1,1,1],[20,0,36,0,104.42,0,104.81,0.7180532662444697,230.54,1,42.830000000000005,1.3534843803638859,291.3,2,331,2.4513723830299865,307.12999999999994,3.4719176335585877,313.72,5.174402781977623,396.84000000000003,6.326875787200865,500.19000000000005,7.364388167349041,368.80999999999995,8.790811591213773,387.88,9.98681090693539,337.3999999999999,11.241719790053693,497.27000000000004,12.920090475305198,322.74,13.613240020972484,438.67,14.753229421096364,397.13,15.549743563573271,391.91,16,64,16.76277460126392,332.3,17.78858407079646,226,18,99.58,18.769582348305757,190.35000000000002,19,80.13,19,72.66,19,35.45],6471.88,[0.34640261245128,0.34640261245128,0.34640261245128,1.3031001789674193,4.086317027622674,9.438115851812917,14.532234307858342,17.34723460334049,18.389400336053885,18.873452782826973,18.873452782826973,18.873452782826973,"NaN","NaN","NaN"],[0,0.07993589545918497,0.5260921224897167,1,1,1],[5,0.34640261245128,474.65,2.312349668961755,1209.83,7.310367324561403,1824.0000000000002,12.971880046866586,1578.95,16.64407530880851,1037.86,18.873452782826973,346.59]]}, +{"name":"random 10","compressions":[100,100,1000],"ops":[{"op":"reset","d":1},{"op":"add","d":2,"values":[[0,4.18]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],4.18,[0,0,0,0,0,0,0,0,0,0,0,0,"NaN","NaN",0],[0,1,1,1,1,1],[1000,0,4.18]]}, +{"name":"random 11","compressions":[100,100,20],"ops":[{"op":"toJSON","d":0},{"op":"add","d":1,"values":[[8.195,32],[2.931,1],[27.512,1],[16.574,6.6899999999999995],[29.672,5.87]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[[100],null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],46.559999999999995,[2.931,2.931,2.931,4.25688993939394,6.484997575757576,10.915088911863531,15.956782372706124,28.589799126637555,29.672,29.672,29.672,29.672,"NaN","NaN","NaN"],[0,0,0.45462393147407876,1,1,1],[100,2.931,1,8.195,32,16.574,6.6899999999999995,27.512,1,29.672,5.87],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[20]]}, +{"name":"random 12","compressions":[100,5,100],"ops":[{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"merge","d":2,"from":2},{"op":"add","d":1,"values":[[14.655,32],[277.899,1],[325.798,32],[179.166,4.43],[739.9,1]]},{"op":"merge","d":2,"from":1},{"op":"merge","d":2,"from":1},{"op":"merge","d":0,"from":0},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],null,null,null,null,null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100],70.43,[14.655,14.655,14.655,14.655,30.347246899922222,200.78058885315204,321.6284651511551,575.6897341818183,664.0691398181817,734.7726643272725,739.9,739.9,"NaN","NaN","NaN"],[0,0,0,0.3513086312120844,0.8571790884783481,1],[5,14.655,32,197.3488729281768,5.43,325.798,32,739.9,1],140.86,[14.655,14.655,14.655,14.655,14.655,197.3488729281768,325.798,424.0280138181818,600.7868250909089,739.9,739.9,739.9,"NaN","NaN","NaN"],[0,0,0,0.4028302349585908,0.9214902967594071,1],[100,14.655,32,14.655,32,197.3488729281768,5.43,197.3488729281768,5.43,325.798,32,325.798,32,739.9,1,739.9,1]]}, +{"name":"random 13","compressions":[5,33.5],"ops":[{"op":"toJSON","d":1},{"op":"toJSON","d":1},{"op":"add","d":1,"values":[[24.68,6.3],[41.622,7.1899999999999995],[29.309,1],[35.909,32],[12.795,1]]},{"op":"reset","d":1},{"op":"merge","d":1,"from":0},{"op":"add","d":1,"values":[[19,1.7],[12,1],[6,1],[2,32],[17,1],[1,1],[5,9.16],[9,0.81],[17,1],[6,1],[7,1],[9,1],[19,2.9],[17,1],[8,0.61],[15,1],[0,9.26],[18,1],[13,6.45],[15,6.9399999999999995],[14,6.42],[12,4.79],[11,1],[6,4.7299999999999995],[7,1],[18,1],[17,32],[9,8.65],[8,4.16],[2,32],[8,2.48],[10,32],[18,9.36],[18,6.27],[2,1],[9,32],[9,0.76],[1,6.35],[8,1],[14,32],[15,1],[19,4.71],[5,1],[6,1],[1,32],[18,32],[17,1],[15,32],[0,9.14],[16,4.9399999999999995],[14,1],[10,1.84],[3,1],[9,32],[1,8.6],[1,7.5],[6,1],[3,1],[15,1.79],[6,32],[4,32],[8,32],["NaN",6.95],[7,1],[17,32],[0,"Infinity"],[17,1],[7,3.71],[12,32],[7,32],[3,-1],[18,1],[16,32],[11,8.22],[0,1],[7,32],[12,1],[12,3.1399999999999997],[2,1],[16,32],[10,32],[14,32],[16,32],[11,32],[12,32],[8,1],[9,2.8899999999999997],[2,1],[12,1],[2,1],[8,5.27],[17,1],[18,1],[7,0.06999999999999999],[15,1],[19,1],[12,32],[9,3.1199999999999997],[10,1],[9,32],[17,32],[12,1],[14,1],[3,-1],[9,2.8699999999999997],[15,1],[2,1],[17,8.37],[17,6.59],[19,32],[0,1],[11,3.38],[10,32],[11,1],[4,32],[6,1],[4,1],[18,32],[8,1],[14,1],[11,1],[5,-1],[12,1],[11,1],[18,32],[6,2.38],[1,7.75],[17,1],[3,6.609999999999999],[13,4.12],[17,1],[12,32],[11,32],[0,1],[18,9.01],[11,1],[15,32],[13,32],[12,1],["NaN",9.65],[6,1],[1,1],[9,32],[6,0],[1,1],[11,1],[6,1],[1,1],[3,1],[17,1],[10,1],[3,6.3999999999999995],[14,1],[5,1],[4,6.279999999999999],[4,1],[17,7.3],[6,1],[4,4.66],[8,1],[1,"Infinity"],[0,1],[13,1],[13,32],[2,1],[5,3.4899999999999998],[15,8.7],[17,9.62],[6,"NaN"],[8,6.359999999999999],[17,1],[1,6.069999999999999],[18,32],[3,1],[9,6.63],[12,32],[12,1],[11,1],[6,1],[17,32],[6,32],[18,32],[19,32],[2,1],[12,1],[0,32],[16,1],[11,32],[6,1],[12,-1],[11,1],[10,1],[14,1],[13,1],[14,1],[4,1],[1,3.5],[17,0.61],[13,32],[5,8.81],[12,32],[11,1],[1,1],[14,7.4399999999999995],[14,1],[7,32],[1,1],[15,32],[13,1],[18,1],[2,1],[17,-1],[1,32],[3,2.5999999999999996],[16,1],[6,1],[17,1],[13,32],[19,1],[19,7.12],[3,1],[17,8.79],[15,1],[9,1],[9,1],[3,1],[7,"NaN"],[18,1],[18,2],[9,5.819999999999999],[5,1],[7,1],[6,32],[12,1],[14,1],[19,32],[18,1],[13,6.64],[16,"NaN"],[17,4.62],[18,32],[14,32],[7,3.0999999999999996],[17,1],[13,32],[7,32],["NaN",3.3],[7,1],[5,5.4399999999999995],[5,7.93],[10,32],[11,1],[17,1],[8,0.84],[15,32],[2,32],[9,1],[11,1],[13,7.06],[6,"NaN"],[18,32],[17,"Infinity"],[13,1],[8,6.46],[1,8.53],[0,1],[0,32],[15,3.0199999999999996],[7,1],[10,1],[13,8],[17,1],[18,-1],[11,1.27],[13,1],[1,1],[12,1],[8,8.08],[16,32],[3,1],[7,1],[8,1],[4,32],[13,8],[1,1],[12,1],[6,1],[8,1],[8,5.59],[19,1],[0,1],["NaN",32],[13,6.37],[3,32],[9,7.51],[17,1],[4,3.0199999999999996],[15,1],[11,1],[3,1]]},{"op":"add","d":1,"values":[[38.409,3.46]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1}],"expect":[[33.5],[33.5],null,null,null,null,null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[5],2674.96,[0,0,0,1.9789331199475297,6.76721689588801,12.000525883900487,15.66522755991715,18,18.218380029190577,19,33.68968820312391,34.057206278026904,"NaN","NaN","NaN"],[0,0.06392992792415587,0.41154024873533407,1,1,1],[33.5,0,1,0,9.26,0,13.14,0,32,0.1821561338289963,40.35,1,48.1,1,54.32,1.7524100634845992,42.53,2.027027027027027,74,3,33,3.629516447959734,55.629999999999995,4.125252525252525,89.1,5.643353837924578,74.78,6.091032424365758,73.71,7,100.16999999999999,7.6736900988252845,107.25999999999999,8.94073995547546,94.33000000000001,9.291322314049587,116.16,10.092723643621845,110.22,11.049725180350395,116.44,12,103.14,12.142424751975785,118.94000000000001,13,99,13.062867215041129,102.12,14.017630465444288,113.44,15,84.42999999999999,15.351943597560975,104.96,16.03921568627451,102,17,67,17,67.88,17.26060606060606,67.64999999999999,18,66,18,41.01,18,66,18,35,18.243677617584492,42.31,19,32,19,33,19,7.12,19,32,34.057206278026904,4.46]]}, +{"name":"random 14","compressions":[1000,33.5,5],"ops":[{"op":"add","d":0,"values":[[69586.1,1],[-48359.2,32],[81679.3,32],[-602749.6,1],[523510.5,32]]},{"op":"add","d":1,"values":[[5,32],[0,1],[11,1],[3,1],[6,1],[15,1],[1,6.34],[1,1],[7,3.51],[2,1],[5,1],[13,32],[1,32],[19,4.31],[2,8.35],[1,1],[18,3.26],[14,32],[16,1],[4,32],[1,2.59],[8,"NaN"],[5,1],[3,32],[7,32],[18,1],[5,32],[17,1],[15,2.3499999999999996],[11,32],[7,9.62],[4,1],[8,32],[8,-1],[3,0.060000000000000005],[11,32],[7,1],[15,1],[8,"Infinity"],[13,32],[9,1.82],[12,1],[4,3.4099999999999997],["NaN",1],[17,1],[18,32],[7,1],[4,"Infinity"],[18,32],[2,1],[0,1],[1,1],[0,1],[8,1],[8,32],[9,1],[5,1],[5,1],["NaN",32],[17,2.4899999999999998],[10,1],[2,32],[8,"NaN"],[17,1],[15,0],[7,1],[18,1],[19,1],[10,0.04],[18,1],[3,1],[6,32],[12,5.59],[6,32],[7,1],[10,1],[19,1],[13,32],[1,1],[8,1],[14,1],[11,32],[2,1],[12,1],[7,"Infinity"],[5,1],[7,32],[2,1],[5,32],[6,1],[4,1],[17,6.87],[4,32],[18,4.51],[14,1],[6,32],["NaN",32],[6,1],[5,32],[16,1],[16,9.68],[18,1],[17,32],[18,32],[8,9.99],[5,1],[13,32],[15,1],[18,1],[15,1],[10,1],[11,1],[6,2.17],[2,1],[18,1],[16,1],[15,32],[6,1],[11,1],[16,1],[12,1],[4,0.87],[19,-1],[5,0.09],[0,1],[17,5.37],[0,1],[8,1],[1,1],[8,1],[6,0.13],[7,1],[7,32],[12,1],[18,1],[4,1],[12,5.88],[0,0],[15,-1],[4,0.25],[3,0.35000000000000003],[19,32],[4,5.41],[2,1],[12,1],[13,1],[11,1],[9,32],[14,4.319999999999999],[15,1],[11,1],[13,1],[6,32],[7,1],[8,1],[19,9.72],[16,32],[10,8.83],[17,"NaN"],[17,6.2299999999999995],[15,1],[11,32],[15,9.98],[12,1],[4,1],[10,0],[3,32],[11,0.26],[11,32],[10,1],[6,1],[17,1],[6,"Infinity"],[1,"NaN"],[7,1],[15,32],[5,1],[16,8.5],[9,1],[18,7.319999999999999],[19,1],[13,1],[9,1],[3,1],[1,1],[9,5.38],[7,1],[11,4.17],[7,1],[1,1],[18,32],[10,32],[6,1],[19,3.3699999999999997],[17,0.23],[6,32],[4,1],[12,4.83],[1,1],[17,1],[14,1],[14,8.24],[3,1],[19,1],[6,1],[18,0.09],[12,-1],[5,0],[0,2.7199999999999998],[6,1],[15,1],[10,1],[18,5.6],[10,1],[12,3.3499999999999996],[5,32],[12,32],[12,0.49],[13,1],[11,1],[18,1],[18,2.4299999999999997],[4,1],[10,32],[16,32],[15,1],[16,1],[8,32],[17,1],[14,1],[12,1],[13,32],[11,1],[3,8.86],[17,1],[12,1],[7,1],[18,1],[10,32],[9,5.22],[6,1],[3,32],[10,3.55],[11,"NaN"],[17,"Infinity"],[7,32],[12,1],[5,0],[7,9.85],[5,8.549999999999999],[17,1],[19,6.96],[8,0.89],[1,1],["NaN",5.47],[17,1.96],[12,32],[3,4.529999999999999],[11,"Infinity"],[17,32],[7,32],[1,32],[2,"Infinity"],[11,4.4799999999999995],[1,6.7299999999999995],[7,32],[6,7.18],[7,1],[18,32],[3,1],[2,5.68],[7,1],[9,1],[2,5.819999999999999],[16,2.26],[19,32],[16,1],[5,5.069999999999999],[6,1],[5,32],[13,1],[17,1.15],[8,1.45],[16,32],[10,1],[6,-1],[6,1],[2,2.69],[16,1],[10,1],[11,32],[5,32],[19,1],[11,32],[11,1],[5,32],[2,1],[18,32],[14,1],[8,9.799999999999999]]},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0.9214516042121026,3.294992244163654,5.428469828594601,9.827960494556105,14.303118326806997,18,18.077809812019044,19,19,19,"NaN","NaN","NaN"],98,[-602749.6,-602749.6,-586621.8792727273,-290275.0109090908,5252.300000000004,80946.3787878788,406149.0875,523510.5,523510.5,523510.5,523510.5,523510.5,"NaN","NaN","NaN"],[0.24250232254844806,0.24250375005210392,0.24251659758500646,0.24264507291403178,0.2432160743763665,0.2439283987006291],[1000,-602749.6,1,-48359.2,32,69586.1,1,81679.3,32,523510.5,32],2495.05,[0,0,0.9214516042121026,3.294992244163654,5.428469828594601,9.827960494556105,14.303118326806997,18,18.077809812019044,19,19,19,"NaN","NaN","NaN"],[0,0.02098354742389932,0.5082379694009839,1,1,1],[33.5,0,5,0.7296222664015906,10.059999999999999,1,32,1,10.59,1.025169896803423,39.73,2,45.35,2.69375,49.6,3,42.86,3.4678860059549126,70.53,4.4128096072054035,79.94,5,68,5,79.71,5.010309278350515,97,6,101.3,6.0429673154608885,81.69000000000001,7,110.62,7,112.85,8,9.799999999999999,8.01580547112462,115.14999999999999,9.501444313683537,93.47,10.321794246708922,102.55,11,100.26,11.009203865623562,108.65,12,92.14,13,96,13.330097087378642,103,14.842653453331986,98.89,15.989063867016622,91.44000000000001,16.60111205125106,82.73,17.083808774345858,50.83,18,71.51,18,42.32,18,42.120000000000005,18,32,18.164708953275905,38.31,19,32,19,22.05,19,32,19,1],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[5]]}, +{"name":"random 15","compressions":[33.5,5,100],"ops":[{"op":"merge","d":2,"from":0},{"op":"add","d":0,"values":[[1.614,1],[32.339,9.28],[15.544,2],[71.366,2.5],[3.457,1]]},{"op":"add","d":0,"values":[[344.741,1],[409.187,1],[866.825,32],[64.969,1],[952.057,1]]},{"op":"add","d":0,"values":[[3,32],[1,5.04],[6,1],[15,1],[3,32],[0,6.609999999999999],[5,7.46],[0,7.74],[16,8.48],[9,1],[12,1],[2,1],[19,1],[4,1.04],[4,1],[1,1],[10,32],[7,1],[9,5.2299999999999995],[15,32],[15,32],[13,1],[5,1],[19,"Infinity"],[6,-1],[4,0],[11,1],[18,1.66],[16,0],[7,1],[15,32],[10,32],[3,1],[13,1],[1,1],[15,1],[2,9.73],[3,1],[10,32],[9,1],[3,9.12],[3,4.84],[4,1],[16,1],[17,1],[12,1],[12,2],[14,3.75],[16,1],[7,32],[8,0.61],[6,5.99],[15,32],[14,0],[10,1],[18,4.17],[0,32],[2,1],[2,1],[11,8.709999999999999],[7,1],[12,8.33],[19,1],[15,0.7],[1,1],[2,1],[14,32],[19,32],[0,32],[13,5.85],[5,1],[14,1],[19,1],[8,32],[11,1],[11,3.6799999999999997],[2,6.56],[4,"Infinity"],[9,1],[16,1],[3,32],[10,32],[14,7.7299999999999995],[10,2.61],[5,4.02],[8,1],[0,1],[2,1.55],["NaN",1],[4,1],[0,1.06],[6,1],[7,0.09],[11,1],[14,8.31],[8,1],[0,-1],[10,1],[5,32],[12,1],[1,32],[17,8.39],[7,1],[6,1],[9,32],[11,5.359999999999999],[12,1],[6,7.89],[18,1],[2,1],[18,-1],[14,1],[11,1],[10,1],[2,1],[5,1],[10,4.59],[11,1],[13,32],[3,5.569999999999999],[6,1],[0,1],[6,1],[8,1],[14,32],[11,32],[9,1],[2,1],[14,3.13],[5,1],[11,1],[4,1],[18,9.18],[8,32],[4,1],[1,32],[14,6.5],[12,6.7],[0,9.07],[11,1],[18,1],[3,1.85],[18,32],[13,1],[8,6.5],[13,1],[15,1],[0,1],[10,32],[19,2.73],[4,32],[0,1],[6,-1],[11,2.6199999999999997],[12,1],[8,1],[4,32],[2,6.02],[1,32],[4,32],[18,2.4299999999999997],[19,32],[6,7.819999999999999],[1,1],[7,4.46],[12,1],[6,1],[2,3.69],[0,1],[2,0.03],[11,1],[16,1.76],[7,1],[8,1],[15,1],[17,1],[14,1],[17,1.37],[10,8.59],[2,1],[17,1],[10,1],[4,32],[14,3.92],[2,1],[11,1],[3,3.4299999999999997],[4,0.36],["NaN",1],[0,32],[6,"Infinity"],[19,1],[19,1],[19,32],[9,1],[16,1],[10,6.2],[8,-1],[3,0.06999999999999999],[12,4.9399999999999995],[11,32],[4,1],[6,32],[14,1],[0,32],[12,5.17],[1,32],[1,6.04],[5,6.24],[9,1],[5,1],[9,1.44],[2,3.3],[10,7.21],[15,1],[11,4.16],[9,1],[7,5.64],[5,9.78],[18,1],[1,32],[15,3.3499999999999996],[1,3.9],[6,0],[12,32],[2,32],[15,8.68],[0,1],[0,3.09],[13,1.51],[5,32],[3,1],[15,1],[5,32],[2,1],[14,1],[5,1],[0,32],[12,7.64],[18,32],[8,"Infinity"],[0,1],[14,2.9099999999999997],[11,1],[12,1],[16,1],[12,0],[7,7.81],[9,32],[3,5.6899999999999995],[2,9.35],[2,4.42],[5,1],[0,1],[13,1],[10,1],[3,1],[0,1],[18,1],[13,1],[18,1],[16,32],[0,3.5999999999999996],[10,1],[8,5.6],[7,32],[18,1],[18,6.319999999999999],[7,2.5999999999999996],[6,1],[9,32],[14,1],[10,8.2],[2,1],[15,1],[5,2.05],[19,0],[13,1],[10,32],[9,1],[19,1],[18,32],[3,1],[3,1],[6,1],[0,2.7699999999999996],[4,5.029999999999999],[11,1],[5,-1],[13,32],[17,1],[3,32],[4,5.22],[16,1],[11,1],[19,1],[15,1],[4,1],[19,1],[16,9.19]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,null,null,2355.53,[0,0,0,0.8888882429253036,3.0833822849594514,8.715619060976211,13.54292907740889,17.833117424242424,19,648.4897885574487,942.472119214544,952.057,"NaN","NaN","NaN"],[0,0.13181746783101891,0.5965196792229349,0.9830088487581831,0.9881073219751259,1],[33.5,0,2.7699999999999996,0,6.609999999999999,0,7.74,0,32,0,34.06,0,45.07,0,36.09,0.17238421955403085,46.64,1,64,1,71.04,1.5274029695233136,76.77999999999999,2.415800415800416,81.77000000000001,3,32,3,87.37999999999998,3.874486521181001,93.48,4.170979198376458,78.83999999999999,5,83.02000000000001,5.658646616541353,99.75,7.006915315723841,88.21,8.09213030336953,89.33,9,102.44,10,97,10,98.2,10.593734209196564,98.95,11.44233849439402,74.92,12.59349862258953,90.75000000000001,13,32,14,85.16999999999999,14.79203168126725,83.33,15,72.05,15.96868155312189,70.31,17.655303030303028,66,18,32,18.107944732297067,46.32,19,35.73,19,34,19,32,87.78199729364005,14.78,866.825,32,952.057,1],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[5],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100]]}, +{"name":"random 16","compressions":[1000,20,33.5],"ops":[{"op":"reset","d":2},{"op":"toJSON","d":1},{"op":"add","d":2,"values":[[-279379.1,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,[20],null,0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[1000],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[20],1,[-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,"NaN","NaN",-279379.1],[1,1,1,1,1,1],[33.5,-279379.1,1]]}, +{"name":"random 17","compressions":[100,100,100],"ops":[{"op":"add","d":1,"values":[[855049.8,1],[-311188.2,1],[-566680.8,1],[-173757.5,1],[975151.9,1],[850888.4,2.3],[80620.6,1],[858259.1,1],[166971.8,"NaN"],[696082.7,32],[873691.6,2.4899999999999998],[166088,1],[-607217,32],[703503.6,1],[-834783,8.2],[102486.8,1],[803171,1],[-651241.4,1],[-623430.5,1],[-178839.2,1],[326703.6,1],[738779.7,-1],[980689.8,32],[-543328.5,9.86],[-306978.1,1],[888210.7,1],[-570128.6,1],[576964.4,5.59],[373646.5,1.53],[472540.4,1],[496094.2,1],[785855,1],[-203209.4,1],[501020.4,1],[723629.2,1],[631634.5,1],[-404669.1,1],[142750.6,32],[-311235.7,1],[435573.9,32],[-398104.5,"NaN"],[927498.7,1],[-570794.2,1],[607557.5,1],[203664.9,1],[-99809.2,1],[-124497.5,32],[487638.8,32],[747102.5,32],[-777836.3,6.1899999999999995],[41113.4,32],[30423.5,1],[-139486.7,32],[-447120.9,1],[408933.6,32],[38622.5,1],[767683.7,32],[932264.7,9.78],[565179.3,1],[801448.4,-1],[474596.7,32],[-171753.8,32],[548194.9,1],[828089.4,5.46],[584341.9,1],[436596.4,1],[554518.8,"NaN"],[-954916.8,1],[-401326.9,1],[103334.1,1],[-598873.4,32],[-302667,-1],[-791952,1],[-983272.2,1],[142445,1],[747948,1],[469680.2,1],[557793.1,7.25],[-986632.2,1],[-555304.1,32],[-91705.7,1],[304882.2,9.799999999999999],[708878.4,32],[-435361.5,1],[-28789.3,4.55],[792781.4,9.31],[-419216.2,1],[-83664,1],[-361630.1,2.82],[-782481.2,1],[898471.3,1],[-419961.7,1],[36291.9,1],[-365266.2,0.37],[-650157.9,1],[-932323.9,1],[268001,1],[652450.4,32],[675354.6,32],[750389,1],[-609376.6,1],[165856.9,1],[-182778.5,1.93],[-330392.7,8.03],[-634771,1],[-427236.9,32],[530875.7,1],[-241276,1],[-704746.4,9.99],[727915.3,1],[825068.3,"Infinity"],[-103096,1],[156834.9,8.01],[78221,32],[-922918.1,1],[-50920.1,7.37],[-527751.9,1],[335070.5,9.049999999999999],[-447736.3,1],[434407.8,8.299999999999999],[-461728.2,1],["NaN",1],[-653719.1,32],[-475176.5,0.08],[988593.6,"Infinity"],[126071.6,7.38],[402894.2,1],[871508.2,32],[-48754.9,32],[334345.5,32],[-456818.3,1],[943743.2,1],[-582131.4,1],[-923137.6,3.9299999999999997],[993649.8,6.59],[673801.9,32],[215305.3,1],[-98378.5,1],[398366.7,1],[197559,5.3999999999999995],[-225772.1,32],[846128.7,32],[204534.5,"Infinity"],[-785129.2,1],[-308561,1],[846975.6,0],[-279987.3,1],[451597.8,1],[746809.8,1],[113283.7,1],[-958929.1,1],[990726.5,32],[968718.9,-1],[367282.8,0],[-910120.5,1],[-856517.2,1],[181670.2,2.65],[-717494.8,1],[-632097.8,32],[429371.6,1],[-138810.1,1],[-739602,1],[534836.1,1],[-90491.9,32],[448015.3,32],[853826.4,1],[-926340.9,1],[-498283,2.98],[-472839.3,7.529999999999999],[792137.5,2.03],[-196433.9,1],[309755.7,4.029999999999999],[93943.1,0.25],[317259.5,-1],[-936491.9,9.93],[-179113.6,1],[890535.4,1],[-796689.7,1],[-89128.4,1],[-85723.8,1],[904658.2,32],[677323.8,32],[859627.8,1],[751793.6,0.46],[566516.2,32],[-647885.7,32],[810041.7,2.7699999999999996],[-585077,32],[-367594.4,1],[-110245,1],[91584,1],[998657.5,"NaN"],[36616,1],[-8963.9,1],[-76876.6,32],[911454.2,32],[889773.5,32],[841241.2,0.66],[732573.8,2.57],[-386598.1,1],[794893,1],[228146.5,32],[-688106.3,1],[-95286.3,1],[729456.4,1],[-677618.5,1],[53713,1],[-486050.6,1],[971895.8,1],[-97057.5,2.03],[367267.4,7.77],[-247711.5,8.52],[532083.2,1],[-401445.7,1],[-341193.9,"NaN"],[527156.1,1],[-748588.9,1],[759554.4,2.0999999999999996],[-901046.4,3.86],[354040.2,1],[-202720.8,1],[-916566.4,3.6399999999999997],[-697645.3,1],[175669.4,32],[-553875.7,32],[564975.5,1],[-602858.5,32],[-562407.6,1],[-950044.3,1],[69634.1,4.2299999999999995],[688241.2,1],[-877052.8,32],[-752239.4,1],[737316.5,1.34],[967349.9,1],[-463646,32],[658467.5,1],[851448.1,0],[768174.4,1],["NaN",1],[709985.1,32],[651713,1],[766360.3,1],["NaN",1],[-643986.6,1],[570955.9,1],[570352,0],[481285.1,"NaN"],[-765595.4,1],[268895.2,1],[520346.7,1],[383573.9,1],[-409902.8,32],[-834739.6,1],[678309.6,1],[886778.7,4.13],[-909605.9,2.38],[-752526,1],[578298.7,"Infinity"],[526331.7,32],[-366383.7,32],[-735040.4,1],[-133818,"NaN"],[675669.2,1],[878851.4,6.9799999999999995],[-414608.4,32],[-129933.3,"Infinity"],[-909417.4,1],[156769,1],[77380,3.69],[66398.7,6.859999999999999],[368337.9,1],[-739387.8,1],[-123006.7,"Infinity"],[655186.7,5.59],[-325403.3,1],[839002.4,1],[235055.3,1],[405297.4,32],[-882918.5,4.52],[294024.1,6.45],[345808.5,1],[-780243.5,"Infinity"],[246868.3,"NaN"],[355814.5,2.8299999999999996],[-720827.6,32],[991263.5,1],[193116.2,1],[716640.9,1],[-938269.8,1],[-405057.7,8.129999999999999],[621760.1,7.72],[468556.9,4.85],[514275.8,1],[-522961.5,1],[195282.9,1],[584491.4,1],[-33933.8,1],[987314.8,1.34],[631093.1,32]]},{"op":"add","d":0,"values":[[6.617,32],[56.117,-1],[73.126,1],[16.18,8.17],[33.694,1]]},{"op":"add","d":2,"values":[[-340801.4,1],[581161.7,32],[612734.6,4.02],[244830.4,1],[831117.2,1],[933448.2,1],[-117697,2.71],[-206794,1],[407410.1,7.859999999999999],[681126.6,32],[-473013.1,1],[799095.8,32],[975486,1],[640504.8,1],[-212149.6,1],[-631209.4,-1],[-50570,32],[-5929.1,6.359999999999999],[441308.6,32],[941285.8,32],[640937.5,0.85],[-785802.6,1],[-197244.1,0],[703746.9,3.03],[749710.2,1],[-427102.4,1],[962921.2,1],[978582.6,5.319999999999999],[-47378,1],[-386807.8,7.3999999999999995],[162170.1,9.59],[-530927.9,32],[800189.6,7.42],[679263.6,1],[540205.1,1],[55114.6,1],[-505723.3,1],[410303.6,1],[964259,1],[597983.8,6.29],[920348.7,1],[184001.4,32],[114789.9,1],[457991.6,1],[-92086.9,1],[-849867.9,1],[-288993.5,1],[-888778.7,0.56],[908557.4,32],[745446.6,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,null,42.17,[6.617,6.617,6.617,6.617,6.617,9.038103061986558,14.057666293253671,23.315474809160314,31.369622900763368,73.126,73.126,73.126,"NaN","NaN","NaN"],[0,0,0.5479074021830096,1,1,1],[100,6.617,32,16.18,8.17,33.694,1,73.126,1],2184.3799999999997,[-986632.2,-969378.0233067998,-920803.856051553,-636467.2565882353,-416950.7233676471,179205.46022503666,674200.507203125,869626.2532080073,910284.226125,990783.3308727273,993649.8,993649.8,"NaN","NaN","NaN"],[0.4261956358228345,0.4261958365771016,0.4261976433655058,0.42621571124954866,0.4263062321111086,0.4264239493208948],[100,-986632.2,1,-971100.6499999999,2,-947743.6333333334,3,-936491.9,9.93,-925226.9086003372,5.93,-916549.6978723404,5.64,-905016.3737569061,7.24,-882918.5,4.52,-877052.8,32,-829927.7950819671,12.2,-768837.6646702049,13.19,-737214.1000000001,2,-720827.6,32,-702021.546533238,13.99,-653719.1,32,-650699.65,2,-647885.7,32,-639378.8,2,-632097.8,32,-616403.55,2,-607217,32,-602858.5,32,-598873.4,32,-585077,32,-570428.52,5,-555304.1,32,-553875.7,32,-510761.63748400856,23.45,-463646,32,-449753.04,5,-427236.9,32,-419588.95,2,-414608.4,32,-409902.8,32,-400209.69543031225,13.129999999999999,-366383.7,32,-299294.32823485415,26.74,-225772.1,32,-187495.19609079446,7.93,-171753.8,32,-139486.7,32,-124931.21515151515,33,-99071.90846824409,8.03,-90450.58181818182,33,-84693.9,2,-76876.6,32,-50920.1,7.37,-48305.77575757576,33,209.28638743455667,9.55,41495.20606060606,33,70066.27368064952,14.78,78684.60588235295,34,121706.25821152194,11.629999999999999,143175.4,33,158660.5843156843,10.01,175669.4,32,195486.63319502075,12.05,229521.89117647058,34,301984.5276481149,22.28,334345.5,32,357531.68885209714,27.18,405297.4,32,409552.9333333333,33,434407.8,8.299999999999999,435604.8848484849,33,448123.8606060606,33,469302.4182481752,6.85,474596.7,32,487638.8,32,507934.275,4,526331.7,32,550687.7736842105,14.25,566516.2,32,599223.8976314269,17.31,631093.1,32,641673.75,2,652450.4,32,655684.5452200304,6.59,673801.9,32,675354.6,32,675669.2,1,677323.8,32,683275.3999999999,2,696082.7,32,703503.6,1,708878.4,32,709985.1,32,731220.0197530864,8.91,747102.5,32,756400.4669064748,5.56,767683.7,32,794298.3361678631,18.11,830841.252247191,7.12,846128.7,32,854572.4476190476,6.3,871508.2,32,880854.9032191781,14.599999999999998,889773.5,32,894503.3500000001,2,904658.2,32,911454.2,32,935535.2555555556,12.78,973523.8500000001,2,980689.8,32,987314.8,1.34,990726.5,32,991263.5,1,993649.8,6.59],376.41,[-888778.7,-883969.225348718,-759479.4499230301,-443741.02644871786,99243.21533649704,546043.4134558822,799353.1565449011,930012.0418029411,948496.9443818182,977500.6518797469,978582.6,"NaN","NaN","NaN","NaN"],[0.23677028568154845,0.23677040787286927,0.2367715075947569,0.2367825048136331,0.23683138134197168,0.23689235481107404],[100,-888778.7,0.56,-849867.9,1,-785802.6,1,-530927.9,32,-468612.9333333333,3,-386807.8,7.3999999999999995,-280648.1666666667,3,-141712.3638814016,3.71,-92086.9,1,-50570,32,-47378,1,-5929.1,6.359999999999999,84952.25,2,162170.1,9.59,184001.4,32,244830.4,1,407410.1,7.859999999999999,410303.6,1,441308.6,32,499098.35,2,581161.7,32,597983.8,6.29,618266.5123505977,5.02,661654.3108108108,1.85,681126.6,32,721174.9318091451,5.029999999999999,799095.8,32,800189.6,7.42,831117.2,1,908557.4,32,926898.45,2,941285.8,32,962921.2,1,964259,1,975486,1,978582.6,5.319999999999999]]}, +{"name":"random 18","compressions":[5],"ops":[{"op":"add","d":0,"values":[[1.313,0.21000000000000002],[40.388,32],[44.985,1],[1.042,32],[80.918,32],[26.493,1],[24.045,6.35],[5.628,1],[33.273,1],[31.099,1],[10.992,4.45],[23.629,1],[24.096,1],[4.366,1],[97.407,1],[20.723,1],[57.609,1],[31.895,1],[5.402,1],[15.3,1],[16.6,1],["NaN",1],[140.833,1],[0.851,1],[22.84,1],[17.463,1],[29.899,0.14],[14.541,1],[13.812,1],[118.266,32],[10.016,4.4799999999999995],[14.889,4.1],[16.568,8.19],[26.983,32],[36.304,32],[10.906,1],[28.925,5.16],[9.154,0.68],[5.84,1],[13.872,7.569999999999999],[12.343,1],[6.076,1],[62.322,2.59],[20.746,32],[81.269,1],[1.285,1],[34.069,32],[42.684,1],[69.918,8.76],[17.429,32],[3.365,1],[43.542,1],[32.558,1],[137.541,32],[12.189,1],[23.707,32],[54.732,1.44],[64.766,5.16],[1.083,1],[55.916,1],[104.718,8.03],[17.928,7.45],[13.429,1],[16.627,6.2],[43.436,1],[61.047,1],[4.259,4.04],[97.891,1],[27.449,1],[2.299,32],[88.077,1],[16.887,1],[4.96,1],[131.899,2.88],[24.088,1],[9.168,1],[18.915,9.93],[71.169,0.2],[11.496,1],[3.813,1],[31.849,1],[10.18,1],[27.14,1],[13.6,1],[61.886,1],[0.53,8.57],[6.483,3.1399999999999997],[66.723,"NaN"],[4.396,9.08],[3.236,1],[97.254,4.5],[89.583,32],[13.148,32],[10.167,1],[15.415,1],[50.354,1],[18.307,8.34],[5.908,1],[40.906,1],[8.545,1],[59.7,7.45],[10.04,3.7699999999999996],[2.081,32],[3.904,32],[18.077,32],[46.01,1.59],[23.704,4.95],[18.498,6.12],[5.666,1],[25.048,32],[23.575,1],[22.457,1],[8.719,32],[16.168,6.76],[137.867,6.859999999999999],[1.617,1],[90.34,1],[15.895,5.12],[10.236,1],[23.486,4.34],[14.235,1],[33.881,8.81],[11.222,2.23],[12.236,1],[6.795,5.4799999999999995],[1.794,32],[11.145,1],[15.992,1],[9.602,1],[20.555,6.75],[72.046,1],[45.719,1],["NaN",1],[31.912,1],[24.285,7.33],[1.221,3.15],[7.111,1],[4.902,0.54],[27.78,5.64],[33.387,1],[33.245,6.779999999999999],[80.932,1.95],[1.761,1],[10.161,3.84],[80.399,3.9699999999999998],[23.697,"Infinity"],[11.787,3.1199999999999997],[19.25,1],[49.12,6.09],["NaN",1],[3.1,1],[38.808,0],[19.425,1],[29.428,"Infinity"],[84.407,1],[1.208,1],[9.934,1],[0.545,2.6999999999999997],[16.248,4.75],[19.633,5.1],[22.799,1],[14.393,1],[19.492,1],[1.756,1],[1.478,9.37],[45.103,1],[7.813,2.11],[15.72,-1],[20.787,32],[88.308,1],[17.342,3.8099999999999996],[65.675,32],[94.081,0.67],[1.779,1],[45.716,32],[14.876,1],[29.868,0.8],[10.785,0.99],[3.853,1],[61.447,1],[52.852,1],[7.282,1],[20.432,1],[24.125,1],[2.274,32],[76.992,9.549999999999999],[38.911,1],[19.628,32],[91.992,"Infinity"],[9.509,0.58],[14.705,1],[12.43,32],[38.862,32],[65.419,1],[39.079,32],[67.845,5.99],[27.452,1],[26.263,"NaN"],[18.058,3.9],[26.116,1],[98.644,32],[56.02,9.15],[37.241,32],[17.509,32],[9,1],[143.382,1],[156.983,32],[74.21,32],[31.587,1],[7.958,32],[15.367,1],[58.069,32],[83.269,32],[1.396,32],[40.463,1],[15.974,8.09],[19.261,0.9400000000000001],[7.16,1],[54.582,1],[33.013,3.4699999999999998],[8.181,"Infinity"],[157.826,3.38],[202.937,32],[15.68,9.28],[22.826,1],[32.397,1.62],[30.571,1],[67.752,1],[49.237,1],[11.288,8.43],[136.556,1],[1.299,32],[27.934,1],[36.262,1],[15.366,0],[25.123,1],[39.352,"NaN"],[23.838,7.1],[23.382,9.59],[7.09,1],[11.961,1],[6.758,1],[4.174,1],[18.929,32],[16.682,1],[0.141,6.609999999999999],[2.997,1],[9.588,6.17],[5.401,0.38],[28.406,0.65],[3.948,1],[19.149,32],[26.079,32],[92.789,1],[0.135,1],[47.62,2.2899999999999996],[154.604,32],[90.565,32],[9.802,1],[1.232,0],[87.284,5.38],[53.784,32],[18.668,1],[77.096,9.64],[88.856,1],[54.573,0],[5.698,32],[101.77,1],[8.608,1],[25.231,1],[12.916,1],[20.419,1],[2.939,1],[106.987,32],[6.085,7.74],[39.396,0.84],[33.485,7.02],[0.798,9.31],[2.338,7.17],[3.101,32],[6.66,1],[26.892,1],[1.047,1],[1.517,32],[31.928,3.7699999999999996],[36.822,3.6599999999999997],[9.909,2.9099999999999997],[109.871,1],[5.286,1.1],[1.06,1],[68.715,32],[12.122,32],[28.353,1],[12.264,1],[32.866,32],[59.431,32],[55.34,-1],[16.905,1],[0.948,32],[24.117,1],[22.516,1],[1.453,"Infinity"],[40.282,1],[29.187,1],[19.183,1],[25.398,0.99],[90.022,1.98],[11.775,5.55],[80.599,1],[46.602,32],[1.333,9.629999999999999],[6.294,1],[14.351,1],[146.935,1],[5.96,1],[18.953,32],[9.319,-1],[12.79,1],[8.007,1],[14.885,1],[7.981,8.52],[15.048,1],[2.443,8.2],[27.878,1],[1.413,32],[23.97,32],[17.22,8.75],[83.097,1],[10.791,32],[38.239,32],[47.515,8.16],[12.05,8.04],[27.261,1],[11.918,9.39],[44.375,0.33],[20.222,1],[32.392,1],[39.66,0],[13.431,1],[4.407,1],[90.817,1],[35.077,32],[24.205,1],[1.689,1],[42.256,32],[122.897,32],[28.695,-1],[47.453,1],[67.846,1],[20.404,1],[30.73,1],[23.752,1],[80.931,1],[11.658,32],[6.625,1],[8.814,0.99],[21.729,1.51],[12.058,1],[44.523,32],[35.78,1],[37.065,1],[26.981,1],[52.093,1],[51.353,7.7299999999999995],[21.379,1],[34.753,1],[44.914,32],[5.104,"Infinity"],[108.651,1],[1.963,0.32],[33.677,1],[27.009,1],[16.914,1],[45.866,3.2199999999999998],[7.782,"NaN"],[13.106,32],[6.963,32],[21.826,32],[5.013,1],[39.468,32],[58.699,1],[14.754,1],[76.124,1],[5.028,1],[29.15,1],[56.018,"NaN"],[17.238,0],[8.19,1.3],[118.516,1],[2.795,32],[25.225,32],[0.395,7.33],[22.564,1],[9.559,1],[9.626,1],[26.869,7.24],[35.983,1],[35.103,32],[30.382,32],[3.768,1.27],[11.42,7.25],[37.929,1],[16.058,1],[18.646,1],[58.423,1],[15.148,1],[95.863,1],[13.525,4.16],[9.917,1],[173.645,1],[13.632,1],[17.642,1],[5.528,6],[20.855,1],[29.487,2.9699999999999998],[15.092,1.48],[81.555,1],[145.179,8.01],[19.788,1],[2.04,32],[9.513,"NaN"],[5.016,1],[1.2,32],[15.573,1.87],[42.652,1],[1.099,1],[20.819,7.069999999999999],[13.905,4.24],[39.826,1],[22.048,1],[12.324,1],[32.023,1],[38.047,5.97],[0.614,9.879999999999999],[15.88,2.0799999999999996],[49.89,1],[22.39,32],[101.607,32],[3.737,2.3099999999999996],[54.274,1],[6.246,32],[57.62,1],[13.508,8.52],[22.053,1],[22.161,32],[31.983,32],[91.983,1],[36.085,32],[3.064,1],[29.101,1.76],[60.944,2.17],[26.44,32],[24.006,1],[23.608,6.85],[11.057,1.04],[4.828,5.21],[47.683,32],[10.959,1],[22.994,1],[21.011,8.459999999999999],[23.777,1],[2.845,1],[11.317,1],[13.787,7.29],[27.866,3.01],[1.161,"Infinity"],[108.756,1],[183.543,1],[1.145,1],[15.346,1],[20.212,4.68],[1.419,7.77],[17.318,1],[24.291,2],[17.294,1],[43.216,1],[12.883,1],[27.99,32],[2.116,1],[31.996,1],[1.017,2.4699999999999998],[53.949,6.17],[136.267,32],[8.028,32],[16.002,1],[8.127,1],[11.819,5],[27.661,1],[27.391,1],[35.532,1],[82.87,8.81],[44.249,1],[4.231,1],[37.736,-1],[25.273,1],[23.634,3.8299999999999996],[64.341,1],[14.986,1],[86.415,1.83],[25.67,1],[30.705,1],[13.171,"NaN"],[15.988,1],[8.781,-1],[42.767,2.4],[44.543,8.91],[57.015,1],[20.77,"Infinity"],[29.689,32],[48.066,1],[26.011,32],[1.288,0.61],[18.037,1],[12.459,6.31],[87.927,1],[4.264,32],[29.945,32],[17.767,5.05],[20.641,1],[13.862,1],[7.777,1],[16.358,32],[18.114,32],[1.074,1],[7.325,6.54],[21.441,1],[14.083,1],[107.921,6.47],[34.423,0],[22.338,1],[90.683,1],[31.482,32],[5.94,32],[42.593,"NaN"],[62.272,2.3],[10.496,6.93],[0.756,1],[15.53,32],[38.796,3.76],[10.364,1],[63.999,1],[42.535,1],[1.596,4.96],[29.321,1],[4.138,32],[5.615,1],[6.141,8.56],[71.372,1],[11.198,32],[21.275,1],[34.342,8.35],[26.388,1],[0.529,32],["NaN",8.35],[14.686,5.279999999999999],[12.552,1],[47.314,0.28],[19.765,1],[65.313,1],[4.122,1],[59.111,1],[44.685,6.7],[65.751,1.27],[138.16,1],[8.924,1],[0.264,0.11],[40.169,4.3999999999999995],[1.025,1],[56.296,1],[6.715,32],[10.077,2.34],[7.143,1],[60.898,32],[7.293,1],[17.016,32],[2.903,1.58],[12.661,32],[65.031,1],[30.272,32],[23.47,1],[14.385,32],[50.897,1],[4.457,32],[42.975,1],[13.489,1],[8.93,1],[2.656,1],[15.1,6.27],[22.361,1],[14.16,8.44],[24.245,0.49],[17.786,32],[27.789,1],[64.68,1],[225.576,1],[86.509,"Infinity"],[25.626,5.31],[68.273,32],[142.018,1],[43.501,1],[1.32,1],[0.656,0.13],[42.75,1],[92.362,1],[28.23,1],[11.796,1],[64.691,8.29],[76.092,1],[22.037,1],[42.393,1],[3.485,1],[9.759,4.91],[136.192,"Infinity"],[121.755,4.779999999999999],[18.895,3.63],[6.476,1],[1.234,1],[18.791,3.5999999999999996],[53.715,1],[12.844,1],[13.542,32],[38.95,1],[7.839,0],[53.314,1],[36.753,1],[65.644,1],[42.277,2.75],[7.633,1],[7.39,1],[14.479,32],[9.156,1],[9.317,"Infinity"],[45.83,32],[71.543,1],[5.905,"NaN"],[118.151,2.19],[15.05,1],[4.335,1],[0.131,32],[42.116,4.92],[12.201,7.71],[38.785,1],[45.34,32],[40.033,1],[35.927,1],[1.433,1],[31.895,1],[46.966,6.64],[7.083,1],[31.109,9.23],[12.152,32],[13.714,1],[4.693,32],[23.667,1],[41.324,1],[5.511,1],[0.34,1],[85.675,1],[9.353,3.32],[124.663,1],[4.422,1.89],["NaN",1],[33.994,1],[50.187,1],[3.268,32],[20.885,9.64],[54.589,32],[16.448,0.68],[6.582,5.09],[10.839,1],[0.321,1],[1.545,32],[10.57,3.5399999999999996],[31.366,1],[41.564,1],[75.569,1],[44.564,1],["NaN",32],[11.418,32],[33.58,1],[25.72,1],[55.62,1],[51.589,2.0199999999999996],[4.695,9.42],[77.33,1],[22.445,1],[12.194,1.16],[29.13,1],[31.262,1],[26.732,1],[47.563,1],[37.957,-1],[25.775,8.51],["NaN",1.8],[45.393,3.9699999999999998],[6.86,0.46],[48.293,1],[112.626,8.31],[78.359,1],[30.159,1],[0.507,32],[6.102,1.79],[6.515,1],[21.257,0.63],[15.773,1],[19.427,1],[2.642,32],[150.074,5.93],[36.095,1],[99.198,1],[8.169,1],[48.781,1],[43.658,1],[108.874,1],[60.342,1],[47.468,4.02],[8.235,32],[101.347,1],[15.109,1],[24.459,1],[6.566,32],["NaN",1],[6.419,32],[64.422,1],[120.432,"Infinity"],[13.199,1],[8.235,-1],[7.873,32],[30.996,32],[47.994,1],[15.741,1],[10.357,1],[76.752,32],[32.284,32],[24.513,32],[76.259,-1],[48.44,1],[48.839,1],[41.389,4.5],[11.402,0.6900000000000001],[37.76,"Infinity"],[17.757,1],[21.319,32],[7.283,2.6199999999999997],[33.983,32],[38.976,32],[39.081,1],[8.662,32],[21.399,4.79],[16.865,32],[34.477,32],[5.848,1],[5.202,1],[77.37,1],[4.698,32],[26.264,32],[17.094,-1],[11.122,6.56],[73.745,1],[12.285,32],[23.409,6.56],[4.954,1],[25.419,32],[12.839,32],[12.747,1],[8.023,1],[11.12,0.68],[17.163,32],[5.345,1],[9.692,32],[45.177,1],[10.162,1],[2.903,1],[68.108,3.59],[8.07,0.49],[1.9,1],[13.295,1],[19.184,1],[28.568,"NaN"],[9.436,32],[39.335,32],[14.963,"NaN"],[36.709,6.1],[1.593,32],[56.414,1],[51.437,32],[0.932,32],[2.424,1],[41.956,1],[8.979,1],[19.232,1],[69.794,1],[12.51,32],[6.338,32],[36.287,4.64],[22.909,7.8],[11.947,0.6900000000000001],[7.963,1],[78.514,1],[80.799,0],[3.117,3.86],[42.305,1],[2.367,1],[18.184,1],[65,2.67],[25.373,0],[9.352,3.8899999999999997],[12.113,32],[47.6,1],[86.335,3.5999999999999996],[13.231,1],[14.095,1],[14.887,32],[44.904,1],[2.189,1],[40.829,1],[20.572,3.5],[37.841,1],[52.153,5.279999999999999],[31.123,1],[21.382,"Infinity"],[60.295,0.6900000000000001],[7.95,1],[49.97,1],[1.714,1],[14.599,5.96],[23.504,1],[26.916,32],[4.472,1],[48.481,2.4499999999999997],[12.06,32],[4.893,32],[23.024,32],[42.576,32],[26.171,1],[12.514,1],[10.139,32],[15.854,32],[58.071,1.24],[18.137,32],[9.452,1],[0.716,32],["NaN",1],[37.648,1],[21.5,1],[2.833,1],[12.238,1],[34.114,32],[42.398,1],[64.476,32]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[625.654,7.77]]},{"op":"add","d":0,"values":[[834263,1],[250120.5,8.17],[893447.2,6.3999999999999995],[736819.9,32],[314498.1,1],[-583055.6,1],[-458782.3,4.59],[436958.8,1],[-452123.9,1],[445059.7,1],[-487936.1,1.18],[104773.3,32],[-848809.9,3.0599999999999996],[581899.3,1],[-470199.6,1.99],[-343210,6.71],[-855218.6,1],[376806.5,1],[-249355,1],[139176.7,1],[-403216,1],[-717126.5,32],[195287.2,1],[665463.8,1],[-718585.5,-1],[-800432.9,1],[109734,1],[-140568.6,1],[46717,1],[184278.5,32],[-732693.7,1],[-91867.4,32],[-604689.7,32],[-929301.3,6.02],[227887.8,-1],[-379502.6,8.129999999999999],[-223503.6,0],[300985.1,1],[-437445.9,1],[551413.3,6.71],[-326582.6,1],[-942271.9,32],[-168988,2.59],[510831.3,1],[-765359.2,32],[-690127.1,32],[217329.1,32],[159410,9.31],[858682.8,32],[705590.7,32]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[null,[0.8168154040591775,0.8497715883583292,1.1463772470506939,4.225925563556494,9.942037271975485,22.08528960580176,43.574184899262804,76.20281490237531,113.97686645294222,143.31940829093872,149.68410075158502,202.937,"NaN","NaN","NaN"],[0.8168154040591775,0.8497715883583292,1.1463772470506939,4.225925563556494,9.942037271975485,22.08528960580176,43.574184899262804,76.20281490237531,113.97686645294222,143.31940829093872,149.68410075158502,202.937,"NaN","NaN","NaN"],null,null,7088.16,[-727743.1499999999,-727743.1499999999,-663105.9363226059,-107752.38706653508,9.200578776687657,22.120638945937298,2316.9003668357245,60593.54048965231,316625.07533566846,618268.66674465,877638.7946747382,893447.2,"NaN","NaN","NaN"],[0.2018553364257231,0.20185628169792727,0.26769980001600036,0.6877346680654602,0.6989693329815772,0.7129845774644329],[5,-727743.1499999999,64,-157577.61254772893,621.9499999999999,7.02639849371711,1489.7600000000002,17.60893635326422,1831.83,35.26127002557515,1708.6900000000005,7286.868730683409,1178.6499999999999,500530.1671018836,186.88,893447.2,6.3999999999999995]]}, +{"name":"random 19","compressions":[100,20],"ops":[{"op":"add","d":1,"values":[[11.449,4.96],[15.657,2.07],[24.637,7.09],[8.902,1],[54.04,1],[25.341,1],["NaN",1],["NaN",1],[10.422,32],[24.502,1],[1.835,1.36],[131.067,"Infinity"],[21.868,1],[33.63,1],[47.674,1],[15.891,1],[63.626,1],[9.881,32],[14.851,1],[8.313,1],[34.472,1],[1.173,32],[13.21,1],[7.133,7.14],[59.595,1],[25.251,1],[56.835,32],[31.184,32],[31.001,1],[9.598,8.25],[30.159,1.35],[3.815,1],[16.392,1],[6.685,3.6999999999999997],[54.2,7.67],[0.24,1],[1.398,1],[60.633,32],[69.66,3.03],[53.697,1],[11.471,1],[62.973,1],[27.529,32],[18.029,32],[12.957,1],[16.998,0],[13.392,32],[28.91,2.4299999999999997],[23.001,6.91],[16.758,1],[14.738,1],[102.592,32],[7.819,6.54],[9.938,1],[8.314,4.12],[3.924,5.72],[48.973,1.83],[11.616,7.49],[96.184,4.55],[41.099,1],[14.68,1],[17.794,32],[40.818,32],[73.97,4.37],[36.089,1],[80.833,1],[21.538,1],[9.587,32],[3.201,1],[0.844,32],[1.4,1],[79.115,1],[6.61,32],[9.637,5.64],[22.479,5.529999999999999],[2.862,1],[7.28,1],[8.098,32],[15.754,1],[56.94,1],[35.658,5.45],[19.238,32],[2.607,32],[14.012,1.49],[7.484,"NaN"],[5.496,1],[29.664,1],[65.318,8.85],[36.041,1],[16.808,"Infinity"],[190.782,1],[46.972,9.93],[16.545,32],[61.98,1],[49.514,1],[71.001,1],[21.183,9.379999999999999],[50.023,9.53],[66.966,1],[2.272,32],[29.376,3.25],[6.507,1],["NaN",1],[53.132,"Infinity"],[4.158,32],[14.235,32],[56.431,32],[76.513,"NaN"],[45.935,1],[6.107,32],[2.222,1],[42.855,1],[17.9,32],[3.847,1],[107.613,1],[64.066,4.13],[3.468,1],[6.941,1],[42.261,1],[71.919,1],[19.408,1],[24.74,32],[14.06,0],[49.956,32],[9.416,9.39],[17.955,1],[5.55,1],[30.205,1],[23.318,1],[1.926,"NaN"],[49.669,7.41],[27.501,1],[57.698,1],[9.19,32],[6.664,9.86],[30.722,1],[151.521,1],[18.192,1],[11.652,1],[37.55,1],[26.038,1],[25.381,32],[15.179,1],[48.437,1.53],[25.753,1.58],[21.199,7.49],[2.151,1],[17.149,1],[35.439,1],[11.6,1],[24.688,32],[31.253,1],[87.737,1],[5.239,1],[84.011,1],[86.525,1],[0.147,1],[2.221,3.42],[30.816,8.22],[63.701,8.67],[13.768,32],[7.203,1],[31.873,1],[4.679,-1],[6.123,32],[14.929,2.6999999999999997],[17.658,6.109999999999999],[3.886,32],[30.115,0.25],[2.249,1],[64.365,0.25],[29.337,32],[74.417,32],[65.491,32],[18.288,1.55],[16.276,6.9799999999999995],[2.073,32],[31.422,1],[23.568,1],[5.639,32],[23.596,1],[6.943,1],[34.247,5.43],[23.366,7.069999999999999],[124.238,0.68],[29.257,1],[57.492,1],[56.316,32],[27.925,1.18],[32.624,1],[22.938,5.1],[5.379,32],[30.767,8.08],[8.79,1],[50.202,1],[8.916,32],[66.622,1.47],[38.899,9.25],[34.448,1],[59.711,1],[10.567,1],[1.115,1],[0.863,32],[1.259,1],[34.927,9.74],[14.242,3.1399999999999997],[30.131,32],[6.565,32],[17.859,6.45],[6.09,1],[90.525,1],[0.216,1],[18.157,7.859999999999999],[36.218,1],[3.89,1],[11.022,7.819999999999999],[45.842,9.86],[10.03,32],[13.992,1],[21.147,2.38],[36.077,1],[31.053,4.4399999999999995],[39.843,1],["NaN",0.79],[34.926,1.7],[0.03,0],[7.183,32],[0.984,1],[89.373,3.55],[31.961,1],[22.081,1],["NaN",1],[6.515,1],[10.492,1],[25.704,1],[39.101,3.8],[36.635,1],[27.586,5.66],[9.711,1],[6.174,32],[32.564,1],[83.805,7.43],[4.654,1.25],[7.272,32],[15.027,1],[4.608,1],[76.11,3.11],[10.156,1],[36.996,9.47],[20.587,32],[96.868,32],[69.556,1],[63.856,7.52],[91.858,9.52],[11.978,32],[27.936,1],[19.646,1],[15.888,1.15],[37.868,1],[17.81,32],[9.924,1],[9.814,8.99],[10.862,1.68],[65.228,32],[49.267,0.05],[15.951,1],[2.602,2.1399999999999997],[30.261,1],[41.192,"NaN"],[2.327,1],[14.599,1],[25.691,1],[22.963,1],[5.644,1],[75.024,1],[27.882,1],[30.318,7.76],[3.759,1],[8.424,1],[10.729,1],[16.073,1],[16.069,1],[27.66,1],[50.145,32],[22.008,32],[19.145,32],[10.442,32],[14.886,8.72],[30.615,4.2299999999999995],[69.809,32],[38.355,1],[18.089,1],[6.797,4.37],[35.76,9.97],[2.554,1],[0.968,7.359999999999999],[1.638,1],[18.396,1],[68.719,32],[19.825,0.68],[3.639,7.71],[18.473,1],[9.964,2.0599999999999996],[3.161,32],[13.458,7.14],[39.864,1],[13.005,1],[2.136,32],[125.562,32],[7.253,2.86],[20.502,0],[1.349,2.0399999999999996],[14.093,4.319999999999999],[31.939,1],[34.835,1],[70.151,4.67],[55.714,1],[60.493,1],[189.044,1],[3.422,2.46],[11.387,1],[40.468,-1],[3.984,6.7],[11.291,1],[100.774,1.18],[14.894,1],[61.117,32],[33.761,1],[15.051,32],[12.581,1],["NaN",2.8699999999999997],[13.934,"Infinity"],[17.749,32],[8.442,32],[0.574,9.82],[31.987,32],[57.824,3.53],[0.84,32],[0.397,4.8],[12.413,32],[33.205,1],[12.749,1],[16.594,10],[42.072,7.06],[158.016,1],[99.887,32],[69.939,2.36],[11.489,-1],[13.968,1],[94.621,1],[3.334,32],[16.567,32],[0.26,32],[6.928,1],[15.807,8.97],[86.26,3.67],[15.637,1],[33.241,1],[13.968,32],[49.926,32],[11.91,5.83],[3.76,9.95],[1.407,32],[43.72,1],[30.45,32],[23.662,1],[4.763,1],[5.57,1],[4.116,1],[19.265,1],[57.62,8.5],[1.046,32],[2.877,7.1899999999999995],[90.854,"NaN"],[7.973,1],[95.864,32],[24.676,3.1799999999999997],[89.091,1],[115.8,1],[15.426,5.319999999999999],[45.649,1],[5.06,1.11],[51.936,1],[13.032,"NaN"],[9.524,1],[8.736,5.99],[16.421,1],[46.642,1],[0.954,2.8],[58.474,32],[27.028,1],[12.49,1],[63.688,1],[16.168,2.9499999999999997],[63.387,9.15],[4.911,1],[4.204,1],[20.75,1],[17.337,32],[42.041,3.28],[4.044,1.8800000000000001],[24.05,0],[27.246,1],[9.127,32],[13.354,1],[2.133,1],[3.8,1],[2.845,32],[6.535,1],[30.231,-1],[1.223,1],[24.834,3.28],[19.165,"Infinity"],[16.839,2.0399999999999996],[34.177,32],[48.252,1],[9.709,9.65],[17.26,1],[6.677,0],[8.964,1.87],[23.517,5.9799999999999995],[23.636,1.79],[44.135,1],[12.73,32],[23.628,1],[19.318,1],[7.203,32],[19.572,1],[5.485,5.91],[33.973,1],[2.063,1],[38.971,1],[16.536,32],[24.929,1],[31.974,32],[17.161,7.05],[12.697,5.77],[45.822,1],[65.428,1],[59.779,32],[21.011,1],[6.248,1],[12.89,6.01],[0.169,0],[1.427,32],[53.005,0.06999999999999999],[6.8,1],[68.831,1],[2.455,-1],[39.979,2.8899999999999997],[81.806,1],[30.79,1],[5.417,1],[8.76,1],[28.819,3.59],[6.79,1],[19.57,3.55],[48.687,7.87],[12.249,4.49],[1.245,2.84],[12.726,1],[41.398,32],[25.904,9.85],[14.375,7.52],[78.94,5.87],[20.301,1],[79.164,32],[132.199,32],[32.545,-1],[21.817,1],[80.47,32],[49.585,1],[48.41,8.11],[82.95,1],[3.616,1],[78.745,3.1399999999999997],[21.533,3.6599999999999997],[23.729,1],[33.224,5.08],[21.212,1],[45.559,32],[39.028,8.11],[59.129,32],[1.383,1],[32.457,1],[26.914,1],[1.993,32],[1.297,1],[33.592,1],[45.972,32],[12.365,1],[9.078,-1],[53.256,2.8899999999999997],[28.358,4.27],[28.691,1],[21.005,1],[18.489,32],[21.82,2.4699999999999998],[9.851,1],[6.244,1],[0.631,1],[5.762,32],[8.784,32],[17.433,32],[8.295,32],[6.353,6],[35.449,32],[47.034,32],[1.389,1],[6.734,1],[20.575,1],[113.492,32],[13.297,1],[8.06,32],[9.92,1],[16.526,32],[4.154,1],[30.783,1],["NaN",1],[12.216,3.65],[28.907,6.18],[24.368,1],[24.788,1],[76.147,1],[1.216,1],[30.254,3.9499999999999997],[0.98,3.38],[15.08,32],[5.511,9.51],[21.084,32],[14.657,32],[28.642,32],[32.075,1],[17.078,1.37],[51.491,1],[52.838,32],[75.045,0.83],[14.946,1],[2.397,1],[79.797,"Infinity"],[21.082,1],[1.129,1],[41.185,3.82],[0.123,1],[51.053,0.63],[42.122,32],[35.217,1],[44.687,1],[0.627,-1],[6.613,0.55],[23.351,1],[11.06,8.629999999999999],[26.564,32],[27.772,1],[16.28,0.51],[40.303,1],[29.962,1],[25.126,4.51],[5.686,8.51],[10.919,1],[4.02,32],[0.743,1],[8.439,1],[18.784,1],[7.24,5.12],[13.529,4.81],[29.821,1],[3.453,1],[41.629,32],[24.837,0.39],[12.198,1],[12.418,7.029999999999999],[2.948,1],[38.676,1],[15.607,32],[32.516,1],[33.142,0.61],[54.007,0],[5.437,32],[0.595,1],[6.453,4.1899999999999995],[2.372,1],[34.45,1],[147.576,1],[67.486,6.63],[36.951,8.84],[42.287,1],[0.536,1],[3.701,3.32],[7.696,1],[2.328,-1],[30.975,"Infinity"],[39.172,32],[31.6,1],[31.65,1],[56.702,1],[16.151,2.7399999999999998],[24.207,"Infinity"],[35.227,1],[16.482,32],[44.039,32],[48.111,32],[9.515,8.23],[43.785,1],[101.014,1],[24.648,32],[52.304,6.91],[107.305,1],[109.426,1],[3.743,32],[1.576,1],[19.176,1],[179.331,3.8699999999999997],[13.092,1],[36.939,32],[92.762,1],[32.692,2.2399999999999998],[40.179,2.03],[14.555,1],[52.124,32],[7.468,1],[37.605,6.18],[19.039,6.02],[18.973,2.0999999999999996],[117.31,1],[91.473,1],[12.799,1],[4.221,1],[8.71,1],[11.068,1],[27.787,7.529999999999999],["NaN","Infinity"],["NaN",1],[25.106,3.1199999999999997],[5.321,2.42],[10.959,1],[39.959,6.26],[42.776,0.58],[4.34,1],[0.357,1],["NaN",1],[59.361,6.12],[27.366,1],[4.393,32],[30.018,1],[12.765,1],[17.043,"NaN"],[48.925,1],[0.818,1],[68.641,32],[4.147,0.91],[7.536,32],[18.878,1],[105.741,1],[68.63,1],[4.416,1],[4.729,9.67],[44.284,1],[27.399,32],[126.17,32],[36.422,1],[1.114,6.08],[5.452,32],[28.085,1],[66.816,1],[18.763,5.54],[23.704,1],[93.012,2.21],[10.244,0.39],[43.249,1],[61.417,32],[71.923,1],[39.733,7.21],[18.264,1],[10.176,32],[13.26,8.35],[30.493,8.32],[69.578,4.02],[34.191,1],[18.849,32],[23.964,1],[2.01,1],[83.002,"NaN"],[13.479,1],[52.089,1],[26.192,32],[64.153,"NaN"],[23.428,5.04],[8.039,9.14],[7.129,1],[6.328,1],[4.505,32],[8.038,1],[44.064,1],[12.77,1],[15.657,1],[114.02,1],[75.544,1],[28.779,1],[25.656,32],[37.404,1],[15.673,1],[5.373,1],[6.14,5.85],[41.24,1.05],[12.083,1],[2.185,"Infinity"],[29.05,32],[51.988,1],[6.119,1],[24.906,6.05],[10.831,5.18],[12.934,32],[9.06,32],[11.923,1],[66.375,1],[1.189,4.029999999999999],[39.958,7.79],[54.549,5.6499999999999995],[18.923,1],["NaN",32],[5.12,1],[38.444,32],[48.043,1],[66.671,0],[31.038,5.8999999999999995],[1.884,1],[45.034,1],[36.435,7.38],[18.78,0],[23.468,1],[31.924,"Infinity"],[1.903,4.45],[25.776,7.3999999999999995],[24.271,1],[96.67,1],[0.045,1],[3.788,1],[88.757,1],[3.321,32],[190.733,1],[0.975,32],["NaN",5.18],[63.558,1],[30.097,"NaN"],[46.12,1],[2.095,1],[23.655,32],[13.105,0.84],[0.67,1],[21.957,1],[83.904,-1],[48.03,32],[37.321,"Infinity"],[41.604,7.33],[44.759,1],[17.718,1],[22.332,"NaN"],[63.914,"NaN"],[64.011,1],[50.127,9.7],[23.061,1],[41.879,0.84],[24.135,1],[7.408,7.59],[38.349,3.0999999999999996],[53.492,1],[22.985,1],[28.007,1],[10.691,1],[41.542,32],[4.109,3.0399999999999996],[79.575,1],[0.144,32],[69.203,32],[47.857,4.8],[1.127,1],[27.887,1],[14.87,0.65],[51.513,32],[23.311,1],[43.914,1],[27.603,32],[27.785,1],[36.197,1],[0.566,1],[2.663,0.67],[20.613,8.29],[11.87,32],[88.199,1],[5.931,1],[27.579,32],[5.454,32],[30.234,8.39],[23.157,32],[2.413,1],[6.853,8.53],[2.956,32],[1.111,1],[86.965,0],[3.892,1],[73.309,32],[21.66,1],[17.641,0.73],[3.635,1],[40.274,1],[6.506,1],[15.035,1],[60.326,1],[77.802,32],[77.882,1.62],[123.153,8.42],[14.139,1],[69.853,32],[42.63,-1],[5.838,1],[17.692,32],[71.276,1],[2.179,1],[37.996,1],[10.136,1],[16.957,9.64],[62.067,32],[0.353,1],[9.999,9.03],[7.552,3.7899999999999996],[7.915,1],[152.271,1],[18.243,1],[90.351,32],[23.211,32],[35.714,1],[15.784,1],[107.396,1],[65.691,2.51],[5.6,1],[18.853,1.87],[11.966,1],[0.977,1],[2.419,1],[7.44,32],[14.448,6.43],[2.108,1],[5.219,32],[28.259,32],[31.578,1],[40.19,1],[47.582,32],[39.491,1],[25.317,1]]},{"op":"add","d":0,"values":[[12,1],[5,32],[17,1],[9,1],[3,1],[5,1],[19,32],[6,1],[9,4.99],[7,1],[13,3.7699999999999996],[13,32],[6,32],[12,1.24],[5,0.11],[0,1],[9,1],[5,32],[2,8.2],[7,1],[6,8.48],[16,1.3],[16,7.12],[3,4.64],[13,1],[17,1],[18,-1],[10,3.82],[3,1],[14,"Infinity"],[19,1],[16,1],[4,4.6899999999999995],[5,1],[0,1],[17,6.02],[6,32],[12,1],[8,5.069999999999999],[0,8.85],[14,32],[11,1],[19,"Infinity"],[2,1],[3,32],[15,32],[14,32],[4,1],[17,7.6499999999999995],[4,32]]},{"op":"add","d":0,"values":[[12,1],[0,1],[18,1],[10,6.31],[10,1.14],[12,2.09],[4,1],[19,5.609999999999999],[2,1],[16,32],[2,1],[13,3.2199999999999998],[7,32],[19,1],[3,1],[11,"NaN"],[17,1],[11,1],[3,32],[16,1],[5,1],[10,1],[14,5.66],["NaN",32],[15,32],[19,8.15],[1,1],[1,1],[7,1],[12,32],[5,1],[8,1],[2,1],[17,1],[0,1],[17,1],[11,1],[15,32],[15,6.37],[16,32],[15,"Infinity"],[16,1],[16,32],[5,7.67],[3,1],[13,1],[2,32],[5,32],[7,1],[10,32],[14,5.13],[4,4.47],[14,32],[6,1],[19,1],[17,32],[3,1],[13,10],[17,1],[5,2.53],[11,32],[14,1.75],[0,1],[11,7.8],[1,8.35],[6,32],[7,32],[5,32],[15,1],[2,0.19],[9,1],[18,32],[7,6.569999999999999],[5,32],[6,1],[9,1.95],[5,1],[8,1],[0,"NaN"],[12,1],[14,0.74],[13,32],[2,1],[8,1],[5,32],[3,6.8],[15,32],[15,0.32],[12,3.1999999999999997],[9,32],[3,32],[8,"NaN"],[12,0.85],[9,32],[15,1.62],[18,6.92],[5,32],[18,1],[9,1.04],[6,1],[18,1],[6,6.08],[14,1],[10,1],[8,1],[12,32],[6,1],[3,32],[7,1],[12,8.18],[13,1],[7,32],[12,-1],[11,32],[15,5.74],[2,1],[2,1],[16,0.19],[14,1],[9,1],[13,1],[15,1],[19,0.65],[18,1],[13,4.81],[4,1],[3,1],[11,32],[14,1],[19,1],[0,1],[12,32],[6,1],[13,0.43],[18,1],[15,8.45],[18,4.54],[5,1],[17,1],[12,1],[19,4.859999999999999],[18,32],[9,1],[5,1],[11,32],[14,1],[7,1],[16,1],[4,7.43],[15,1],[0,1],[12,3.23],[9,1.3],[10,5.8999999999999995],[4,32],[3,1],[3,1],[14,1],[15,3.32],[6,1],[3,1],[17,1],[10,1],[4,1],[11,1],[3,1],[9,8.27],["NaN",1],[15,1],[7,1],[6,1],[9,1],[3,1],[5,1],[14,1],[13,32],[1,32],[7,1],[11,1],[3,1],[5,1],[19,32],[7,32],[7,5.34],[15,4.89],[1,32],[10,8.97],[18,32],[16,32],[2,1],[11,1],[7,1],[10,1],["NaN",1],[15,"NaN"],[16,1],[10,1],[13,1.48],[16,1],[13,32],[7,0],[17,1],[4,1],[18,0.9400000000000001],[2,7.43],[13,32],[15,32],[2,1],[5,1],["NaN",1],[10,1],[18,1],[18,4.359999999999999],[14,5.25],[17,1],[6,1],[8,1],[9,5.58],[15,6.63],[1,8.44],[8,1],[12,2.1199999999999997],[7,4.5],[0,"NaN"],[15,32],[4,3.26],[2,"Infinity"],[8,1],[11,1],[12,6.27],[11,1],[2,1],[5,1],[3,1],[13,32],[19,1],[14,1],[11,32],[14,1],[3,1],[5,1],[9,32],[11,1],[3,1],["NaN",1],[15,1],[12,9.98],[15,1],[16,7.02],[8,32],[6,8.48],[18,32],[1,1],[11,1],[15,1],[19,1],[16,32],[15,1],[14,6.279999999999999],[19,5.1],[10,32],[8,1.47],[6,32],[12,1],[1,1],[4,4.67],[6,1],[3,1],[11,1],[17,1],[6,1],[0,1],[15,32],[8,32],[6,1],[19,1],[15,32],[1,8.67],[19,1],[11,32],[12,32],[8,5.96],[2,32],[0,4.56],[1,1],[19,5.55],[4,2.9699999999999998],[9,7.1899999999999995],[13,1],[3,4.46],[8,1],[14,32],[0,1],[11,1],[1,1],[8,1],[19,"Infinity"],[19,1],[17,1],[17,1],[11,6.99],[8,6.74],[13,1],[16,1],[5,1],[9,7.47],[8,2.2399999999999998],[15,8.69],[7,3.86],[12,1],[12,32],[18,1.87],[17,32],[15,1],["NaN",1],[19,32],[9,4.85],[14,32],[16,1],[9,1],[18,1],[11,1],[12,1],[17,"Infinity"],[2,4.319999999999999],[15,8.1],[3,1.74],[14,32],[8,4.6899999999999995],[13,0.76],[3,3.5799999999999996],[8,1],[15,1],[18,1],[12,1],[9,1],[3,32],[14,1],[1,1],[15,2.38],["NaN",32],[11,1],[3,1],[9,0],[16,1],[5,32],[14,32],[0,1],[5,1],[17,3.7399999999999998],[12,1],[14,1],[0,2.34],[1,1],[18,6.609999999999999],[9,5.2299999999999995],[17,8.73],[1,1],["NaN",1],[5,1],[3,-1],[4,1],[7,1],[18,32],[1,1],["NaN",1],[13,1],[2,1],[10,1],[14,1],[3,32],[9,32],[5,1],[0,1],[10,1],[8,1],[10,32],[16,1],[1,8.23],[16,1],[15,32],[7,5.779999999999999],[13,32],[19,7.95],[16,8.47],[5,0.09],[9,1],[0,32],[11,1],[6,1],[7,32],[10,6.34],[0,32],[8,0.55],[0,32],[17,9.51],[18,1],[13,2.3699999999999997],[3,1],[15,1],[10,0.76],[10,8.17],[2,1],[3,1],[10,1],[1,32],[13,1],[16,32],[2,1],["NaN",32],[15,1],[2,5.01],[10,32],[5,32],[12,1],[5,5.63],[15,32],[4,1],[19,0],[2,6.92],[6,1],[19,1],[13,32],[15,6.43],[18,1],[8,1],[10,1],[6,"NaN"],[13,5.25],[19,1],[12,1.45],[19,32],[4,1],[16,7.109999999999999],[12,1],[14,8.94],[6,1],[7,5.43],[14,32],[8,9.03],[2,6.4399999999999995],[8,1],[8,1],[6,1],[6,1],[10,32],[13,1],[13,4.97],[19,32],[17,32],[16,0.49],[8,7.21],[0,2.25],[12,1],[17,1],[6,32],[9,1],[1,2.61],[3,9.26],[5,32],[15,32],[0,"NaN"],[2,"Infinity"],[10,1],[17,9.84],[5,32],[1,1],[16,32],[7,1],[4,1],[11,-1],[16,"NaN"],[13,7.1499999999999995],[0,"NaN"],[3,3.75],[3,7.31],[5,1],["NaN",1],[10,32],[11,9.209999999999999],[17,1],[12,32],[1,0.06999999999999999],[2,32],[16,1],[7,1],[2,9.04],[1,0.76],[2,0.98],[2,1],[18,4.04],[12,1],[14,1],[17,9.94],[16,1],[8,1],[3,1],[0,1],[3,1],[14,1],[0,0.51],[7,1],[4,32],[17,1],[1,32],[3,0.43],[11,0.6900000000000001],[12,1.66],[0,1],[1,1],[18,1],[16,1.55],[1,1],[18,"NaN"],[5,8.76],[1,1],[2,1],[13,1],[19,1],[12,0.39],[13,1],[7,5.26],[2,1],[3,1],[2,32],[8,32],[13,1],[10,1],[6,6.66],[5,1],[0,32],[7,32],[0,1],[16,1],[6,1],[5,32],[8,32],[7,1],[19,32],[18,1],[15,1],[19,1],[11,32],[9,32],[7,32],[17,3.7699999999999996],[19,7.09],[16,32],[11,32],[16,1],[14,1],[17,3.98],[16,32],[2,32],[15,0.47000000000000003],[18,1],[1,1],[18,1],[2,1],[12,1],[8,1],[4,1],[14,32],[8,32],[7,32],[2,4.76],[5,7.27],[13,1],[12,1],[11,32],[0,32],[3,8.16],[5,1],[13,1],[19,1],[8,1],[17,1],[9,3.2399999999999998],[13,1],[7,1],[4,32],[7,1],[1,4.7],[2,1],[9,9.32],[6,1],[4,32],[3,32],[0,1],[3,32],[16,1],[1,9.36],[8,3.13],[11,1],[9,1],[10,1],[1,32],[12,1],[11,1],[8,32],[8,32],[6,1],[5,1.82],[15,32],[9,6.38],[3,1],[14,1],[2,32],[0,1],[3,1.59],[19,1],[3,32],[15,5.1499999999999995],["NaN",1],[1,32],[10,1],[4,32],[5,1],[7,32],[17,1],[4,0.37],[17,32],[13,1],[15,3.88],[3,1],[6,1],[6,1],[16,32],[6,8.34],[15,32],[7,1],[16,1],[17,0],[4,1],[10,1],[0,1],[19,1],[19,1],[17,0.42],[16,1],[11,32],[13,1],[3,2.5],[0,1],[12,6.6],[8,1.46],[4,5.31],[6,1],[7,32],[0,1],[3,1.4],[0,1],[11,1],[13,1],[17,32],[16,5.33],[14,1],[0,1],[15,1],[16,32],[7,4.74],[11,1],[14,-1],[17,1],[6,32],[2,32],[9,32],[15,2.4],[10,1.77],[5,7.29],[6,1],[9,1],[12,1],[6,1],[0,4.05],[9,9.44],[18,1],[13,32],[13,5.37],[13,10],[10,1],[10,1],[14,1],[5,1],[6,32],[5,1],[1,8.27],[13,1],[11,3.1199999999999997],[18,32],[0,1],[8,1],[1,1],[7,1],[19,1],[1,1],[16,1],[14,1],[6,-1],[13,9.49],[19,6.09],[17,1],[17,1.27],[13,1],[5,1],[1,1],[9,1],[5,32],[1,2.48],[16,1],[2,32],[16,1],[17,8.93],[1,1],[19,1],[16,32],[8,3.3699999999999997],[13,1],[7,1],[10,1],[10,0.73],[17,32],[12,1],[18,1],[0,1],[1,32],[16,0.17],[15,0.78],["NaN",1],[5,1],[16,1],[16,1],[18,32],[9,8.83],[4,4.8],[15,0.77],[2,32],[6,32],[2,1],[6,8.84],[11,1.57],[16,1],[0,1],[11,0],[14,3.42],[14,1],[9,1],[12,1],[0,1],[9,1],[11,1],[19,7.92],[15,1],[9,32],[0,1],[3,1],[3,1],[1,1],[6,32],[18,9.77],[15,32],[16,1],[2,32],[2,1],[18,1],[11,1],[4,1],[0,1],[6,9.22],[18,1],[18,1],[8,7.72],[2,1],[7,8.42],[13,5.41],[18,32],[17,1],[8,1],[3,1],[5,1],[8,6.95],[8,1],[17,1],[5,1],[15,32],[15,1],[6,5.42],[18,"Infinity"],[4,1.16],[9,4.59],[14,32],[7,0],[10,1],[15,1],[9,32],[0,1],[0,32],[1,1],[9,7.02],[9,4.22],["NaN",1],[14,1],[2,2.0399999999999996],[7,1],[8,7.6499999999999995],[11,1],[16,1],[5,1],[8,1.95],[4,0.89],[13,1],[2,0.62],[2,1],[16,1],[11,32],[16,1],[13,32],[6,1],[16,1],[16,32],[8,1],[7,1],[12,3.61],[3,1],[4,32],[15,0],[6,1],[8,1],[2,1],[9,32],[18,1],[9,32],[9,1],[13,1],[14,9.17],[4,32],[19,32],[18,0.5],[4,1],[8,2.92],[9,0.09999999999999999],[13,8.57],[19,1],[9,5.56],[19,1],[9,2.8],[8,9.24],[13,1],[8,7.81],[8,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1}],"expect":[null,null,null,7367.220000000001,[0,0,0,2,5,9.643202843287721,15,17,18,19,19,"NaN","NaN","NaN","NaN"],[0,0.06693501755071789,0.5121993099160876,1,1,1],[100,0,1,0,32,0,16.85,0,9.899999999999999,0,32,0,32,0,32,0,4.76,0,32,0,34,0.41423357664233573,27.4,1,32,1,41.44,1,23.9,1,36.44,1,40.7,1,41.36,1,46.74999999999999,1.3381468110709986,49.86,2,45.62,2,57.69,2,45.019999999999996,2,65,2,37.76,2,64,2.028985507246377,69,3,72.64,3,76.8,3,47.78,3,65.91,3,66.59,3.5303119482048264,84.95,4,65,4,56.33,4,65,4.0127161749745675,78.64,5,75.78,5,66.53,5,65,5,75.09,5,69.63,5,96.13999999999999,5.554026503567789,78.48,6,86.56,6,93,6,98,6.406504065040652,93.48,7,74.57,7,99.17,7,99,7.249086651053865,106.75,8,18.05,8,101.67999999999998,8,106.21000000000001,8.099829265843123,99.57,9,113.89999999999999,9,85.99,9,92.74,9,106.21,9.63675171249876,100.73000000000002,10,82.27000000000001,10.009132420091325,109.5,11,32,11,106.8,11,105,11,83.89,11.117452440033086,84.63,12,77.23000000000002,12,88.6,12.051921192990093,91.86999999999999,13,42.57,13,86.46000000000001,13,97.47999999999999,13,103.13,13.098920338488474,102.80999999999999,14,74.78999999999999,14,86.02000000000001,14,99,14,84.36,14.666666666666666,96,15,93.82,15,79.52000000000001,15,85.16999999999999,15,72.43,15,74.5,15,69.95,15.577219597115146,80.41999999999999,16,32,16,66.19,16,78.02,16,48.07,16,69.55,16,72.33,16.0273336066694,73.17,17,56.67,17,53.98,17,64.53,17,32.42,17,44.2,17.068493150684933,36.5,18,47.46,18,32,18,38.3,18,42.48,18,43.04,18,33,18,44.769999999999996,18,32,19,34,19,39.61,19,15.66,19,34,19,13.649999999999999,19,32,19,9.95,19,32,19,32,19,1,19,32,19,12.09,19,8.09,19,7.92],6904.069999999999,[0.141,0.141,0.4706549303117889,3.2521910790474657,7.995689497608577,19.805847206635335,44.45291414545344,68.30188842539019,85.6039404481166,128.72660222496867,176.05329407720976,190.733,"NaN","NaN","NaN"],[0,0.031171256456182746,0.30215991418612453,0.9700044269821432,1,1],[20,0.141,33,0.5319502292075966,91.62,0.971317616673674,166.48999999999998,1.5996826817801246,155.26999999999998,2.782297806956279,286.35999999999996,4.26857460182025,351.6,5.798136174667266,334.35,7.356706245246346,354.99,8.922438531001136,281.28,10.787517768278676,313.47999999999996,13.49585267835224,407.34,16.375925678219467,451.55,19.88293821062045,469.6600000000001,25.09424047867018,489.6899999999999,28.850131986303307,353.36999999999995,35.98230711610488,493.95,43.46533948454898,159.86,48.07828228248742,439.17,57.460482110912345,357.76,65.49857005532503,289.20000000000005,73.94527097375196,182.49,85.32599861288945,187.44,100.55990043868015,104.86000000000001,121.79772585847088,105.42,140.45257686027523,42.87,190.733,1]]}, +{"name":"random 20","compressions":[33.5,33.5,20],"ops":[{"op":"add","d":0,"values":[[137.98,1],[124.161,1],[425.312,1],[753.971,6.39],[169.024,1],[496.966,1],[165.529,"Infinity"],[523.612,32],[182.168,1],[576.387,5.95],[563.364,1],[975.32,1],[367.976,6.05],[659.213,1],[969.769,1],[917.914,1],[828.991,1],[8.295,1],[29.427,6.5],["NaN",32],[640.749,1],[910.739,1],[471.023,1],[447.747,1],[611.093,1],[461.302,0.99],[390.651,1],[944.686,1],[566.153,5.16],[606.249,32],[29.265,0.95],[660.73,1],[654.834,1],[461.851,32],[553.467,32],[717.871,32],[502.321,32],[27.566,4.029999999999999],[882.051,1],[118.302,"NaN"],[1.054,1],[7.293,1],[491.31,1.41],[253.457,1],[893.835,32],[253.979,32],[433.093,1.8800000000000001],[506.076,1],[151.612,1],[338.463,1],[36.65,1],[339.834,1],[954.687,1],[253.361,32],[23.358,1],[41.582,1],[185.318,32],[44.041,1],[778.648,7.99],[103.551,1],[845.109,1],[728.508,32],["NaN",1],[771.842,"Infinity"],[155.325,1.3800000000000001],[773.721,1],[242.521,1],[239.462,32],[79.586,1],[739.952,32],[425.899,1],[990.667,0],[975.91,8.82],[495.701,1.01],[832.656,1],[953.5,1],[606.75,1],[254.808,1],[882.39,32],[677.878,0.3],[340.809,32],[708.287,1],[792.101,1],[828.492,32],[647.193,1],[249.57,32],[21.235,32],[162.738,9.56],[346.783,32],[164.82,32],[366.019,1],[147.729,32],[948.838,1],[70.508,1.56],[640.123,3.7699999999999996],[440.254,1],[356.404,1],[847.372,32],[379.644,8.379999999999999],[638.257,1],[706.405,1],[266.664,1],[295.319,1],[570.47,1],[697.486,1],[361.741,2.01],[102.117,6.16],[250.593,1],[309.697,32],[74.979,3.1799999999999997],[539.798,1],[372.395,1],[577.517,1],[330.784,32],[151.634,1],[354.073,3.69],[31.123,1],[378.941,9.41],[433.997,1],[326.831,1],[399.312,6.71],[487.581,32],[859.725,32],[301.23,32],[794.139,0.26],[615.773,1],[431.139,3.3099999999999996],[222.09,8.08],[417.602,1],[985.616,1],[457.219,8.379999999999999],[253.227,7.92],[866.453,1],[840.068,7.54],[329.543,1],[341.971,1],[568.903,32],[928.635,1],[56.112,7.91],[968.417,1],[202.737,9.16],[349.005,-1],[744.853,1],[151.301,1],[899.195,32],[854.295,32],[577.068,32],[554.927,1],[941.916,1.92],[370.354,1],[319.198,1],[537.969,-1],[677.512,1.27],[568.358,9.03],[19.039,1],[747.518,1],[634.843,1],[299.876,1],[263.721,7.77],[245.159,1],[490.844,1],[222.157,5.99],[818.136,32],[951.168,1],[436.019,32],[561.902,32],[461.777,1],[2.859,1],[111.314,1],[472.349,5.3999999999999995],[873.664,1],[524.282,1],[631.301,1],[473.003,1],[998.408,32],[446.185,1],[424.138,32],[769.051,1],[46.624,1],[190.503,1],[651.789,1],[217.424,1],[187.512,9],[577.14,1],[578.406,1],[953.701,32],[9.502,"Infinity"],[956.345,1],[252.168,32],[397.925,3.34],[553.974,1],[718.644,1],[556.154,1],[132.255,4.27],[74.201,1],[294.882,32],[998.703,8.97],[540.1,7.56],[473.104,1],[73.69,32],[69.656,32],[452.75,0.32],[856.232,1],[500.893,32],[893.706,1],[503.509,32],[833.375,1],[357.817,"NaN"],[73.174,32],[960.857,32],["NaN",3.55],[174.587,32],[790.38,3.61],[125.614,6.05],[196.464,1],[828.796,32],[892.136,2.32],[151.892,1],[839.743,1],[390.733,1],[648.202,1],[305.672,0.66],[285.404,0.48],[523.87,1],[793.618,32],[824.248,1],[69.431,8.67],[349.106,5.66],[993.172,1],[205.598,1],[267.742,32],[138.866,1],[369.277,6.71],[17.02,32],[956.269,9.27],[414.748,1],[5.33,1],[815.744,32],[703.098,32],[304.51,8.959999999999999],[666.068,8.48],[423.331,1],[201.222,1],[49.002,1.31],[142.182,1],[278.089,32],[751.03,1],[740.541,-1],[770.729,7.84],[127.128,5.55],[928.483,32],[646.706,4.569999999999999],[827.943,1],[992.042,1],[132.845,1],[292.528,4.41],[509.895,1],[445.791,32],[589.445,1.06],[689.035,1],[264.421,6.4399999999999995],[944.08,1],[216.995,32],[916.096,32],[717.01,1],[922.611,1],[389.298,1],[848.451,1],[259.868,2.0199999999999996],[247.927,32],[3.969,1],[279.568,32],[921.383,32],[168.555,1],[36.253,7.3],[644.248,1],[412.378,1],[428.811,"Infinity"],[870.596,1],[556.06,1],[635.128,1],[795.154,1],[177.78,2.28],[262.771,32],[547.276,32],[808.841,1],[359.59,1],[51.696,1],[284.14,1],[262.747,1],[100.48,"NaN"],[258.126,6.31],[519.922,1],[357.619,2.1999999999999997],[435.832,1],[621.408,1],[678.516,32],[667.969,3.11],[948.52,5.63],[962.945,1]]},{"op":"add","d":2,"values":[[524.683,1],[980.227,1],[648.889,32],[393.732,1],[664.75,1],[362.643,9.64],[491.639,1],[812.993,1.8],[329.12,1],[859.608,2.8699999999999997],[734.196,1],[504.226,32],[798.806,32],[799.186,1],[847.126,6.14],[262.434,32],[97.608,8.14],["NaN",32],[745.039,2.1199999999999997],[164.727,1],[743.04,1],[355.207,32],[714.302,1],[384.922,3.9699999999999998],[288.275,8.18],[295.002,1],[948.09,32],[473.766,1],[439.687,3.3099999999999996],[50.649,1],[37.58,32],[797.048,1.37],[60.969,0.23],[277.609,32],[140.903,1.87],[71.95,8.02],[770.352,32],[701.704,1],[406.893,1],[480.907,1],[179.353,1],[275.176,0],[202.013,1],[252.666,2.46],[36.448,1.8],[504.097,1],[388.902,1],[750.651,9.86],[875.537,1],[316.616,5.81],[619.108,32],[929.82,1],[810.867,8.1],[3.014,1],[450.037,"NaN"],[700.267,1],[980.338,32],[919.988,2.09],[762.588,1],[658.637,1],[464.624,1],[298.111,1],[798.731,32],[185.656,32],[884.773,32],[641.149,1],[712.875,1],[554.262,1],[304.582,1.75],[146.763,32],[10.052,7.09],[993.341,32],[909.645,1],[430.029,32],[491.395,0.83],[249.095,1],[620.769,32],[41.899,32],[473.853,1],[440.551,1],[537.073,1],[884.678,"NaN"],[913.917,32],[262.074,8.89],[196.503,1],[249.105,1],[125.855,32],[975.218,2.7899999999999996],[589.013,1],[685.893,4.529999999999999],[292.045,32],[782.837,"NaN"],[266.241,1],[898.157,1],[523.004,"NaN"],[748.189,9.53],[597.193,2.2899999999999996],[243.652,32],[752.329,1],[504.057,0.03],[662.165,32],[197.219,32],[854.625,4.9799999999999995],[669.2,4.529999999999999],[710.144,0.36],[741.359,1.82],[214.216,32],[552.839,8.65],["NaN",1],[462.058,9.24],[741.093,1],[378.935,32],[988.649,3.73],[348.283,1],[877.958,1],[59.793,1],[866.396,32],[853.484,32],[908.116,32],[849.718,2.6399999999999997],[458.872,32],[242.786,32],[406.609,32],[718.702,1],[897.502,1],[216.219,3.1999999999999997],[405.034,32],[546.746,1],[742.306,1],[16.671,1],[514.075,1],[446.566,1],[890.667,32],[869.243,32],[618.28,1],[357.684,1],[145.944,0],[47.779,32],[482.023,1],[502.487,32],[471.73,32],[487.823,1],[166.067,1],[519.378,32],[848.453,1],[742.292,1],[990.977,1],[0.479,1],[391.312,1],[58.194,4.58],[214.746,1],[544.796,32],[475.696,"Infinity"],[630.064,1],[351.366,32],[486.036,1],[511.137,1],[227.581,1],[13.405,1],[326.535,"Infinity"],[729.452,32],[79.658,4.77],[735.563,32],[470.187,1],[423.208,1],[568.345,9.74],[118.206,1],[993.008,32],[947.092,1],[908.663,9.129999999999999],[807.978,32],[250.722,3.03],["NaN",32],[739.182,3.9299999999999997],[326.652,1],[157.767,7.91],[122.074,32],[246.628,5.02],[769.487,1],[243.832,9.24],[952.97,32],[429.049,1],[591.97,32],[664.266,32],[404.12,1],[398.349,1],[392.293,32],[312.012,1],[207.413,1],[767.519,1],[142.376,1],[129.224,1],[983.443,1],[874.817,2.4899999999999998],[528.073,32],[105.946,1],[154.824,32],[49.961,1],[144.653,0.63],[715.224,1],[61.137,0.58],[108.627,1],[326.308,1],[633.562,1],[814.035,1],[644.693,32],[941.653,"NaN"],[121.238,1.98],[694.889,32],[393.272,1],[487.548,1],[59.415,2.51],[200.361,6.34],[186.87,6.75],[258.58,"Infinity"],[693.116,1],[288.423,1],[460.275,0.18000000000000002],[844.82,1],[205.67,32],[478.13,32],[851.641,1],[915.292,1],[171.111,1],[97.269,32],[737.962,1],[786.798,32],[301.991,32],[888.345,0.43],[410.649,9.12],[598.732,3.5199999999999996],[367.964,0.62],[552.563,32],[302.045,0.73],[317.647,32],[322.367,0.27],[905.448,1],[852.405,1],[122.224,32],[707.643,1],[697.319,32],[17.5,1],[540.853,4.43],[837.362,32],[600.475,1],[782.49,3.0399999999999996],[762.23,0.97],[228.585,32],[592.914,7.1499999999999995],[253.757,1],[876.53,3.3099999999999996],[154.345,1],[602.296,1],[243.657,1],[437.29,1],[323.261,1],[258.839,"Infinity"],[441.989,6.529999999999999],[819.418,1],[394.007,1],[134.725,9.82],[905.972,1],[607.484,32],[912.802,1],[380.222,1],[347.046,32],[478.377,6.18],[911.882,1],[860.621,1],[503.293,0.38],[190.849,1],[675.9,32],[844.419,1],[234.374,1],[290.253,1],[671.771,1],[826.013,1.54],[801.496,9.47],[416.293,1],[883.473,6.18],[581.739,1],[375.058,1],[508.157,32],[178.34,1.16],[807.115,1],[958.398,-1],[671.894,9.1],[380.492,32],[41.027,1],[424.676,32],[448.511,6.09],[758.256,7.72],[292.621,32],[759.732,1],[831.633,32],[71.509,1],[635.748,32],[97.73,5.37],[5.475,1],[311.195,1],[145.371,1],[367.8,32],[835.544,1],[600.115,1],[84.937,32],[813.83,1],[453.831,1],[590.665,"NaN"],[175.683,1],[756.779,32],[19.242,1],[801.801,1],[79.677,32],[581.84,1],[650.175,0.73],[295.307,0],[170.489,1],[347.842,1],[771.029,1],[560.923,1],[901.95,1],[914.011,32],[70.909,5.76],["NaN",1],[964.888,1],[286.766,1],[608.319,1],[649.242,1.84],[631.015,9.79],[997.48,1],[482.319,2.17],[396.448,32],["NaN",1],[206.419,1],[128.097,1],[869.942,0.33],[667.273,1],[650.452,32],[574.963,32],[433.267,1],[337.18,1],[836.881,1],[891.734,8.82],[828.229,6.18],[509.506,1],[834.729,1],[654.176,1],[248.713,1],[451.066,32],[406.774,32],[693.657,3.96],[917.075,"Infinity"],[563.955,1],[584.769,1],[836.714,32],[362.181,5.93],[59.496,1],[117.528,32],[857.21,1],[177.893,1],[855.479,32],[172.616,32],[914.333,1],[559.884,1],[387.347,"NaN"],[938.165,32],[296.919,1],[316.303,1],[679.098,1],[129.592,1],[453.005,0.14],[465.663,32],[666.392,1],[88.781,4.29],[176.191,1],[583.558,2.2699999999999996],[771.744,1],[443.775,32],[415.579,-1],[602.26,1],[374.022,9.12],[682.413,5.4399999999999995],[785.611,1],[619.614,1],[878.971,32],[1.456,1],[751.646,1],[548.298,1],[578.596,1],[740.577,1],[75.021,1],["NaN",5.18],[627.649,9.48],[158.573,"NaN"],[849.771,32],[805.159,1],[186.336,32],[565.669,1],[373.72,1],[457.122,1],[59.677,1],[226.682,1],[789.972,1],[406.935,32],[538.895,1],[600.764,32],[601.365,0.35000000000000003],[715.771,1],[758.629,32],[343.885,32],[711.567,32],[577.819,"NaN"],[805.573,1],[148.554,1],[971.908,1],[60.499,1],[746.895,1],[671.081,1],[94.25,1],[702.529,4.58],[689.704,1],[421.272,1],[366.675,1],[621.888,32],[294.99,32],[264.253,0.51],[810.997,1],[791.879,32],[902.073,3.4299999999999997],[607.87,6.99],[108.948,32],[400.964,2.2899999999999996],[892.075,32],[530.352,1],[380.877,1],[204.017,5.75],[345.224,5.74],[680.738,1],[554.004,1],[141.595,2.75],[409.461,3.4899999999999998],[316.191,1],[593.478,1],[166.528,32],[90.546,8.19],[214.234,-1],[804.305,1],[495.163,1],[356.237,3.4],[331.186,1],["NaN",-1],[686.313,1],[306.165,1],[821.606,32],[876.192,32],[515.098,1],[223.56,0.68],[842.84,32],[515.933,1],[614.528,1],[640.393,32],[23.49,1],[734.424,1],[568.352,6.92],[287.95,32],[546.305,1],[951.945,7.1499999999999995],[144.483,1],[479.798,8.629999999999999],[653.608,3.3499999999999996],[370.464,1],[163.54,8.299999999999999],[464.271,32],[598.603,"Infinity"],[357.577,32],[913.43,1],[232.634,2.73],[91.954,8.34],[484.19,32],[945.1,1],[129.314,1],[49.441,2.9099999999999997],[414.587,1],[229.509,1],["NaN",32],[843.697,1],[890.901,1],[435.586,7.22],[196.187,1],[470.198,32],[577.224,32],[893.769,"Infinity"],[950.002,32],[846.997,"NaN"],[706.807,1],[602.106,"Infinity"],[619.616,1],[625.264,32],[961.516,1],[853.152,2.94],[446.092,1],[759.259,1],[259.84,1],[635.002,9.379999999999999],[563.145,9.49],["NaN",1],[843.255,1],[499.828,32],[179.284,1],[842.917,1],[922.556,5.68],[736.205,1],[751.231,1.89],[336.662,4.17],[862.18,1],[616.218,32],[896.034,1],[285.826,32],[368.253,1],[895.194,4.76],[852.635,8.69],[169.048,1.69],[788.264,"NaN"],[974.922,1],[992.431,1],[30.07,1],[289.083,3.6999999999999997],[584.785,1],[131.739,1],[864.941,1],[567.682,32],[123.991,32],[545.095,32],[852.112,1],[476.283,32],[440.885,1],[536.605,0.17],[528.214,7.67],[995.702,1],[674.457,3.4299999999999997],[960.518,0],[407.207,6.02],[416.466,7.319999999999999],[440.401,1],[926.948,1],[956.477,32],[750.475,7.319999999999999],[470.739,1.8],[537.253,1],[540.455,32],[444.266,1],[726.635,1],[270.327,8.52],[725.272,8.97],[529.448,32],[320.021,1],[426.099,7.95],[291.064,32],[37.291,1],[194.235,32],[716.17,32],[452.127,7.71],[986.436,1],[445.976,1],[377.219,1],[612.525,1],[816.313,2.01],[762.566,"NaN"],[167.714,1],[343.683,1],[749.424,32],[966.022,32],[551.233,1],[741.217,1],[978.144,1],[636.861,6.55],[20.486,9.43],[561.246,1],[96.098,1],[76.016,1],[917.683,6.4799999999999995],[16.119,32],[470.988,5.529999999999999],[158.122,1],[532.59,1],[353.804,32],[173.164,3.63],[820.329,-1],[536.561,1],[793.213,8.09],[231.357,1],[964.681,1],[208.07,32],[689.124,2.94],[796.147,-1],[366.715,1],[250.74,6.02],[117.832,0],[746.255,-1],[547.359,1],[968.306,2.8499999999999996],[248.39,32],[824.732,3.3],[718.087,1],[293.42,32],[872.146,1],[808.625,0.39],[36.953,0.78],[851.049,1],[688.89,"Infinity"],[309.42,1],[223.517,32],[902.086,0.87],[578.909,2.21],[860.008,32],[208.079,32],[494.762,1],[695.451,1],[240.774,8.59],[271.615,0],[488.223,1],[383.655,"Infinity"],[122.212,1],[191.754,2.3299999999999996],[962.797,32],[523.874,1],[92.501,1],[688.143,1],[989.944,32],[843.577,1.84],[202.986,1],[884.335,32],[411.599,32],[309.464,1],[412.701,8.26],[838.861,3.59],[683.21,5.6499999999999995],[398.996,2.67],[783.019,1],[764.217,3.4699999999999998],[665.404,1],[534.168,1],[359.076,1],[703.454,"NaN"],[878.912,3.6999999999999997],[437.598,1],[875.176,1],[465.43,1],[309.617,32],[816.929,32],[538.02,7.64],[298.755,1],[356.747,32],[608.623,32],[62.732,1],[997.782,9.54],[207.88,"NaN"],[54.314,6.55],[917.158,4.6499999999999995],[840.362,1],[559.569,6.9399999999999995],[703.285,7.46],[358.534,1],[122.878,3.32],[818.853,1],[563.069,1],[127.072,32],[328.393,7.279999999999999],[387.539,1],[657.072,1.36],[37.49,9.36],[706.888,1],[633.848,1],[539.659,1],[6.653,1],[731.578,2.34],[823.577,4.029999999999999],[829.275,8.97],[386.719,32],[695.733,1],[122.83,1],[93.041,"Infinity"],[914.338,1],[993.92,0],[615.772,0],[937.194,1],[127.82,32],[282.243,6.6],[841.045,1],[841.497,1],[433.133,1],[752.078,0],[237.893,1],[951.108,1],[486.783,6.97],[730.408,1],[168.901,4.1],[408.457,32],[808.644,1],[567.256,1],[572.1,0.68],[158.916,2.5999999999999996],[766.477,32],[902.966,32],[325.392,1],[670.666,1],[798.577,7.93],[815.847,9.59],[913.428,1],[700.58,1],[558.839,1],[332.843,1],[89.689,1],[837.075,1],[454.491,9.459999999999999],[614.76,1],[337.857,32],[740.809,32],[324.202,32],[818.27,32],[60.726,1],[545.58,1],[911.303,1],[736.941,1],[328.827,32],[811.199,1],[294.211,1],[349.953,3.8899999999999997],[255.174,1],[832.508,1],[975.146,6.38],["NaN",32],[466.765,1],[863.719,1],[732.921,1],[875.736,1],[516.796,1],[231.934,7.359999999999999],[723.201,32],[871.841,1],[384.286,4.63],[616.435,32],[35.038,1],[736.216,1],[292.467,32],[531.176,1],[262.375,1],[958.275,1],[52.167,1],[800.496,32],[367.524,9.299999999999999],[873.389,1],[18.495,1],[262.395,1],[230.918,1],[861.489,32],[338.789,1],[996.173,2.2199999999999998],[9.324,1],[480.236,1],[370.889,1],[368.744,32],[794.436,1],[789.744,32],[937.306,32],[169.882,32],[316.076,1.8],[258.557,4.4399999999999995],[779.131,1],[484.426,2.82],[336.439,1],[52.745,"NaN"],[299.119,1],[705.034,1],[188.078,1],[277.144,1],[942.137,3.01],[194.527,32],[241.001,1],[325.719,1.5],[709.487,32],[885.164,32],[459.151,1],[189.744,1],[241.261,8.379999999999999],[680.034,5.64],[270.953,1],[715.613,1],[41.47,-1],[252.002,32],[799.129,1.62],[522.78,32],[641.54,32],[956.632,0],[317.902,8.79],[146.762,1],[909.971,1],[534.372,0.91],[62.408,1],[980.348,1],[880.618,"NaN"],[881.718,1],[718.879,32],[136.026,4.39],[87.695,5.24],[475.456,-1],[448.954,32],[779.743,32],[61.747,7.1499999999999995],[561.157,1],["NaN",3.32],[9.479,7.31],[436.232,0.09],[226.742,1],[121.576,1],[265.764,1],[658.328,1],[549.031,2.6399999999999997],[85.615,1],[277.071,9.24],[795.85,1.05],[245.911,6.39],[343.965,1],[612.355,1],[323.811,32],[481.767,1],[692.332,6.3],[22.798,1.64],[965.834,1],[991.459,32],[908.194,1],[175.206,1],[290.768,1],[603.9,1],[319.206,32],[683.46,32],[71.992,32],[743.028,32],[845.303,1],[314.717,32],[628.286,1],[791.809,32],[975.674,32],[634.761,1],[686.392,4.77],["NaN",4.72],[183.098,32],[919.477,6.77],[933.945,1],[406.018,1]]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"add","d":0,"values":[[118.426,32],[802.505,8.709999999999999],[245.438,5.14],[868.857,"NaN"],[33.798,1.23]]},{"op":"add","d":0,"values":[[296.86,1],[594.197,1],[227.661,4.4799999999999995],[720.018,1],[1.255,1],[322.15,1],[510.517,0],[237.442,1],[269.733,1],[105.945,1.69],[978.865,4.39],[461.461,32],[162.717,1],[521.153,3.0999999999999996],[773.01,1],[756.774,1],[104.426,1],[999.05,4.72],[796.09,1],[186.208,1],[968.365,1],[338.049,1],[168.625,1],[740.936,1],[65.897,32],[109.887,1],[347.789,1],[686.98,-1],[443.588,3.8299999999999996],[680.248,1],[106.748,32],[19.029,1],[713.815,4.779999999999999],[985.534,32],[188.848,"Infinity"],[529.654,4.75],[521.727,0.84],[804.982,1],[105.253,3.09],[571.934,-1],[693.787,1],[616.505,1],[663.417,1],[4.073,32],[699.771,32],[654.149,0],[869.163,32],[715.896,32],[300.266,1],[142.772,8.97],[689.175,1],[875.651,1],[27.92,1],[951.009,1],[14.611,1],[587.084,9.76],[114.166,"Infinity"],[688.533,-1],[415.468,1],[806.379,1],[315.34,32],[731.32,32],[492.792,1],[940.85,1],[498.098,32],[918.366,1],[7.593,1],[397.906,1],[252.389,32],[352.4,1],[561.023,1],[6.505,"NaN"],[143.413,1],[920.31,1],[298.596,1],[192.587,1],[583.057,1],[757.782,1],[234.956,1],[733.556,1],[538.129,0],[555.144,1],[327.759,32],[392.109,1],[613.552,1],[236.996,1],[385.798,32],[674.267,0.89],[262.565,1],[518.885,9.379999999999999],[590.009,1],[807.066,1],[961.426,32],[618.99,1],[801.84,1],[519.304,1],[137.414,1],[788.025,1],[788.777,1],[577.431,8.47],[781.387,1.96],["NaN",1],[781.221,1],[337.785,2],[773.338,32],[803.643,1],[452.38,1],[437.173,3.1799999999999997],[503.6,4.74],[549.172,1],[919.207,32],[881.388,1],[394.051,1],[231.233,1],[586.151,32],[149.67,32],[691.914,6.13],[587.149,1],[9.209,1],[380.342,1],[313.173,1],[443.425,1],[814.456,1],[481.381,2.32],[341.975,32],[458.783,32],[358.25,1.11],[625.687,1],[586.951,3.46],[452.601,2.9699999999999998],[829.819,1],[18.324,1],[763.969,0],[777.322,1],[23.543,1],[708.668,9.77],[33.676,1],[337.718,1],[325.329,5.66],[400.396,32],[259.644,1],[750.793,1],[860.801,1],[368.78,1],[576.611,32],[439.678,32],[87.603,1],[788.808,32],[210.959,2.55],[949.755,4.95],[742.168,1],[548.765,32],[955.039,2.1599999999999997],[883.091,1],[897.764,1],[524.636,1.99],[479.284,8.379999999999999],[612.163,1],[118.291,-1],[288.698,0.24000000000000002],[562.956,1],[285.467,1],[139.944,1],[147.247,1],[500.017,"NaN"],[122.931,1],[366.721,0.97],[292.092,1.83],[841.617,1],[814.015,-1],[421.327,32],[300.691,1],[78.021,32],[852.115,1.98],[2.854,1],[929.562,32],[366.768,32],[623.847,32],[193.066,1],[39.31,1],[203.959,1],[529.629,3.9499999999999997],[868.101,1],[187.281,1],[747.514,2.03],[537.563,1],[931.091,1],[678.588,5.33],[840.248,32],[308.598,9.24],[393.017,7.37],[347.59,32],[468.089,1],[493.314,32],[481.73,1],[582.255,32],[674.751,1],[321.063,32],[858.941,1],[57.898,0.68],[208.98,3.1399999999999997],[973.589,32],[815.975,1],[703.832,32],[591.371,1],[82.036,1],[158.656,5.58],[600.845,4.72],[186.208,1],[820.369,6.71],[328.343,8.26],[470.474,1],[862.933,1],[869.8,9.95],[344.206,2.8099999999999996],[195.15,1],[146.953,1],[272.46,1],[987.286,1],[9.863,32],[106.374,1],[819.073,1],[771.79,8.59],[355.666,3.67],[144.997,1],[755.738,32],[477.943,1],[361.123,0.06999999999999999],["NaN",1],[911.664,1],[933.834,1],[591.173,1],[523.127,1],[353.257,1],[41.2,1],[558.169,1],[92.245,1],[855.026,1],[730.933,-1],[744.451,1],[392.274,1],[825.585,0.88],[875.845,1],[778.007,1],[713.246,1],[46.397,1],[467.833,9.47],[431.592,1],[404.135,1],[197.487,1],[404.446,"Infinity"],[645.989,1],[460.558,1],[830.282,0.26],[378.035,-1],[628.351,32],[165.925,7.859999999999999],[756.199,32],[299.644,8.459999999999999],[448.589,2.9299999999999997],[949.213,1],[155.544,1],["NaN",1],[12.426,2.8099999999999996],[373.728,7.02],[781.492,32],[116.967,0.78],[406.025,5.7],[327.757,1],[271.135,1],[600.236,1],[835.082,1],[261.441,1],[737.361,0],[279.015,2.5399999999999996],[302.593,0.9400000000000001],[327.684,1],[490.881,1],[508.076,0],[804.544,1],[496.004,2.25],[495.632,32],[876.557,0.5700000000000001],[627.543,1],[563.535,"Infinity"],[645.069,1],[905.755,6.8999999999999995],[319.819,32],[559.513,1],[673.522,3.3099999999999996],[757.768,32],[287.71,32],[292.464,32],[854.911,0.9],[105.448,1],[166.24,1],[950.78,"NaN"],[765.076,32],[989.171,1],[645.605,9.41],[75.762,1],[467.063,"NaN"],[930.805,1],[818.899,4.47],[202.792,1],[92.791,6.3],[366.98,3.2399999999999998],[570.255,1],[496.775,1],[669.258,6.91],[162.215,32],[387.864,32],[996.955,4.33],[427.208,32],[909.044,1],[388.998,9.709999999999999],[345.732,1.42],[406.713,1],[771.494,2.05],[895.091,9.75],[473.343,1],[21.356,5.3],[510.563,1],[401.284,1],[564.58,0.35000000000000003],[202.744,1],[388.53,32],[602.324,6.42],[245.162,1],[758.561,7.63],[585.393,1],[240.523,5.859999999999999],[837.986,1],[806.618,1],[786.217,4.29],[791.924,1],[468.288,"NaN"],[979.062,32],[292.429,32],[92.258,1],[934.274,32],[26.834,32],[544.842,32],[97.012,1],[644.209,1],[584.487,32],[771.906,1],[497.723,1],[720.62,1.47],[503.367,9.57],[803.236,"NaN"],[364.648,1],[196.722,1],[528.977,32],[591.648,1],[761.618,1],[713.689,1],[737.057,1],[959.636,8.09],[182.43,1],[147.945,1],[458.153,8.51],[319.964,1],[470.682,8.44],[409.337,1],[203.866,1],[93.856,1],[171.159,1],[959.241,1],[958.502,"Infinity"],[245.858,1],[483.207,1],[224.891,32],[174.987,5.41],[393.215,1],[63.765,1],[824.422,1],[688.986,3.42],[711.695,7.17],[218.109,1],[120.75,32],[967.551,6.47],[394.438,1.2],[113.668,1],[935.185,4.74],[786.901,1],[669.736,1],[657.608,32],[474.127,1],[938.294,1],[891.517,3.26],[738.085,1],[647.495,1.39],[697.376,1],[124.885,32],[164.217,32],[543.152,32],[258.261,1],[207.033,1],[583.139,1],["NaN",1],[427.166,4.88],[136.52,1],[16.452,1],[93.561,1],[908.637,7.39],[552.749,1],[120.144,1],[642.907,32],[806.07,1],[833.33,1],[604.206,1.46],[31.579,1],[869.936,2.9899999999999998],[646.134,1],[294.913,1],[366.938,1],[519.255,32],[269.734,1],[707.571,1],[3.603,32],[236.526,1],[210.368,-1],[368.929,1],[592.327,32],[722.863,1],[253.691,4.569999999999999],[725.593,32],[477.076,5.529999999999999],[139.28,"NaN"],[589.704,1],[958.15,5.029999999999999],[457.589,1],[827.965,-1],[408.693,7.2],[396.666,32],[52.335,"Infinity"],[205.954,1],[284.747,1],[498.287,1],[337.341,32],[561.603,1],[283.197,-1],[652.705,0],[146.853,1],[919.666,32],[674.97,7.04],[676.491,32],[580.75,32],[814.625,9.51],[131.122,0.06999999999999999],[289.558,9.03],[391.349,32],[622.099,7.91],[843.155,2.67],[140.49,1],[603.606,4.529999999999999],[448.923,1],[549.341,"NaN"],[549.323,1],[598.174,32],[623.448,1],[467.397,1],[771.905,1],[194.608,32],[393.086,32],[594.713,1.93],[866.211,32],[781.554,3.0799999999999996],[27.072,32],[106.228,1],[255.303,1],[420.001,32],[505.587,1],[608.937,7.5],[843.077,32],[846.728,32],[677.242,1],[726.171,32],[149.609,0.8],[844.027,1],[487.721,1],[806.416,1],[236.684,1],[939.306,32],[8.212,32],[269.25,1],[948.509,1],[832.026,1],[211.142,1],[500.877,3.5599999999999996],[443.67,1.8],[193.565,6.01],[833.354,1.12],[922.787,1],[256.001,4.8],[160.53,7.96],[99.645,32],[115.945,32],[492.071,1],[711.416,1],[754.248,1],[779.153,1],[165.801,32],[271.661,32],[785.789,6],[809.791,32],[612.121,1],[985.013,32],[877.117,-1],[876.252,1],[127.198,6.66],[87.852,1],[221.755,4.22],[333.405,1],[913.434,1],[23.34,1],[722.04,1],[176.666,1],[471.476,2.7699999999999996],[690.755,32],[173.451,32],[863.42,2.4],[606.768,1],[688.873,1],[806.794,1],[297.541,1],[161.466,1],[39.745,1],[563.752,1],[526.243,32],[554.081,32],[169.54,32],[536.848,"NaN"],[828.518,9.43],[962.098,5.67],[348.518,1.39],[181.712,1.31],[105.805,1],[63.087,1],[475.739,32],[255.721,5.5],[949.511,1],[800.765,4.029999999999999],[66.618,1],[841.399,1],[452.21,1],[666.419,1],[206.205,1],[859.32,1],[21.203,8.01],[631.001,1],[637.173,1],[125.394,1],[963.05,1.36],[332.171,1],[799.636,1],[519.169,9.06],[710.242,1],[554.073,1.69],[97.966,1.12],[335.033,32],[255.09,1],[85.9,32],[408.239,5.81],[664.569,7.62],[336.034,1],[913.487,1],[492.529,32],[418.468,9.09],[385.065,1],[196.214,1],[652.922,1],[663.119,1],[854.119,1],[193.473,4.21],[834.621,1],[233.94,1],[699.684,1],[970.433,1],[934.063,1],[406.284,"Infinity"],[674.175,1],[418.076,1],[105.561,3.57],[176.735,6.319999999999999],[675.312,1],[324.563,1],[340.547,1],[711.781,32],[636.112,1],[476.422,1],[773.303,1],[150.243,32],[494.748,1],[387.273,-1],[446.446,3.73],[669.668,1],[818.771,1],[923.375,32],[86.163,1],[232.179,1],[435.584,32],[942.203,1],[739.981,4.02],[516.549,32],[943.85,1],[761.763,4.93],[141.494,5.3999999999999995],[359.641,1],[339.774,1],[173.187,4.09],[897.12,1.83],[843.777,1],[709.668,2.7899999999999996],[584.065,2.9099999999999997],[553.212,9.1],[369.42,1],[471.518,32],[160.357,1],[8.389,32],[833.234,7.38],[773.576,1],[380.083,8.32],[292.62,1],[534.946,1],[411.965,1.46],[784.795,6.08],[484.372,1],[657.688,1],[894.917,1],[799.88,0.03],[942.119,1],[819.476,32],[205.169,0.44],[152.683,0],[899.913,1],[652.32,32],[120.67,32],[996.29,1],[226.598,7.17],[70.643,1],[811.802,1],[257.767,1],[174.605,1],[693.386,-1],[189.18,1],[485.518,1],[971.585,1],[958.841,2.6399999999999997],[476.105,0.8],[310.077,32],[666.728,1.55],[346.689,1],[755.68,2.94],[588.013,1],[777.968,32],[527.76,1],[9.107,9.26],[156.389,0.76],[82.043,1],[969.812,1],[852.635,4.06],[784.991,5.779999999999999],[611.143,3.51],[838.412,"NaN"],[659.612,1],[107.371,1],[872.31,1],[99.937,1],[46.724,32],[158.51,1],[45.691,1],[856.885,4.24],[913.543,32],[698.955,1],[491.056,1],[361.418,1],[775.932,1.57],[675.337,1],[857.968,1],[313.932,-1],[394.224,32],[285.142,32],[342.21,1],[993.922,2.11],[693.622,1],[410.574,1],[497.477,1],[113.315,1],[802.816,32],[799.692,1],[280.948,1],[135.9,1],[152.54,1],[705.878,1],[700.361,1],[567.527,0],[529.901,0.7],[86.818,1],[5.614,32],[251.21,1],[72.59,1],[892.434,32],[209.93,1],[304.187,5.279999999999999],[717.711,1.54],[207.209,32],[61.838,3.7699999999999996],[210.239,1],[814.59,32],[758.874,32],[757.527,1.12],[739.359,1],[300.224,32],[910.417,32],[357.821,1],[799.738,1],[676.335,1],[101.064,32],[224.595,1],[840.073,1],[608.159,1],[559.405,1],[586.481,1],[870.328,32],[212.815,2.5],[788.56,32],[465.934,1],[974.69,6.67],[812.516,1],[412.012,32],[826.034,32],[804.935,1],[609.192,32],[121.673,1],[2.097,-1],[312.664,32],[645.477,1],[416.414,1],[479.344,3.4299999999999997],[493.794,2.1399999999999997],[730.59,1],[642.642,1],[768.834,3.38],[757.778,2.3499999999999996],[948.138,1],[492.527,7.27],[664.209,1],[863.453,32],[688.939,4.45],[273.586,1.72],[996.453,32],[192.368,8.44],[932.921,1],[835.897,1],[170.234,1],[280.108,7.22],[576.695,32],[191.336,1],[81.946,32],[885.23,1],[552.337,0.59],[596.662,1],[468.808,0.59],[239.689,1],[404.872,1],[597.25,9.45],[589.847,1],[7.775,1],[587.988,0.91],[524.662,32],[30.933,1],[981.2,3.53],[13.241,0.85],[716.825,6.75],[70.531,1],[336.68,8.2],["NaN",1],[929.042,7.859999999999999],[495.583,7.6499999999999995],[571.708,5.64],[556.268,32],[847.064,0.09],[639.261,32],[78.19,1],[770.819,32],[1.253,1],[709.286,32],[764.532,1.37],[189.435,1],[497.738,4.609999999999999],[782.314,1],[182.306,9.61],[636.737,1],[245.954,32],[927.785,1],[909.733,6.79],[480.731,1],[965.312,32],[715.296,4.7],[551.928,5.97],[499.781,1],[608.768,1],[667.47,32],[378.892,9.82],[227.989,3.42],[284.023,1],[338.553,1],[971.602,1],[476.343,3.53],[854.874,1],[92.148,1],[870.579,1],[852.84,1],[502.032,1],[762.606,7.7],[552.256,1],[850.533,"NaN"],[426.152,1],[135.412,1],[369.445,4.35],[897.628,9.54],[103.724,7.13],[854.473,9.209999999999999],[584.774,1],[348.235,1],[940.342,3.6999999999999997],["NaN",32],[503.637,32],[36.294,1],[677.946,1],[204.441,1],[886.907,"Infinity"],[814.649,1],[517.398,1.18],[447.977,32],[50.594,1],[933.599,1],[54.086,1],[920.363,1],[877.108,1],[543.115,0.22],[774.975,6.069999999999999],[248.195,1.32],[444.485,32],[139.463,0],[331.678,"NaN"],[286.274,32],[398.698,32]]},{"op":"add","d":1,"values":[[969559,"NaN"],[-129756.5,1],[656548.9,4.84],[-370534.1,8.68],[749674.9,1],[-588803.6,0],[-778958.5,1],[-769555.9,32],[929118.7,3.8499999999999996],[452190.6,1],[43306.3,"NaN"],[984153.8,1],[-84338.3,1],[-97157,1],[66715.3,2.67],[329229.3,9.33],[582499,8.82],[-711785.4,32],[133217.5,32],[242162.9,32],[741321.2,1],[117830.3,1],[-76237.5,1],[643020.2,7.08],[554372.5,32],[-78926.3,32],[638302.4,32],[318849.6,1],[-298482,1],[558534.2,1],[220301.9,0.21000000000000002],[-783364.9,9.08],[114976.5,6.58],[143950.1,1],["NaN",1.61],[-199525.1,32],[-722475.2,32],[736053.8,1],[409148,1],[-150790.8,32],[-845994.7,8.66],[-839517,1],[734856.3,1],[535047.5,1],[258666.2,1],[-175101.8,1],[184363.3,1],[414811.6,32],[836083.2,1],[-480394.4,1],[-949037.1,1],[-38478.2,1],[-330835.7,32],[-655708.8,1],[-405580.9,1],[570720.4,9.459999999999999],[-523578.9,6.85],[-424685.5,1],[420643.2,1],[301226.8,32],[998350.9,1],[-814583.6,"NaN"],[-520408.9,1],[201666.2,1],[-498681.5,5.069999999999999],[-629306.3,"NaN"],[-690840.1,1],[-906866.5,1],[-114132.3,32],[101386.3,32],[944203.5,1],[-8513.1,1],[-366058,6.77],[768428.7,1],[-943695.5,2.28],[-203389,1],[-892383.8,32],[62136.5,1],[-857497.2,6.39],[-139012.9,8.799999999999999],[233273.6,1],[145994.5,32],[-836712.9,1],[-742477,9.879999999999999],[-421133.4,1],[656305.7,32],[987252.9,"Infinity"],[798063.9,1],[8836.7,1],[271769.6,1],[716762.7,1],[11903.4,1],[78074.9,1],[-247449.1,8.58],[162890.1,1],[960711.2,1],[-483885.3,1],[-905824.6,1],[380467,1],[240001.6,32],[483037.8,1],[-634643.7,1],[792540.1,8.82],[-360099.5,1],[-458021.1,1],[-1819.3,4.529999999999999],[48207.2,1],[-24798.1,32],[-871860.8,32],[-134991.5,1],[707537.4,1],[-351601.1,5.24],[-131527.4,1],[658066.3,1],[211562.4,32],[473712.9,1],[842614,-1],[-505769.6,5.7],[585199.5,32],[66073,1],[-453061.4,1],[340239.1,8.1],[-854196.8,1],[-705456.6,1],[-516121.5,1],[-835713,1],[64984.1,1],[658020.6,1],[884712.1,1],[-968226,32],[-382166.6,1],[-436080.9,1],[-385361.2,2.69],[588851.9,1],[-786977.4,1],[-233406.6,7.6899999999999995],[-48264,1],[-5134.5,1],[-72146.9,8.12],[-917770.1,32],[80739,1],[901420.7,1],[464286.6,"Infinity"],[622087,2.0199999999999996],[-731846.2,0],[629325.5,3.61],[-879307.4,2.57],[605349.6,1],[-396529.4,1],[-100398.2,2.3499999999999996],[-113856.5,32],[-816203.5,1],[277558.2,0],[-530639.9,1],[278571.3,32],[-302609.1,6.25],[-988898.8,32],[346769,1],[2422.9,1],[621094.8,6.79],[-438303.5,32],[792444.2,1],[-561996.3,"NaN"],[552675.8,6.52],[129032.6,32],[474109.1,1],[-412122.7,7.84],[-927947.5,1],[442791.1,"NaN"],[730914.1,1],[519220.7,1],[-136958.9,1],[110491.6,4.54],[941585,32],[-83257,32],[390439.4,1],[-821091.3,1],[-613117.2,1],[-525533.7,-1],[-710704.3,1],[-912799.8,1],[-175977.2,32],[-497431.3,1],[538208.4,1],[-96699.7,-1],[500636.4,32],[134674.4,1],[-445858.9,0.9400000000000001],[484768.2,32],[915358,1],[340192.7,32],[-233302.6,3.23],[-482029.9,8.36],[384020.3,4.21],[-984911.7,32],[-680429.3,1],[-96405.2,1],[754602.7,1],[940601.6,5.569999999999999],[720531.5,1],[-837494.7,32],[160412.1,32],[499581.1,32],[-983312.7,6.74],[-833947.2,1],[-905994.5,1],[-2319.3,1],[-440211.4,1.74],[83618.8,1],[340672.3,1],[-23586,1],[-491357.9,1],[-63153.1,1],[979433,1],[213318.7,32],[-250382,8.6],[282735.9,1],[724570.8,32],[-539426.5,32],[825149.4,32],[638972.1,1],[-474452.4,3.4699999999999998],[-361641.6,1],[-933927.2,0],[986510.7,0.85],[946556.2,32],[307422.5,32],[-357022,32],[793347.6,"NaN"],[827002.3,32],[-648404.6,1],[-612918.8,1],[-788886.8,"NaN"],[-813209.3,1],[-491036.2,-1],[-766486.1,1],[97242.2,1],[282979.2,1],[-835869,32],[-2387.6,1],[480169.6,32],[283288.9,32],[-359698.7,1],[-707895.3,1],[-912371.2,1],[-82459.6,1],[276476.2,32],[130103.3,1],[755491.9,1],[530546,1],[801314.6,1],[759221.2,1],[-864764.5,1],[-372964.2,1],[-429910.6,4.55],[712981.9,32],[-350917.6,1],[443088.9,1],[516482.7,1],[767790.2,1],[-844719.1,1],[641452.3,1],[-998766,1],[470644.6,1],[676115.6,1],[-461837.4,"Infinity"],[-517366.1,1],[-307690.3,1],[-742347.4,9.709999999999999],[-158615.3,8.49],[-28400.3,1],[-818330.6,8.07],[-198423.8,1],[-510390.7,1],[-948979.7,1],[-912879.4,1],[354881.4,1],[-962860.9,2.51],[-223207.7,8.28],[709513.1,1],[-948944.2,1],[232591.4,9.52],[809930.7,32],[-633832.4,1],[-515110.6,1],[805521.5,1],[-466836.4,1],[-773091.1,1],[-456337.2,32],[-851375.9,1],[432498.7,3.5599999999999996],[-899953.1,32],[-184184.9,1],[794096.4,6.37],[231591.8,5.62],[-56636.5,32],[-462083.9,32],[661218.3,32],[101540,1],[-851526.1,4.68]]},{"op":"merge","d":0,"from":1},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,[0,0,0,0,0,0],null,null,null,null,11214.54,[-998766,-992358.575206788,-912932.4385950055,-60298.41669435968,209.47138670943858,502.4383262090304,819.4000859289059,139620.04514311382,479719.2566619256,853537.7807387516,964928.1671241224,981687.2154639176,"NaN","NaN","NaN"],[0.12325298524366385,0.12325337087543528,0.12325684156137805,0.17431746529737044,0.49783245160189993,0.8783489446285215],[33.5,-998766,1,-988898.8,32,-970850.7898296334,38.74,-913405.1719634471,78.78999999999999,-873615.376516977,91.3,-802133.7028723554,142.74,-613767.1915257663,148.45,-453662.1915130324,188.76,-246874.883900868,254.61,-66594.60082318496,235.67000000000002,14.906726487693119,340.46000000000004,71.78359428741446,336.1,105.29416183607748,220.46999999999997,137.50234230145867,246.79999999999998,167.97953588209114,202.19,193.19919327956984,297.6,240.3760248642903,263.43,260.29453055037317,214.39999999999998,288.6858136748833,362.27,314.15025695945945,295.99999999999994,339.28977716297794,218.67999999999998,379.8776641282669,386.07,416.33035279548795,407.8,458.31419500640214,390.49999999999983,501.5562844476278,404.89,535.7269088030741,369.53000000000003,571.4706479981787,307.47,602.2748469793116,387.65999999999997,662.405803420535,345.55999999999995,707.4301262306409,347.38,747.4373793415582,298.28,777.1246950818664,325.53,811.2606373987074,292.47,837.4424976935951,244.97000000000003,861.0383700088374,248.94,905.2446170191314,396.73,942.8981266901388,337.99,982.230340359411,296.04,159270.2409447905,258.47,270364.47602040815,196,413516.362949827,231.2,557744.8425647926,141.22,666526.4362879399,148.92000000000002,784832.0612668744,125.19,891262.8029456772,78.42,946556.2,32,981687.2154639176,4.85],2393.33,[-998766,-997633.7657105455,-988034.9324865625,-866617.9458363537,-455281.57418190734,83703.67560561438,469346.73053104413,724157.4941330639,830795.0873934997,946116.5587933332,981687.2154639176,981687.2154639176,"NaN","NaN","NaN"],[0.47891136298045556,0.4789116149244338,0.4789138824202373,0.4789365573782725,0.4790373349695406,0.4791630550146476],[33.5,-998766,1,-988898.8,32,-984911.7,32,-970850.7898296334,38.74,-922605.1356913871,46.79,-899953.1,32,-891411.6753832804,34.57,-862770.7078794289,56.73,-836398.5705882353,68,-770958.8165373295,74.74,-709203.8706666667,75,-516316.53208985704,73.45,-462083.9,32,-438163.2879679144,89.76,-345348.8899009697,96.94,-219162.55654244887,71.38,-159171.045509329,86.29,-103137.87464582315,102.35,-56636.5,32,-32824.91221871299,101.32000000000001,115138.94753630705,77.12,147480.3495049505,101,216447.3956813939,80.35,253132.0224489796,98,287596.9295918367,98,331490.55097150255,92.63999999999999,447914.7112660944,74.56,492174.65,64,530080.6392577104,76.52,590463.0007882536,64.7,646694.9454844006,73.08,661218.3,32,703459.504470803,43.84,750622.038731819,61.19,809930.7,32,825149.4,32,842628.7225846926,39.85,940601.6,5.569999999999999,941585,32,944203.5,1,946556.2,32,981687.2154639176,4.85],7421.040000000001,[8.738025768087216,10.510293063885797,27.027566564196608,150.65852439654475,299.51230607893933,514.9110226307046,769.462932487659,896.4148372707948,947.79329245251,989.894924661083,997.4317768411674,"NaN","NaN","NaN","NaN"],[0,0,0.0007120676632156325,0.05401502524969358,0.4863972399679355,1],[20,12.105339361702127,28.2,21.855691869774063,56.21,54.16293910084184,167.49,95.20946367374914,233.44,135.80636878956452,312.78000000000003,187.98511918774997,392.49,243.8445583967918,443.86,302.13713493886166,483.33,349.643610180782,540.4300000000001,411.23378665242507,505.55999999999995,466.94274865576654,182.26,496.39902297769146,478.29,564.4388381795196,442.96,622.6536063338325,313.87,670.0999835356688,432.44999999999993,730.7850219172274,518.77,796.907702469571,482.27,842.780271634075,355.91999999999996,878.9801517531045,328.56,913.9345930563916,249.15,950.7361934659912,242.73,982.7230132667805,152.26,992.6456473175023,68.22,997.782,9.54]]}, +{"name":"random 21","compressions":[100],"ops":[{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[0,-1],[6,1],[7,1],[16,5.3999999999999995],[6,1]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[4.291,8.79],[32.131,1],[12.254,1],[42.919,1.44],[57.069,1],[7.271,8.33],[11.453,9.879999999999999],[2.864,0.91],[17.746,1],[18.26,1],[22.122,9.6],[36.29,1],[19.778,32],[1.009,1],[10.767,32],[8.655,1],[33.282,1],[41.755,2.1199999999999997],[27.283,32],[15.984,32],[45.785,32],[41.158,9.549999999999999],[18.136,1],[10.723,1],[42.878,1],["NaN",32],[11.789,1],[57.763,1],[33.33,32],[19.499,1],[43.219,2.76],[14.318,1],[5.451,1],[22.345,1],[7.884,0.56],[11.394,1],[6.53,1],[25.465,4.93],[9.935,3.3],[6.768,1],[32.648,32],[8.523,1],[18.707,32],[38.939,1],[0.68,1],[34.611,1],[86.014,1],[58.143,3.69],[0.191,1],[50.525,4.06]]},{"op":"add","d":0,"values":[[2,6.66],[0,1],[10,1],[5,1],[14,-1],[12,1],[5,1],[7,1],[8,1],[15,1],[14,1],[4,5.18],[19,1],[17,1],[1,1],[4,1],[7,32],[1,0.060000000000000005],[12,32],[0,1],[19,32],[8,1],[6,1],[1,2.1599999999999997],[12,1],[4,1],[19,1],[8,32],[13,"Infinity"],[14,32],[6,4.55],[14,"Infinity"],[14,1],[1,1],[1,1],[3,1],[14,1],["NaN",-1],[16,1],[12,3.7199999999999998],[0,1],[3,1],[12,1],[17,1],[14,1],[16,32],[12,32],[10,1],[10,1.12],[15,2],[12,1],[17,3.8899999999999997],[3,32],[14,32],[15,1],[8,6.2299999999999995],[5,1],[8,4.04],[17,1],[6,1],[12,2.57],[15,1],[14,3.21],[17,1],[0,7.819999999999999],[16,32],[16,1],[3,32],[4,1],[17,32],[3,1],[12,1],[15,1],[5,1],["NaN",32],[11,1],[2,32],[11,1],[12,"Infinity"],[2,1],[19,1],[16,32],[17,32],[8,1],[17,32],[0,1],[6,1],[9,9.95],[9,1],[7,1],[17,8.61],[5,32],[11,1],[9,1],[11,5.97],[9,1],[18,1],[13,1],[12,32],[15,1],[10,6.87],[4,1],[12,1],[13,32],[9,1.21],[14,1],[19,32],[6,"NaN"],[16,1],[10,5.49],[6,1],[11,32],[19,1],[6,1],[12,32],[9,1],[8,1],[17,1],[5,32],[2,0.06999999999999999],[12,7.62],[2,1],[0,3.34],[6,1],[10,1],[13,1],[18,9.26],[13,1],[0,1],[6,4.42],[12,1],[2,7.68],[18,1],[3,32],[6,1],[9,1],[15,6.359999999999999],[4,1],[8,1],[6,1],[15,32],[19,32],[12,1],[17,1],[18,1],[18,1],[3,1],[14,1],[2,1],[2,1],[7,1],[12,1],[3,1],[9,1],[13,1],[10,1],[10,1],[13,1],[7,32],[9,1],[19,1.41],[16,1.6],[11,32],[7,1],[17,5.96],[19,32],[7,1],[19,32],[2,6.279999999999999],[19,1],[13,1],[13,1],[18,1],[10,1],[5,1],[2,1],[2,6.819999999999999],[18,9.36],[15,1],[11,1],[10,3.28],[18,1],[7,1],[7,1],[10,1],[10,1],[18,2.5399999999999996],[9,1],[5,1],[8,32],[6,1],[3,8.74],[4,4.7],[9,1],[19,32],[4,1],[3,0.85],[10,1],[10,1],[11,1],[1,1],[15,32],[15,1],[0,9.92],[6,1],[0,1],[17,4.83],[1,32],[9,0.98],[17,32],[16,7.41],[13,1],[8,32],[9,1],[11,32],[16,1],[7,1],[2,9.97],[6,1],[17,1],[2,1],[9,1],[7,6.9799999999999995],[0,1],[19,4.6],[19,1.57],[5,32],[14,1],["NaN",9.95],[18,1],[16,1],[19,1],[3,32],[7,32],[19,1],[5,1],[13,1],[14,1],["NaN",32],[5,1],[2,1],[3,5.99],[15,8.68],[13,32],[11,9.25],[0,1],[19,1],[11,32],[19,1],[4,32],[8,1],[3,5.77],[17,6.5],[5,1],[19,1],[11,1],[10,32],[9,1],[9,1],[2,5.05],[16,1],[4,1],["NaN",32],[11,1],[14,32],[7,32],[11,1],[1,1],[18,"Infinity"],[3,7.9399999999999995],[17,6.6],[6,32],[11,1.87],[14,1],[18,1.18],[8,32],[15,9.67],[6,1],[15,7.87],[1,1],[13,4.89],[13,8.53],[11,32],[13,1],[1,1],[3,1],[14,32],[9,1],[5,2.42],[2,1],[12,1],[16,4.569999999999999],[9,32],[14,1],[7,1],[6,0],[17,1],[4,1],[1,32],[7,5.2],[19,8.18],[17,1],[3,1],[19,"Infinity"],[15,32],[3,1],[11,2],[19,1],[9,32],[8,3.9299999999999997],[4,32],[17,1],[16,32],[1,1],[18,-1],[11,6.2],[7,7.47],[4,1],[8,2.9099999999999997],[19,1],[14,1],[12,32],[19,1],[8,1],[6,1],[19,1.11],[9,1],[12,7.2],[18,1],[18,1],[12,1],[11,1],[15,1],[12,1],["NaN",1],[6,0],[13,9.15],[11,1],[17,8.85],[0,1],[0,1],[1,1],[17,1],[17,9.72],[0,32],[7,8.86],[7,1],[4,2.7699999999999996],[18,1],[19,32],[1,0.5700000000000001],[13,1],[4,1],[18,1],[8,"Infinity"],[15,1],[13,32],[10,1],[19,1],[3,7.819999999999999],[8,1],[7,1],[17,1],[15,9.79],[18,8.87],[2,1],[7,1],[7,32],[1,1],[4,1],[0,1],[18,3],[0,1],[12,"NaN"],[10,1],[17,1],[8,1],[11,0],[8,0.26],[6,1],[2,9.89],[1,1],[11,1],[7,9.31],["NaN",1],[15,1.25],[5,1],[16,8.24],[0,6.529999999999999],[16,1.65],[1,7.58],[19,8.36],[16,7.42],[13,1],[10,32],[19,"Infinity"],[9,1],[13,1],[13,1],[7,1],[6,1],[12,1],[17,1],[16,1],[13,32],[6,32],[4,1],[2,1],["NaN",32],[0,5.09],[6,32],[15,32],[14,32],[6,1],[19,32],[0,32],[14,8.74],[9,1],[17,1],[11,32],[8,1],[14,1],[17,1],[11,1],[10,7.49],[17,1],[12,1],[9,1],[17,6.55],[15,1],[14,32],[17,32],[0,7.33],[4,1],[13,1],[11,32],[15,32],[3,1],[3,32],[11,5.319999999999999],[4,1],[5,32],[19,3.3899999999999997],[18,32],[17,5.6499999999999995],[13,1],[4,1],[3,1],[0,7.64],[8,1],[13,32],[7,32],[14,1.37],[3,"NaN"],[0,32],[11,1],[4,1],[2,7.4799999999999995],[15,4.779999999999999],[7,1],[9,1],[11,8.34],[4,3.3899999999999997],[15,1],[5,32],[0,1],[19,32],[18,32],[4,0.95],[6,32],[13,1.3800000000000001],[10,1],[11,1],[5,1],[14,32],[8,9.03],[14,1],[19,32],[14,2.88],[19,32],[17,32],[4,3.8499999999999996],[5,1],[5,2.4299999999999997],[18,5.569999999999999],[11,1],[2,32],[17,1],[15,1],[18,1.05],[4,1],[7,1],[12,32],[13,2.96],[16,32],[3,2.3099999999999996],[19,1],[13,32],[10,1],[17,1],[8,32],[8,1],[10,1],[0,5.29],[1,1],[16,1],[7,1],[8,4.52],[17,1],[17,32],[8,32],[4,1],[18,1],[4,8.74],[0,1],[16,1],[1,1],[19,1],[0,1],[10,1],[13,1],[13,2.2699999999999996],[11,1],[6,1],[7,3.1999999999999997],[5,1],[7,32],[17,32],[5,32],[11,7.13],[12,32],[18,5.33],[10,8.44],[10,32],[11,0.15000000000000002],[0,9.47],[12,1],[9,1],[3,32],[7,1],[1,4.6499999999999995],[6,1],[3,3.6999999999999997],[4,1],[19,32],[19,1],[13,1],[15,1],[7,2.42],[10,3.09],[5,1],[19,32],[9,32],[1,1],[14,1],[14,1],[5,1],[15,1],[3,1],[15,1],[17,32],[19,1],[6,1],[17,1],[13,32],[14,1],[4,9.51],[10,32],[4,5.97],[13,0],[16,7.4799999999999995],[16,1],[19,1],[13,1],[18,2.84],[15,2.5399999999999996],[6,0],[16,"Infinity"],[5,1],[13,2.94],[1,1],[15,1],[16,32],[19,1],[6,6.54],[8,1],[7,1],[8,3.59],[16,5.68],[10,1],[11,1],[2,"NaN"],[4,1],[7,32],[18,1],[10,"Infinity"],[12,4.52],["NaN",1],[5,1],[14,1],[7,1],[0,1],[5,32],[2,5.029999999999999],[19,1],["NaN",1],[6,7.52],[11,1],[7,1.11],[2,1],[10,1],[9,"NaN"],[9,1],[10,3.42],[8,32],[12,1],[17,1.34],[19,0.89],[5,1],[13,1.85],[16,1],[11,1],[16,1],[5,5.8],[19,8.97],[19,1],[1,6.54],[0,1],[3,1],[10,"NaN"],[1,"NaN"],[1,1],[15,1],[6,2.8],[6,-1],[0,8.1],["NaN",1],[17,1],[16,1],[12,32],[2,32],[10,1],[13,1],[6,4.87],[0,1],[17,4.279999999999999],[9,32],[13,1],[1,1],[10,8.78],[5,1],[4,3.3699999999999997],[6,1],[7,32],[0,1],[7,-1],[6,8.43],[6,1],[2,0.8200000000000001],[15,32],[0,1],[5,9.39],[5,5.17],[15,3.8499999999999996],[2,9.78],[6,1],[8,0],[14,1],[2,32],[8,32],[10,0.18000000000000002],[9,1],[19,1],[14,1],[7,32],[10,1],[17,1],[9,0],[8,32],[4,1],[3,0.24000000000000002],[12,1],[11,2.88],[12,1],[1,7.54],[17,1],[11,7.81],[14,32],[15,3.25],[8,1],[15,4.76],[0,1],[9,1],[14,1],[13,1],[6,1],["NaN",1],[14,1],[19,1],[11,1],[0,1],[14,1],[11,5.97],[19,1],[17,1],[14,8.02],[5,32],[2,7.95],[1,1],[11,1],[12,0.72],[5,1],[19,1],[17,1],[12,5.33],[11,1],[17,1],[1,1],[6,32],[15,32],[4,32],[15,1],[19,32],[7,1],[18,1],[18,2],[14,"Infinity"],[1,32],[6,1.67],[6,1],[10,6.2299999999999995],[6,1],[8,5.069999999999999],[11,1],[3,32],[7,1],[12,1],[5,1],[8,1],[8,1],[3,8.299999999999999],[10,32],[2,1],[0,1],[10,32],[15,1],[3,1],[16,1],[7,32],[7,32],[16,32],[19,1],[0,1],[6,1],[17,4.2],[16,1],[11,9.16],[3,"Infinity"],[13,8.39],[1,1],[15,1],[3,1],[9,1],[10,1],[3,8.69],[1,8.36],[0,32],[14,32],[0,1],[6,1],[13,1],[13,9.01],[4,1],[9,"NaN"],[0,32],[4,1],[17,1],[11,1],[3,32],[5,1],[2,1],[2,1],[7,1],[5,1],[17,1],[7,1],[6,8.32],[0,1],[6,1],[6,32],[1,5.12],[5,1],[10,32],[3,2.09],[8,6.16],[13,1],[9,4.21],[3,9.68],[0,1],[17,1],[5,1],[5,5.569999999999999],[13,32],[0,1],[1,1],[12,1],[2,1],[2,1],[11,8.79],[8,2.7899999999999996],[6,1],[11,6.319999999999999],[4,32],[15,1],[9,1],[10,32],[16,1],[13,1],[4,7.55],[3,1],[0,1],[6,1],[6,1],[11,1],[7,1],[18,32],[17,3.6999999999999997],[13,1],[10,1],[3,5.24],[12,4.05],[10,1],[8,1],[1,4.12],[0,1],[18,32],[18,1],[9,1],[7,8.97],[13,1],[8,0.19],[9,32],[18,2.4499999999999997],[5,1],[14,1],[5,1],[18,32],[7,1],[2,4.569999999999999],[12,3.2699999999999996]]},{"op":"add","d":0,"values":[[435.501,1],[704.976,1],[394.245,7.21],[822.136,1],[630.108,2.3099999999999996]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],null,[6,6,6,6,6.6,11.781249999999998,16,16,16,16,16,16,"NaN","NaN","NaN"],null,null,null,6578.550000000001,[0,0,0,2.4535276672412847,6,10.978378855078477,16,19,19,40.863516540567474,472.8977889256459,822.136,"NaN","NaN","NaN"],[0,0.05511776911325444,0.47638005335522254,0.9980491543911221,0.9991223818201983,1],[100,0,1,0,4,0,2,0,7.819999999999999,0,5.34,0,10.92,0,4,0,32,0,13.62,0,32,0,14.969999999999999,0,32,0,31.86,0,36,0.07908796546141393,37.06,1,4.12,1,40.16,1,36.57,1,34.31,1.0406022635408245,49.48,2,4.569999999999999,2,49.41,2,52.489999999999995,2,38.03,2,42.6,2.2381719136894236,56.54,3,37.24,3,33,3,43.59,3,63.52,3,35.31,3,37.940000000000005,3,50.989999999999995,3.317790674404643,49.970000000000006,4,39.55,4,71.77,4,45.779999999999994,4.273263908959537,55.36,5,66,5,70.42,5,73.43,5,54.36,5.384139740856159,60.97,6,68,6,84.86,6,64.28999999999999,6.576649993900207,81.97,7,75.97999999999999,7,89.53,7,84.93,7,66.11,7,66,7.577296239210852,97.32000000000001,8,68.98,8,90.64999999999999,8,68.59,8.274128659629554,100.41999999999999,9,33,9,75,9.289876119092234,96.06,10,34,10,87.92999999999999,10,89.70000000000002,10,97,10.91415408525755,90.07999999999998,11,75.25,11,80.07000000000001,11,95.82,11.606707805664287,86.85999999999999,12,69.57,12,86.82000000000001,12,70.52,12.502724568709102,84.05,13,35,13,91.57,13,70.33999999999999,13,86.44999999999999,13.894273644684345,85.21999999999998,14,67,14,75.11000000000001,14,84.89999999999999,14.59330512692882,80.36,15,59.22,15,78.03999999999999,15,85.41999999999999,15.454013015184382,73.75999999999999,16,65,16,81.58000000000001,16,60.79,16,74.68,16.934138309549944,81.99,17,53.4,17,74.67,17,44.199999999999996,17,67,17,67.34,17.744950559247847,61.69,18,67.45,18,32,18,64,18.43840116809637,54.79,19,34,19,33,19,33.41,19,32,19,33,19,54.35,19,42.47,19,35.39,19,32,19,32,19,34,19,33,19,36.89,19,13.97,19.014676470588235,34,19.778,32,23.197594977462973,15.53,27.283,32,32.131,1,32.648,32,33.282,1,33.33,32,41.03599899345747,19.869999999999997,45.785,32,54.82165846153846,9.75,86.014,1,394.245,7.21,571.3143444108761,3.3099999999999996,704.976,1,822.136,1]]}, +{"name":"random 22","compressions":[5,100],"ops":[{"op":"merge","d":1,"from":1},{"op":"add","d":0,"values":[[773.603,"Infinity"],[110.559,32],[793.103,1],[237.25,0],[20.184,32]]},{"op":"toJSON","d":1},{"op":"add","d":1,"values":[[1,1],[8,9.91],[19,1],[12,1],[2,1],[15,1],[18,1],[9,1],[14,"NaN"],[9,"Infinity"],[15,32],[15,1],[8,1],[9,0.68],[2,1],[2,1],[8,1],[0,1],[10,32],[12,32],[15,1],[11,32],[2,1],[5,32],[12,"Infinity"],[8,0],[3,1],[13,32],[0,9.04],[13,1],[3,1],[5,1],[5,1],[12,1],[0,32],[9,3.92],[3,1],[5,1],[2,2.7199999999999998],[6,8.25],[18,1],[3,1],[7,32],["NaN",32],[2,1],[19,1.32],[13,5.81],[16,32],[11,1],[19,1],[8,"NaN"],[0,1],[2,1],[3,32],[15,1],[8,1],[5,1],[6,1],[6,1],[0,1],[10,4.1],[9,6.25],[4,2.5799999999999996],[5,"NaN"],[17,32],[5,32],[15,0.62],[18,32],[1,32],[4,1],[5,1],[1,1],[18,32],[14,1.59],[7,1],[8,9.72],[13,1],[0,2.6599999999999997],[15,1],[5,2.4899999999999998],[1,0.28],[13,1],[11,2.69],[10,4.3],[7,1],[3,1],[16,1],[4,32],[10,9.59],[1,8.51],[19,1.57],[11,1],[4,0.91],[13,7.45],[15,1],[10,32],[0,1],[13,1],[4,32],[16,1],[5,0],[2,4.24],[6,32],[0,32],[15,1],[1,1.72],[2,1],[1,1],[1,1],[12,32],[9,32],[11,1],[8,32],[17,9.12],[18,5.8],[12,1],[9,1],[16,8.32],[3,32],[4,9.58],[12,1.29],[18,6.12],[17,6.069999999999999],[7,7.21],[17,9.1],[17,1],[4,3.5799999999999996],[1,1],[5,32],[15,1],[8,9.93],[14,7.71],[15,1],[0,32],[0,1],[14,4.14],[12,0.9400000000000001],[4,1],[5,1],[4,32],[15,"Infinity"],[13,1],[19,32],[12,1],[19,1],[11,32],[5,0],[11,1],[9,1],[1,1],[14,1],[17,32],[8,32],[16,1],[16,1],[4,5.359999999999999],[13,1],[19,1],[14,1],[3,32],[5,1],[4,32],[16,1],[19,1],[17,7.25],[12,32],[2,1],[6,1],[6,1],[9,1],[19,6.05],[11,32],[6,1],[16,1],[1,1],[7,"NaN"],[5,1],[7,1],[2,4.33],[9,1],[4,32],[17,1],[15,7.58],[3,1.83],[1,1],[15,5.6],["NaN",1],[8,32],[14,0.88],[9,1],[2,32],[16,1],[13,1],[18,5.79],[3,"Infinity"],[16,2.84],[6,1],[9,1.17],[1,32],[2,1],[2,"Infinity"],[13,8.06],[1,2.61],[4,1],[2,1],[10,1],[2,8.83],[14,32],[14,4.18],[17,1],[7,32],[14,1],[11,1],[4,0.3],[2,1],[4,"NaN"],[2,1],[8,1],[11,3.34],[4,1],[0,1],[16,1],[7,1],[15,32],[10,7.41],[16,1],[2,32],[7,32],[10,1],[11,0.95],[3,1],[4,1],[18,1],[17,1],[17,4.93],["NaN",1],[3,32],[6,7.5],["NaN",32],[9,2.1199999999999997],[19,9.59],[2,32],[4,1],[14,1],[9,32],[7,32],[1,0.42],[5,4.4799999999999995],[10,9.16],[12,0.64],[4,32],[17,1],[18,1],[11,32],[13,32],[11,1],[1,1],[6,1],[10,1],[0,7.4799999999999995],[4,0.9],[15,32],[9,1.86],[10,1],[11,32],[4,5.56],[14,32],[5,1],[6,1],[17,1],[10,"Infinity"],[8,1],[15,3.82],[0,32],[18,32],[2,1],[2,4.54],[0,1],[12,1],[2,1],[18,1],[7,1],[4,1],[19,1],[14,1],[16,1],[1,1.66],[16,0.35000000000000003],[4,5.45],[1,8.07],[5,32],[1,2.1999999999999997],[18,1],[14,32],[11,32],[8,1],[14,1],[19,1],[18,1],[14,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1}],"expect":[null,null,[100],null,65,[20.184,20.184,20.184,20.184,20.8900546875,66.783609375,141.58372727272726,544.9051818181817,679.3456666666666,786.8980545454543,793.103,793.103,"NaN","NaN","NaN"],[0,0,0,0.6809425683583361,0.8832992339068139,1],[5,20.184,32,110.559,32,793.103,1],2399.92,[0,0,0,1.2091847516865806,4,8.03082333379274,13,17,18,19,19,19,"NaN","NaN","NaN"],[0,0.09195723190773027,0.5861132871095704,1,1,1],[100,0,1,0,9.04,0,32,0,5.66,0,32,0,32,0,9.48,0,32,0.5,2,1,32,1,17.509999999999998,1,32,1.296296296296296,22.68,2,12.57,2,32,2,12.83,2,32,2,32,2.379506641366224,10.54,3,32,3,1,3,32,3,32,3,2.83,3,32,4,3.5799999999999996,4,32,4,0.91,4,32,4,14.16,4,32,4,5.359999999999999,4,32,4,33.3,4,3,4,32.9,4,12.01,5,35,5,34,5,35.49,5,7.4799999999999995,5,32,6,10.25,6,36,6,9.5,7,34,7,8.21,7,33,7,32,7,33,8,22.630000000000003,8,32,8,9.93,8,32,8.045801526717558,36.68,9,10.17,9,37,9,37.15,10,36.1,10,13.89,10,33,10,19.57,11,36.69,11,34,11,36.34,11,33.95,11,32,11.030303030303031,33,12,33,12,34.29,12,33.94,12.951248513674198,33.64,13,28.32,13,32,14,16.32,14,32,14,6.18,14,32,14,1,14,32,14.333333333333334,3,15,32,15,21.800000000000004,15,32,15,32,15,3.82,16,32,16,21.51,17,32,17,15.189999999999998,17,10.1,17,32,17.10427528675704,19.18,18,32,18,32,18,11.92,18,7.79,18,32,18.619771863117872,7.890000000000001,19,32,19,3,19,6.05,19,9.59,19,1,19,1]]}, +{"name":"random 23","compressions":[100],"ops":[{"op":"add","d":0,"values":[[872.747,32],[950.848,1],[601.308,9.07],[938.665,"Infinity"],[75.414,1]]},{"op":"add","d":0,"values":[[384616.5,1],[-583485.5,1.95],[-826034.6,32],[514145.3,32],[72816.7,8.59],[-21556,1],[-12861.2,2.51],[-820777,1],[-285912.8,0.51],[12397.5,32],[-226724.9,9.67],[-252699.1,3.21],[-265142.4,1],[-826560.2,1],[-139031,1],[950078.4,1],[753566.2,8.94],[848923.2,7.35],[434622.4,1],[-706904.8,2.5],[93093.9,5.38],[-475005,1],[908316.6,"Infinity"],[-402271,-1],[-766457.3,1],[12120.7,32],[-712745,1],[758450.1,1],[-389371.2,1],[362598.7,1],[782760.8,1],[-824588.6,1],[918362.4,7.09],[-435287.1,1],[553918.3,1],[619774.1,1],[896679.8,32],[295875.6,1],[-943338.1,3.1199999999999997],[612557.8,1],[98832.1,32],[233749.2,1],[-683688.7,1],[-533274.3,1],[589211.3,1],[927492.4,2.19],[125597.5,1],[-359023.9,32],[-491135,2.07],[38152.3,1],[890680.5,32],[-119834,8.9],[-193563.2,1],[509247.1,"Infinity"],[390286,0.29000000000000004],[-847093.2,6.88],[-685517.5,5.33],[-228024.4,-1],[932496.1,1],[385472.5,1],[615783.2,1],[715496.6,6.95],[882871.9,1],[452784.5,1],[-179080.2,1],[-313422,1],[-15254.4,1],[-877407.1,1],[-897871.9,1],[773073.3,1],[586670.2,1],[98746.8,1],[341779.2,32],[256316.6,2.6399999999999997],[-553244.4,1],[387695.5,7.87],[-853620,1],[-427964.2,1],[-337076.7,1],[-393513.8,32],[321863.6,32],[-548166.1,1],[310267.5,1],[-438773.3,1],[-579027.5,8.36],[251279.9,1],[693082.5,7.46],[283490.8,0.01],[359560,1],[-972132.4,1],[394197.7,1],[962498.1,32],[-748387.4,1],[226725.5,1],[-400052.5,1],[-930739.7,1],["NaN",32],[-658305.5,1],[-95943.1,5.779999999999999],[-664010.8,9.78],[-980282.4,32],[305303.5,1],[-786540.3,32],[-145234.3,32],[-589681.8,1],[-21392.3,32],[988761.9,1],[654009.5,1],[370041.1,9.14],[200523.6,1],[372329.9,5.09],[292966.5,1],[407226.3,1],["NaN",32],[-401011.3,32],[423917,1],[-461057.4,3.9499999999999997],[-406029.8,0.5700000000000001],[-694781.2,32],[528909.5,4.819999999999999],[823028.6,7.26],[-99952.1,32],[-674546.7,0.79],[-763278.4,"NaN"],[-835548.3,1],[-934478.6,1],[-934189.1,6.069999999999999],[68544.2,1],[-229436.5,1],[195751.1,1],[-858520.7,32],[-152861.5,1.07],[26579.7,1.68],[966093.1,1],[-934646.5,1],[105343,32],[-990322.7,1],[-683415,1],[361263.1,1],[534092.7,32],[-558980.9,32],[-891741.4,1],[-197283.9,1],[-202804.5,1],[82767.9,1],[309428.9,1],[547585.7,32],[188348.8,1],[-996665.1,7.56],[129019.3,1],[-472833.5,0.21000000000000002],[-114982.9,1],[733542.6,1],[-898272.9,1],[-252737.4,7.9399999999999995],[599300.4,8.22],[-645421.8,0],[-526619.3,1],[36274.6,1],[777693,32],[385013.2,32],[74526.4,1],[93424.8,1],[650382.4,1],[-905590.3,1],[-573834.7,1],[-617794.6,1],[-46939.5,1],[-393117.8,1],[-928604.2,1],[755048,32],[-468532.7,1],[-67499.6,32],[-597028.5,32],[710604,1],[981032.8,1],[902182.5,1],[939485.9,1],[-556396.9,1],[335645.4,1],[-281823,5.029999999999999],[843682.2,1.92],[559276.9,1],[289657.7,4.22],[852451.3,-1],[640616.2,1],[-141999.7,"Infinity"],[86695.9,32],[-923109.4,1],[-931327.2,1],[-536118.1,1],[-704870,1],[294812.6,9.06],[-502752.7,6.08],["NaN",1],[-841065.4,1],[18656.8,1],[510542.3,-1],[379196,1],[342.6,1],[685141.8,1],[-833615.6,1],[-870204.5,32],[452398.7,1],[-318953.3,0.52],[831564.8,1],["NaN",1],[-255937.1,32],[670956.8,0],[64277.4,32],[-340003.4,32],[-303008,1.85],[113842.9,1],[-592296,32],[-805616.5,1.43],[305525.4,1],[-773639.8,32],[-579962.7,32],[800398.5,32],[-775020.2,1],[871896.7,32],[500425.8,32],[-591075.8,1],[-297230.8,1],[-424913.4,32],[-941607,32],[-179495.4,"Infinity"],[473712.4,9.879999999999999],[201538.8,1],[-513604.8,0],[-755114.6,5.47],[263171.4,32],[-6154.5,1],[60777.4,7.83],[-114947.1,1],[-509634.7,32],[535613.7,1],[-489080.5,32],[-976305.3,1],[694672.6,32],[28030.3,1],[-544340.7,1],[467839.2,32],[904455.8,32],[463439.5,0.4],[376244.2,32],[275054.9,1],[627670,1],[466468.7,1],[-517322,1],[-340229.3,4.75],[-970181.5,1],[614432.6,32],[531796.9,3.4099999999999997],[551198.5,4.43],[-102189.6,1],[375140.3,0.06999999999999999],[410878.3,0.85],[-846956.4,32],[-989589.3,1.27],[-159153.6,4.38],[-287940.3,1.41],[100851.1,1],[-180751.2,32],[-200784.5,32],[151380.7,1],[832230.8,1],[730161.6,1],[-883518.3,"Infinity"],[-393525.3,1],[481944.2,1],[-345484,1],[266060.5,32],[732374.1,1],[-329521.6,32],[193559.6,1],[-36389.6,1],[113903.9,3.1999999999999997],[-611155.8,1],[566816.1,1],[642969.3,7.83],[-403966.9,1],[562731.8,1],[-650272.3,0],[854142.4,1],[-919727.9,1],[19112.8,"NaN"],[-946369.6,8.049999999999999],[388034.8,1],[-133747.6,6.52],[-614395.3,32],[-619019.8,1.95],[862031.3,7.6],[370282.5,32],[-873321.4,32],[-938706.3,32],[469430.9,32],[118812.7,"Infinity"],[585051.5,4.22],[-63526.2,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[null,null,2429.3999999999996,[-996665.1,-996665.1,-981145.642192231,-847682.8675233823,-554250.8466500003,-3489.830377426572,468944.4366875,780908.7494545452,891957.2260312499,955899.870159999,973283.4649064699,988761.9,"NaN","NaN","NaN"],[0.50168721457935,0.5016876980454205,0.5016920492400551,0.5017355611864017,0.501928947614609,0.5109772101059462],[100,-996665.1,7.56,-989912.3837004405,2.27,-980282.4,32,-972873.0666666668,3,-946369.6,8.049999999999999,-943338.1,3.1199999999999997,-941607,32,-938706.3,32,-923646.0361452841,17.07,-877407.1,1,-873321.4,32,-870204.5,32,-858520.7,32,-847921.474111675,7.88,-846956.4,32,-834197.375,4,-826034.6,32,-815567.695335277,3.4299999999999997,-786540.3,32,-775020.2,1,-773639.8,32,-737694.115455305,11.969999999999999,-694781.2,32,-665035.1579862699,21.849999999999998,-614395.3,32,-611155.8,1,-597028.5,32,-592296,32,-586975.7784810127,3.95,-579962.7,32,-578472.7136752136,9.36,-558980.9,32,-539435.2250000001,8,-509634.7,32,-499801.9467484663,8.15,-487968.6856182403,34.21,-449381.48633093527,6.949999999999999,-423968.80208519514,33.57,-400762.9235294117,34,-393380.31176470587,34,-358613.60000000003,33,-340229.3,4.75,-339914.71212121216,33,-326691.3532031894,36.370000000000005,-281072.13094339625,7.949999999999999,-255937.1,32,-238499.9934268186,22.82,-200469.15,34,-178175.79903691815,37.38,-145291.76416201936,34.07,-123272.34267100978,18.42,-99338.75907887772,37.78,-64677.73611111111,36,-19679.2508131165,37.51,575.6170367428003,10.07,875.1136969696969,33,12120.7,32,14928.022717622083,37.68,60777.4,7.83,64406.69696969697,33,73917.82370160529,10.59,87616.74644194756,37.38,98732.85428571429,35,106852.38924731183,37.2,209537.3674050633,12.64,263171.4,32,266338.2553165707,33.01,296303.1664937759,19.28,322281.2303030303,33,343438.7485714286,35,370041.1,9.14,370282.5,32,372368.02558139537,5.16,376577.2617647059,34,385027.11818181816,33,408881.04422745545,17.409999999999997,467839.2,32,469430.9,32,474468.9992647059,10.879999999999999,500425.8,32,514145.3,32,530105.8589307412,8.229999999999999,534092.7,32,535613.7,1,547585.7,32,580986.9448261416,23.869999999999997,614432.6,32,659408.8052489907,22.29,694672.6,32,734854.9772750125,19.89,755048,32,765761.7,2,777693,32,782760.8,1,800398.5,32,837305.7337429594,19.53,862031.3,7.6,871896.7,32,882871.9,1,890680.5,32,896679.8,32,902182.5,1,904455.8,32,920517.0012931034,9.28,940686.8,3,962498.1,32,973562.95,2,988761.9,1]]}, +{"name":"random 24","compressions":[1000],"ops":[{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"add","d":0,"values":[[342.295,7.279999999999999],[690.353,32],[336.133,1],[154.921,5.87],[204.23,1],[693.907,32],[31.2,1],[579.145,32],[695.517,8.83],[568.426,1],[750.935,3.2399999999999998],[573.168,0],[549.268,9.53],[421.124,1],[496.877,"Infinity"],[403.626,1],[698.324,9.54],[377.356,32],[60.899,1],[457.911,3.0399999999999996],[488.422,32],[403.724,32],[252.348,1],[486.811,6.75],[593.204,1.46],[571.563,1],[145.561,1],[361.657,2.25],[226.757,4.77],[929.646,6.81],[158.937,32],[815.123,1],[958.638,1.19],[233.188,1],[153.57,1],[990.505,1],[582.665,1],[195.816,1],[863.988,1],[277.657,32],[379.434,1],[292.496,6.83],[918.826,5.05],[989.345,1],[960.487,1],[227.444,32],[880.407,32],[51.531,32],[264.535,1],[399.057,1],[666.401,5.85],[325.088,1],[853.829,6.97],[250.379,6.8],[573.22,1],[57.266,4.25],[749.696,3.59],[241.814,32],["NaN",1.44],[216.515,32],[602.445,1],[813.241,1],[234.93,0.81],[995.984,1],[699.881,1],[959.377,5.02],[798.23,6.33],[450.034,"Infinity"],[996.527,1],[673.657,1],[437.753,1],[111.037,1],[537.129,32],[171.84,1],[293.745,1],[22.579,32],[52.691,1],[556.548,1],[72.759,1],[619.867,1],[946.952,32],[850.974,32],[799.717,1],[256.974,32],[727.47,0.060000000000000005],[632.939,1],[778.338,1],[59.633,32],[56.226,32],[340.716,1],[202.011,1],[533.654,1],[514.729,1],[277.018,1],[656.417,1],[928.921,0],[19.774,32],[20.312,5.71],[595.966,1],[598.993,1],[228.607,3.15],[731.845,1],[471.584,1],[755.35,1],[870.337,"Infinity"],[844.4,32],[112.753,32],[817.11,1],[260.68,32],[55.035,32],[550.921,3.9899999999999998],[502.704,1.79],[845.974,1],[90.455,1],[790.817,1],[704.649,1],[337.557,1],[229.499,32],[649.991,32],[434.587,1],[938.207,1.51],[172.095,1],[327.518,32],[44.501,1],[399.007,1],[732.428,0],[724.023,1],[35.048,1],[935.243,1],[783.344,6.6899999999999995],[797.209,9.459999999999999],[786.538,32],[192.498,1],[631.526,"Infinity"],[387.936,5.7299999999999995],[447.847,1],[418.706,1],[454.915,1],[829.152,1],[35.436,1],[657.044,32],[746.007,1],[420.2,6.92],[513.699,1],[323.924,1],[208.47,32],[410.128,4.35],[29.276,1],[663.586,9.89],[164.921,32],[958.842,1],[195.564,1],[398.725,2.4299999999999997],[858.366,3.5399999999999996],[576.462,1],[320.389,1],[979.309,1],[967.543,32],[746.346,1.37],[970.192,0.51],[363.204,1],[320.715,32],[541.772,1],[502.414,1],[320.839,1],[89.219,5.41],[956.714,32],[180.506,4.39],[418.696,1],[776.341,1],[355.388,1],[43.49,6.109999999999999],[338.9,32],[437.628,1],["NaN",1.3800000000000001],[227.258,7.779999999999999],[40.129,1],[882.245,1],[529.289,1],[913.545,32],[214.466,1],[239.25,3.46],[127.159,2.6199999999999997],[114.644,1],[5.507,3.61],[720.197,1],[433.638,0.86],[65.017,5.58],[334.049,6.67],[969.876,32],[714.551,32],[489.233,2.86],[282.626,0],[788.685,32],[160.061,1],[694.881,1],[10.48,1],[262.12,1],[443.253,1],[218.465,32],[496.844,1],[251.593,8.82],["NaN",1],[202.287,1],[100.353,7.09],[662.027,1],[626.807,1],[602.075,1],[856.239,1],[494.742,"NaN"],[353.67,1],[237.763,32],[351.113,1],[442.19,1],[26.204,1],[193.979,1],[477.263,0.27],[489.893,1],[416.209,1],[561.171,1],[673.888,1],[615.015,0.38],[116.871,2.17],[785.536,32],[122.529,32],[502.465,32],[569.407,3.8099999999999996],[884.237,32],[196.16,1],[353.988,1],[692.127,7.24],[176.215,32],[698.776,1],[587.313,1],[941.031,32],[116.039,1],[231.742,32],[85.561,1],[277.184,1],[136.611,1],[145.577,8.64],["NaN",5.97],[536.406,1],[440.071,0.64],[456.143,-1],[770.775,1],[414.948,"Infinity"],[592.042,1],[333.849,4.4399999999999995],[390.488,5.46],[867.117,1.96],[552.455,9.83],[477.836,1],[540.285,1],[761.215,1],[566.316,4.08],[960.91,1],[818.385,1],[940.329,1],[207.176,7.34],[14.874,1],[784.112,1],[151.744,1],[700.165,32],[397.29,32],[245.864,32],[126.769,1],[617.436,2.01],[36.487,0.3],[535.8,1],[941.876,0.29000000000000004],[589.247,1],[797.878,1],[694.577,1],[962.855,1],[777.524,-1],[991.406,9.18],[867.666,8.75],[687.062,4.85],[886.168,1],[577.462,1],[264.688,1],[600.169,5.779999999999999],[688.903,32],[546.312,3.4099999999999997],[306.755,1],[371.382,"Infinity"],[12.17,1],[380.224,1],[75.03,1],[648.686,1],[391.188,0.11],[420.914,8.2],[998.271,8.69],[771.411,"NaN"],[393.493,1],[116.837,1],[589.52,1],[750.154,1],[596.124,0]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],null,2210.2499999999995,[5.507,6.381320281995659,19.62328787878788,60.710634545454546,224.99238482458526,401.3758360294118,716.6564611835768,914.7494385964914,957.0708008436276,981.9936300000038,998.271,"NaN","NaN","NaN","NaN"],[0,0,0.001758859224269829,0.109657613414091,0.555899365240891,1],[1000,5.507,3.61,10.48,1,12.17,1,14.874,1,19.774,32,20.312,5.71,22.579,32,26.204,1,29.276,1,31.2,1,35.048,1,35.67853846153846,1.3,40.129,1,43.49,6.109999999999999,44.501,1,51.531,32,52.691,1,55.035,32,56.226,32,57.266,4.25,59.633,32,60.899,1,65.017,5.58,73.8945,2,85.561,1,89.219,5.41,90.455,1,100.353,7.09,111.037,1,112.753,32,115.3415,2,116.837,1,116.871,2.17,122.529,32,126.769,1,127.159,2.6199999999999997,141.086,2,145.577,8.64,152.65699999999998,2,154.921,5.87,158.937,32,160.061,1,164.921,32,171.9675,2,176.215,32,180.506,4.39,193.2385,2,195.69,2,199.0855,2,203.2585,2,207.176,7.34,208.47,32,214.466,1,216.515,32,218.465,32,226.757,4.77,227.258,7.779999999999999,227.444,32,228.607,3.15,229.499,32,231.742,32,233.96756906077349,1.81,237.763,32,239.25,3.46,241.814,32,245.864,32,250.379,6.8,251.593,8.82,252.348,1,256.974,32,260.68,32,263.781,3,277.101,2,277.657,32,292.496,6.83,306.963,3,320.715,32,323.28366666666665,3,327.518,32,333.849,4.4399999999999995,334.049,6.67,336.845,2,338.9,32,340.716,1,342.295,7.279999999999999,352.9236666666667,3,359.7280769230769,3.25,363.204,1,377.356,32,379.829,2,387.936,5.7299999999999995,390.488,5.46,393.2645765765766,1.11,397.29,32,398.8072157434402,3.4299999999999997,401.3415,2,403.724,32,410.128,4.35,417.87033333333335,3,420.2,6.92,420.914,8.2,429.5942937062937,2.86,438.2675909090909,2.64,444.43,3,454.915,1,457.911,3.0399999999999996,475.01366079295155,2.27,486.811,6.75,488.422,32,489.233,2.86,496.38366666666667,3,502.465,32,506.64486021505377,2.79,525.8906666666667,3,536.103,2,537.129,32,541.0285,2,546.312,3.4099999999999997,549.268,9.53,550.921,3.9899999999999998,552.455,9.83,558.8595,2,566.316,4.08,568.426,1,569.407,3.8099999999999996,573.7483333333333,3,577.462,1,579.145,32,586.4083333333333,3,590.781,2,594.3267642276422,2.46,598.993,1,600.169,5.779999999999999,604.296512605042,2.38,618.2436411960133,3.01,636.144,3,649.991,32,656.417,1,657.044,32,662.027,1,663.586,9.89,666.401,5.85,673.7725,2,687.062,4.85,688.903,32,690.353,32,692.127,7.24,693.907,32,694.729,2,695.517,8.83,698.324,9.54,699.3285,2,700.165,32,704.649,1,714.551,32,722.2661165048544,2.06,738.9259999999999,2,746.346,1.37,749.696,3.59,750.154,1,750.935,3.2399999999999998,758.2825,2,773.558,2,778.338,1,783.344,6.6899999999999995,784.112,1,785.536,32,786.538,32,788.685,32,790.817,1,797.209,9.459999999999999,797.878,1,798.23,6.33,806.479,2,816.1165000000001,2,823.7685,2,844.4,32,845.974,1,850.974,32,853.829,6.97,856.239,1,858.366,3.5399999999999996,863.988,1,867.117,1.96,867.666,8.75,880.407,32,882.245,1,884.237,32,886.168,1,913.545,32,918.826,5.05,929.646,6.81,935.243,1,938.207,1.51,940.329,1,941.031,32,941.876,0.29000000000000004,946.952,32,956.714,32,958.638,1.19,958.842,1,959.377,5.02,960.487,1,960.91,1,962.855,1,967.543,32,969.876,32,970.192,0.51,979.309,1,989.345,1,990.505,1,991.406,9.18,995.984,1,996.527,1,998.271,8.69]]}, +{"name":"random 25","compressions":[20],"ops":[{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[20]]}, +{"name":"random 26","compressions":[1000],"ops":[{"op":"add","d":0,"values":[[-814663.3,1],[-564093.9,1],[163351.7,1],[-663479.2,1],[192962.8,1],[-320485.1,1],[-69896.3,8.94],[-483800.4,1],[-238699.2,1.94],[-638104.7,32],[363535.3,"Infinity"],[-816694.7,1.54],[-179109.6,1],[969162.1,32],[981064.7,3.5199999999999996],[507079.4,1],[-146390.9,1],[643182.9,3.2399999999999998],[-679844.8,32],[139835.8,32],[-126929,32],[744820.1,1],[300198.5,6.5],[455953.6,6.14],[153992.2,32],[50312.1,6.22],[759346.9,1],[903478.8,1],[-370098,1],[-530667.5,0],[-768497.3,1],[297427.2,32],[-714331.9,7.17],[808537.5,1],[605082.3,1],[-292870.1,32],[74713.7,32],[389701.5,2.15],[-604693.2,32],[835125.8,32],[-636112.4,32],[-51800.9,1],[-308742.7,32],[-857494.7,32],[-183640.2,1],[-129862.2,3.13],[37396.1,1],[-49837.1,1],[250706.4,-1],[525634.3,2.8299999999999996],[-503183.8,2.9099999999999997],[-251057.9,1],[937823.1,1.65],[898615.5,2.21],[-686823.1,8.52],[-666023,1],[312953.2,32],[120544.1,32],[-285191.4,1],[627263.3,32],[-587404.1,1],[-927147.8,1],[-704395.4,9.81],[245904.7,1],[-893990.5,32],[-188340.2,32],[521361.5,32],[-479762.9,9.31],[962956.4,32],[-755796.4,0.64],[-40062.8,1],[499015.6,2.9499999999999997],[-555969.4,1],[-492470.2,8.29],[647792.8,3.1199999999999997],[227278.8,1.24],[-119302.4,9.81],[690825.4,0.62],[-386589.6,2.9699999999999998],[810693.4,1],[-522847.2,1],[-69568.5,7.109999999999999],[247249.1,1],[-481397,32],[883300.3,1],[-203229.4,32],[-167472.6,"NaN"],[-546451.9,0.56],[-609493.5,1],[-787883.8,32],[670595.1,1],[155194.8,32],[848623.2,32],[-235244.1,1],[312196,1],[853977.9,1],[-258490.7,"Infinity"],[538640.5,32],[-634232.4,2.3899999999999997],[-975731.3,5.41],[664900.3,1],[684622.5,1],[206214,1],[-602301.5,32],[285839.2,8.82],["NaN",9.12],[-55366.2,1],[979302.9,1],[799235.8,1],[-76099.1,1],[-829959.6,5.83],[-162153,32],[281334.8,4.069999999999999],[633977.5,1],[813763.3,32],[-148420.6,5.87],[-588197.7,3.67],[-439908.9,32],[197979,1],[-938463.6,1.21],[-147573.8,6.069999999999999],[-865393.7,1],[734335.5,"Infinity"],["NaN",6.72],[-563863.1,1],[-625745.2,1],[-567981,32],[499229.9,32],[-567151.1,1],[-766784.4,32],[424925.5,1],[-109662.1,1],[360382.7,5.62],[-218373.3,"Infinity"],[-736562.5,1],[-816160.4,32],["NaN",1],[753294.6,1],[515665.4,8.99],[-76122.4,5.76],[-225643.4,32],[-361641.5,5.319999999999999],[456954.3,1],[-871333.3,7.55],[-684178,1],[854649.7,8.08],[925890.3,1],[-548701,8.09],[66291.4,8.25],[62570.4,2.4499999999999997],[-141064.6,32],[368544.2,1.07],[287203.6,1],[980402,1],[328075,1],[481320.4,3.1799999999999997],[268455.5,0.84],[96910.1,"Infinity"],[-707972,32],[-316224.8,1],[-98034.6,1],[967914.6,1],[-576766.6,32],[-478988,8.73],[-394173.7,32],[-159803.2,1],[-813062,32],[-913787.7,0.87],[80588.7,1],[-60259.8,1],[953747.2,1],[-31409.7,32],[277272.1,1],[824450.7,1],[788817.8,1],[999214.8,1],[-277475.3,1],[-456521.5,1],[-432294.4,1],[-266883.9,5.9799999999999995],[379090.9,1],[155835.9,1],[345852,1],[-484719,32],[168826.9,8.799999999999999],[-421216,32],[312485.6,1],[246189.4,1],[-710588.1,32],[-247581.6,1],[-797180.6,32],[669169.1,32],[-910211.3,32],[488720.8,1],[-183441.3,1],[-89454.5,9.81],[-696164.1,2.25],[-974232.9,2.55],[277815,6.31],[485560.8,1],[-25969.1,1],[923620.4,1],[989910.2,32],[-30296.1,1],[711000.5,1],[192454.9,1],[963025.1,1],[457660.3,3.07],[-214348.9,1],[320598.4,1],[-586078.6,1],[-441206.9,1],[300894.6,1],[794956.2,1],[-176623.5,1],[-390229.3,5.2299999999999995],[327496.4,1],[-649958.1,1],[-190282.9,32],[-408597.4,1],[-959552.1,32],[875520.3,4.819999999999999],[62398.4,1],[540083,9.51],[-133033.5,"Infinity"],[570003.2,3.5],[-103663.9,1],[213378.6,5.13],[-660965.9,1],[-566187.5,9.07],[350588.2,1],[835277.2,8.959999999999999],[-979445.3,0.11],[822054.3,1],[-242973.6,1],[685495.1,2.5],[-472362.3,0],[644749,1],[210974.5,1],[455220,8.19],[303351.7,8.83],[-680030.7,1],[128270.1,1],[838936.7,-1],[973766.3,"Infinity"],[949874.2,9.03],[116567.9,32],[-444583,5.609999999999999],[320159.2,1],[451170,7.38],[-471491.7,4.59],[-422360.5,5.97],[-694824.6,1],[-683600.9,32],[504646.8,0.12],["NaN",3.3699999999999997],[-61328.5,8.65],[-92045.9,1],[474330.2,6.819999999999999],[-833831.2,1],[-971827.4,1],[240543.4,2.5199999999999996],[557463.7,1],[-894719.8,1],[649896.1,4.77],[-514127.9,32],[152795.1,32],[-397044.1,5.279999999999999],[-334145.7,1],[-108449.8,"Infinity"],[216298.8,32],[142400.5,1.12],[16834.2,-1],[887844.4,1],[-516833.5,32],[272768.6,9.58],[258975.8,1],[113553.7,32],[-618516.4,1],[274440.1,6.819999999999999],[-815606.8,1],[174303.1,1],[808415.7,1],[849818.6,1],[-905321.9,1],[792737.6,1],[-568900.9,32],[-474560.8,0.72],[-879637.5,1],[-27324.8,1],[944156.5,5.45],[-424407.7,32],[474118.5,1],[556946.4,9.72],[-217777.3,8.31],[121859.6,1],[530804.6,32],[-910337.9,32],[-655680.3,1],[416697.3,1]]},{"op":"toJSON","d":0},{"op":"reset","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0},{"op":"add","d":0,"values":[[388.301,1.11],[272.308,4.16],[830.621,1],[666.136,1],[604.47,9.76],[467.019,1],[832.647,1],[877.76,1],[767.892,8],[949.091,1],[827.463,1],[113.488,32],[219.448,1],[69.983,1],[903.862,6.6899999999999995],[416.924,1],[266.859,2.42],[32.35,1],[929.845,32],[271.069,1],[532.62,1],[7.655,32],[939.987,1],[933.444,1.78],[671.721,1],[417.476,32],[504.833,1],[267.932,9.18],[102.256,1],[26.417,32],[695.683,32],[696.765,32],[524.804,1],[876.07,6.42],[974.773,1],[312.156,32],[558.344,1],[849.422,32],[239.478,1],[430.209,5.54],[868.813,1],[240.823,3.7699999999999996],[450.286,1],[908.811,1],[254.312,1],[97.131,32],[953.059,32],[654.41,1],[76.63,6.97],[122.699,32],[825.418,1],[430.986,32],[495.16,1],[516.594,"NaN"],[265.084,1],[629.209,32],[453.028,6.58],[777.286,1.4],[880.946,1],[608.555,1],[378.057,9.11],[520.292,32],[46.556,32],[273.226,1],[887.672,3.42],[480.912,32],[652.231,4.62],[774.039,1],[707.942,9.17],[776.27,1],[802.306,1],[39.753,1],[25.146,1],[592.12,1],[567.085,1],[652.451,1],[595.449,32],[421.884,1],[29.494,1],[132.945,1],[266.19,-1],[776.131,32],[852.214,32],[763.287,1],[580.283,5.01],[300.59,32],[834.345,32],[109.554,-1],[697.492,1],[309.9,8.62],[654.135,1],[96.357,32],[91.323,-1],[866.82,5.77],[54.508,1],[971.26,1],[645.262,1],[930.864,1],[917.428,1],[742.784,1.6300000000000001],[686.477,1],[571.805,1],[237.665,32],[329.356,32],[240.437,1],[650.729,1],[974.983,7.26],[365.885,32],[856.905,6.33],[152.425,1],[785.138,1],["NaN","NaN"],[588.574,1],[253.008,1],[789.964,32],[386.333,1],[958.423,1],[787.183,1],[585.965,0.95],[17.133,1],[231.187,32],[838.496,1],[556.09,1],[614.276,1],[187.512,1],[963.898,32],[561.343,1],[866.756,1],[582.678,1],[248.14,5.42],[520.07,6.22],[837.876,1],[860.561,8.53],[282.189,3.65],[765.188,1],[284.059,1],[77.422,1],[111.801,1],[663.271,5.3999999999999995],[515.357,32],[455.48,1],[812.338,1],[585.918,1],[98.941,9.299999999999999],[238.298,"Infinity"],[271.556,32],[68.64,1],[901.483,1],[268.883,1],[421.311,6.35],[628.365,1],[995.997,1],[245.533,32],[522.495,32],[543.479,1],[427.607,32],[125.429,32],[325.571,1],[469.452,1],[128.028,1],[456.314,32],[743.213,1],[362.346,1],[355.716,1],[236.599,32],[574.144,1],[578.581,1],[887.878,32],[139.186,1],[955.45,1],[177.885,1],[498.608,1],[317.783,32],[721.172,1],[933.318,1],[634.047,32],[248.017,1],[17.498,32],[991.428,1.93],[267.715,1],[891.69,1],[38.633,5.88],[215.05,1],[445.708,32],[976.338,1],[561.596,9.31],[909.519,"NaN"],[833.244,"Infinity"],[459.735,32],[885.743,32],[799.681,1],[756.677,9.4],[21.193,32],[326.116,1],[251.133,32],[850.944,1],[238.071,1],[840.592,1],[114.755,32],[339.881,8.93],[263.626,1],[741.842,1],[891.599,1],[579.45,1],[682.254,32],[650.052,1],[440.877,1],[218.116,8.27],[558.088,32],[981.414,32],[614.702,4.7299999999999995],[660.251,5.24],[777.173,32],[491.877,9.52],[977.823,1],[116.265,1],[964.093,6.75],[869.059,1],[712.42,1],[476.43,6.51],[249.321,1],[165.018,3.3899999999999997],[571.165,2.8299999999999996],[902.265,1],[597.672,1],[967.484,32],[723.527,32],[495.338,1],[267.646,1],[18.632,1],[541.816,1],[849.007,1],[432.145,4.67],[896.586,8.36],[806.034,32],[370.429,1],[85.889,32],[152.084,0.7],[301.178,1],[928.242,5.56],[750.676,1],[723.514,5.99],[357.605,32],[679.679,1],[741.809,1],[977.26,1],[898.593,6.069999999999999],[887.475,1],[752.652,1],[909.333,1],[353.023,1],[288.049,32],[347.451,1],[487.268,32],[546.049,32],[476.834,32],[617.036,1],[44.284,1],[217.203,2.2899999999999996],[820.019,1],[995.814,32],[940.121,1],[847.135,1],[939.497,1],[567.815,1],[944.615,32],[203.552,5.33],[875.145,-1],[799.795,1],[820.287,7.76],[316.236,1],[843.831,1],[792.974,5.56],[307.056,32],[449.372,1],[734.704,1],[83.96,1],[980.261,1],[234.676,1],[257.525,1],[955.724,0],[870.93,0.72],[814.904,1],[707.186,5.41],[189.611,1],[35.548,1],[433.914,1],[214.876,1],[669.973,1],[950.41,32],[523.368,32],[383.683,3.0999999999999996],[908.607,1],[402.968,1],[134.182,1],[194.588,32],[982.454,1],[81.668,1],[426.262,1],[751.41,32],[402.271,1],[355.477,-1],[923.311,0],[341.093,1],[556.59,3.0599999999999996],[917.253,1],[571.91,5.59],[979.985,4.24],[385.482,1],[367.184,32],[353.409,1],[177.387,32],[451.659,1],[973.337,32],[452.892,-1],[977.965,1],[718.684,1],[627.568,1],[323.786,1],[870.196,1],[128.087,-1],[689.42,5.84],[876.263,1],[499.675,1],[50.381,32],[890.133,5.17],[257.013,32],[758.178,32],[565.561,1],[132.778,1],[470.005,1],[723.299,1],[141.459,7.38],[714.017,1],[787.774,1],[887.063,32],[520.361,1],[626.564,1],[714.42,"NaN"],[879.199,0],[454.364,32],[600.473,32],[563.328,1],[924.822,3.23],[890.962,6.56],[623.2,1],[421.221,32],[508.595,1],[865.275,1.67],[7.623,1],[891.78,32],[955.109,8.45],[476.429,1],[964.154,1],[794.391,1],[223.579,32],[754.091,1],[899.761,3.8099999999999996],[90.629,1],[945.376,1],[345.074,1],["NaN",1],[807.42,1],[888.2,1],[934.563,1],[994.004,1],[554.923,2],[112.927,5.68],[252.527,32],[257.257,1],[76.341,1],[665.217,1],[956.653,7.66],[690.252,9.6],[752.97,5.609999999999999],[14.168,1],[140.976,1],[290.539,1],[803.798,"NaN"],[886.49,1],[401.52,1],[54.092,1],[365.533,4.25],[483.784,1],[30.172,1],[748.333,1],[81.844,1],[370.355,8.72],[923.215,2.48],[755.1,32],[86.826,0.43],[316.58,1],[547.539,0],[733.679,1],[682.521,1],[322.082,1],[725.589,1],[160.624,9.47],[227.668,4.46],[532.207,1],[240.94,4.72],[592.252,5.359999999999999],[743.111,1],[677.023,2.3499999999999996],[962.713,32],[685.427,32],[897.873,1],[473.08,1.9],[333.384,1],[258.773,1],[247.656,6.85],[145.922,1],[728.141,1],[496.112,1],[787.798,8.42],[612.63,1],[207.738,1],[501.007,2.23],[295.517,32],[418.455,5.029999999999999],[471.073,32],[374.77,0],[52.229,32],[908.403,32],[258.241,3.48],[581.438,1],[876.813,1],[807.75,3.5599999999999996],[161.006,1],[979.302,1],[149.284,32],[750.531,"NaN"],[547.615,32],[445.88,1],[29.629,2.13],[218.178,3.46],[517.905,0.060000000000000005],[710.536,1],[299.989,1],[8.474,32],[552.252,-1],[736.927,4.51],[653.728,5.35],[271.515,1],[241.334,1],[607.675,2.48],[572.853,1],[205.287,1],[196.392,1],[372.133,1],[608.772,1],[380.444,1],["NaN",32],[747.678,1],[887.123,4.09],[804.86,32],["NaN",1.02],[415.457,7.8999999999999995],[332.441,7.93],[39.006,32],[414.13,2.15],[105.695,1],[723.742,9.34],[505.825,1],[673.751,1],[707.741,1],[596.836,1],[753,1],[267.242,32],[431.243,9.799999999999999],[95.987,1],[284.93,2.2899999999999996],[388.059,1],[603.571,4.06],[766.245,1],[506.742,1],[535.673,4.069999999999999],[548.044,3.7699999999999996],[158.661,32],[725.556,1],[266.65,32],[810.63,32],[611.759,1],[522.96,1],[468.616,1],[303.146,8.54],[584.807,1.79],[865.582,"NaN"],[69.196,32],[750.795,1],[375.926,32],[59.165,"Infinity"],[537.205,3.4499999999999997],[749.361,1],[567.419,1],[380.192,1],[509.009,9.43],[159.38,1],[548.342,1],[623.557,7.84],[961.292,1],[189.671,1],[141.784,1],[224.142,8.52],[474.371,1],[587.738,32],[547.118,1],[658.09,1],[208.19,6.63],[825.837,1],[143.222,32],[360.722,0],[637.562,0.21000000000000002],[723.66,32],[661.795,1],[338.778,2.7199999999999998],[80.57,5.26],[684.514,1],[566.268,1],[377.712,6.64],[640.434,1],[776.407,1],[633.508,1],[138.01,1],[510.429,2.9699999999999998],[538.649,1],[902.508,1],[981.278,1],[923.503,6.46],[923.507,1],[295.575,7.9799999999999995],[942.734,1],[635.248,1],[69.825,1.06],[277.363,1],[958.413,32],[369.863,1],[325.774,1],[148.464,32],[787.566,1],[165.031,32],[404.56,32],[110.67,1],[409.054,1],[448.444,32],[427.492,1],[90.07,1],[660.424,0],[281.997,32],[874.959,1],[246.914,1],[676.8,1],[596.249,32],[928.826,1],[181.332,32],[642.58,32],[541.176,6.66],[75.955,32],[235.329,1],[237.473,1.49],[754.284,2.57],[761.891,32],[225.191,1.26],[578.707,3.5],[612.915,"Infinity"],[168.77,32],[436.238,1],[59.039,"NaN"],[954.175,1],[415.243,0.12],[734.212,1],[673.077,1],[76.982,"Infinity"],[314.313,1],[750.196,1],[37.514,1],[354.223,5.02],[347.87,5.54],[522.628,1],[874.61,0],[411.163,7.42],[966.41,"Infinity"],[862.683,32],[640.478,9.84],[38.408,1],[682.577,1],[708.363,1],[686.583,8.93],[875.061,9.26],[408.335,32],[513.243,32],[365.919,32],[379.174,32],[763.772,1],[703.208,32],[34.326,32],[88.487,32],[593.244,32],[943.605,32],[325.746,1],[917.411,32],[719.28,32],[900.251,1],[702.089,1],[667.731,32],[249.828,1],[692.625,32],[769.059,4.14],[498.378,"NaN"],[299.382,1],[661.357,1],[14.924,9.97],[698.847,1],[443.636,2.01],[787.66,32],[481.463,0],[424.173,1],[315.095,1],[582.599,1],[699.737,6.569999999999999],[94.157,1],[384.262,5.05],[328.853,1],[534.612,1],[908.939,1],[970.43,32],[104.943,0],[634.33,1],[529.976,6.64],[935.608,1],[571.227,"Infinity"],[942.607,32],[987.976,2.8299999999999996],[130.346,8.29],[972.99,9.47],[643.509,1],[570.924,32],[796.673,32],[553.908,32],[9.11,3.8299999999999996],[371.033,32],[722.559,9.15],[431.27,32],[764.138,32],[464.629,1],[702.083,1],[30.262,32],[960.441,1],["NaN",0],[284.89,1],[866.553,32],[856.089,1],[238.07,1],[356.586,2.4499999999999997],[913.275,2.9],[639.078,1],[531.518,5.76],[150.222,2.34],[974.759,32],[991.725,0],[641.23,1],[370.972,1],[424.357,32],[397.921,1],[913.957,7.029999999999999],[836.5,0],[955.267,1],[831.116,4.9799999999999995],[341.246,1],[957.82,1],[979.312,32],[215.197,1],[623.764,1.26],[361.39,7.47],[496.015,1],[662.869,1],[672.542,1],[697.114,1],[125.342,1],[617.707,1],[612.028,1],[535.159,3.8099999999999996],[786.44,7.45],[634.761,3.05],[761.717,1],[459.568,32],[271.743,1],[398.448,1],[588.958,4.9399999999999995],[185.212,1],[46.812,1],[23.588,32],[668.071,32],[431.414,32],[913.506,0],[920.335,32],[244.812,1],[769.273,32],[117.378,1],[165.411,32],[521.004,8.85],[55.428,8.75],[57.261,2.8099999999999996],[898.676,32],[723.114,1],[842.778,"Infinity"],[518.321,1],[652.265,1],[602.242,1],[265.171,"NaN"],[120.165,1],[630.677,1.11],[340.019,32],[828.371,9.15],[364.669,1],[902.158,5.06],[929.02,1],[913.36,1],[808.781,1],[852.531,8.92],[170.08,1],[229.9,32],[970.432,1],[902.103,0],[951.898,9.15],[594.467,1],[823.325,1],[789.841,1.47],[277.226,1],[494.069,6.41],[69.11,1],[971.855,1],[761.583,0.14],[608.776,6.9399999999999995],[659.611,1],[596.724,1],[294.505,1],[657.464,1],[659.823,1],[549.661,1],[451.17,32],[799.385,4.359999999999999],[443.656,32],[308.314,7.279999999999999],[264.317,32],[785.259,32],[261.282,1],[727.243,1],[327.314,1],[997.283,1],[466.248,2.36],[970.479,1],[637.291,0],[679.705,1],[466.932,1],[755.383,32],[754.417,1],[149.09,9.9],[215.297,1],[674.345,1],[758.457,1],[284.553,6.58],[843.913,"NaN"],[451.549,1],[651.507,1],[524.829,32],[760.875,7.359999999999999],[68.056,1],[360.505,1],[405.578,1],[281.544,7.1899999999999995],[464.76,1],[405.489,1],[641.077,0.27],[660.797,1],[722.553,1],[645.544,1],[477.493,32],[658.015,"NaN"],[226.424,1],[663.559,9.91],[410.409,1],[452.998,1],[653.176,1],[467.228,32],[290.964,32],[621.171,1],[27.864,2.19],[647.252,1],[762.029,32],[798.997,1],[53.872,7.4799999999999995],[452.811,1],[791.394,0.18000000000000002],[624.626,1],[49.59,2.3099999999999996],[336.549,32],[632.312,9.79],[202.793,32],[839.991,1],[407.692,1],[644.307,4.74],[286.426,1],[549.019,32],[436.854,1],[959.031,1],[955.861,2.65],[391.126,0.63],[248.715,1],[142.315,1],[387.927,1],[479.987,1],[599.812,32],[284.229,5.2299999999999995],[150.403,1],[423.128,1],[839.243,1],[173.451,32],[131.159,8.87],[145.707,1],[241.558,1],[205.033,1],[412.856,1],[525.879,1],[119.156,0.06999999999999999],[863.12,"NaN"],[330.748,32],[544.183,0],[13.083,1],[910.577,0],[374.403,9.69],[130.351,1],[608.008,6.08],[276.21,1],[734.951,32],[420.207,32],[903.911,1],[41.754,"Infinity"],[412.929,8.12],[155.78,32],[540.416,32],[944.789,1],[908.425,"Infinity"],[398.033,1],[248.575,1.85],[680.925,1],[306.026,1],[984.344,2.44],[54.721,1],[777.902,1.14]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[null,[1000,-979445.3,0.11,-975731.3,5.41,-974232.9,2.55,-971827.4,1,-959552.1,32,-938463.6,1.21,-927147.8,1,-913787.7,0.87,-910337.9,32,-910211.3,32,-905321.9,1,-894719.8,1,-893990.5,32,-879637.5,1,-871333.3,7.55,-865393.7,1,-857494.7,32,-833831.2,1,-829959.6,5.83,-816694.7,1.54,-816160.4,32,-815135.05,2,-813062,32,-797180.6,32,-787883.8,32,-768497.3,1,-766784.4,32,-744068.412195122,1.6400000000000001,-714331.9,7.17,-710588.1,32,-707972,32,-704395.4,9.81,-696164.1,2.25,-694824.6,1,-686823.1,8.52,-684178,1,-683600.9,32,-680030.7,1,-679844.8,32,-663489.3666666667,3,-652819.2,2,-638104.7,32,-636112.4,32,-634232.4,2.3899999999999997,-617918.3666666667,3,-604693.2,32,-602301.5,32,-588197.7,3.67,-586741.35,2,-576766.6,32,-568900.9,32,-567981,32,-567151.1,1,-566187.5,9.07,-561308.8,3,-548701,8.09,-531320.682051282,1.56,-516833.5,32,-514127.9,32,-503183.8,2.9099999999999997,-492470.2,8.29,-484719,32,-483800.4,1,-481397,32,-479762.9,9.31,-478988,8.73,-474560.8,0.72,-471491.7,4.59,-456521.5,1,-444583,5.609999999999999,-441206.9,1,-439908.9,32,-432294.4,1,-424407.7,32,-422360.5,5.97,-421216,32,-408597.4,1,-397044.1,5.279999999999999,-394173.7,32,-390229.3,5.2299999999999995,-382435.54458438285,3.9699999999999998,-361641.5,5.319999999999999,-323618.5333333333,3,-308742.7,32,-292870.1,32,-281333.35,2,-266883.9,5.9799999999999995,-247204.36666666667,3,-237523.99591836735,2.94,-225643.4,32,-217777.3,8.31,-214348.9,1,-203229.4,32,-190282.9,32,-188340.2,32,-180703.65000000002,4,-162153,32,-159803.2,1,-148420.6,5.87,-147573.8,6.069999999999999,-146390.9,1,-141064.6,32,-129862.2,3.13,-126929,32,-119302.4,9.81,-103786.86666666667,3,-92045.9,1,-89454.5,9.81,-76122.4,5.76,-76099.1,1,-69896.3,8.94,-69568.5,7.109999999999999,-61328.5,8.65,-55808.96666666667,3,-44949.95,2,-31409.7,32,-27863.333333333332,3,37396.1,1,50312.1,6.22,62520.54492753623,3.4499999999999997,66291.4,8.25,74713.7,32,80588.7,1,113553.7,32,116567.9,32,120544.1,32,125064.85,2,139835.8,32,142400.5,1.12,152795.1,32,153992.2,32,155194.8,32,159593.8,2,168826.9,8.799999999999999,186573.6,3,205055.83333333334,3,213378.6,5.13,216298.8,32,227278.8,1.24,242066.49659090908,3.5199999999999996,250804.76666666666,3,268455.5,0.84,272768.6,9.58,274440.1,6.819999999999999,277272.1,1,277815,6.31,281334.8,4.069999999999999,285839.2,8.82,287203.6,1,297427.2,32,300198.5,6.5,300894.6,1,303351.7,8.83,312340.8,2,312953.2,32,322751.3333333334,3,341505.06666666665,3,360382.7,5.62,373639.2241545894,2.0700000000000003,398271.5952380952,3.15,424925.5,1,451170,7.38,455220,8.19,455953.6,6.14,456954.3,1,457660.3,3.07,474118.5,1,474330.2,6.819999999999999,481320.4,3.1799999999999997,487140.8,2,499015.6,2.9499999999999997,499229.9,32,506818.7642857143,1.12,515665.4,8.99,521361.5,32,525634.3,2.8299999999999996,530804.6,32,538640.5,32,540083,9.51,556946.4,9.72,557463.7,1,570003.2,3.5,605082.3,1,627263.3,32,633977.5,1,643182.9,3.2399999999999998,644749,1,647792.8,3.1199999999999997,649896.1,4.77,664900.3,1,669169.1,32,677608.8,2,685495.1,2.5,703279.1654320988,1.62,749057.35,2,774082.3500000001,2,793846.8999999999,2,803825.75,2,809615.45,2,813763.3,32,823252.5,2,835125.8,32,835277.2,8.959999999999999,848623.2,32,849818.6,1,853977.9,1,854649.7,8.08,875520.3,4.819999999999999,883300.3,1,887844.4,1,898615.5,2.21,903478.8,1,923620.4,1,925890.3,1,937823.1,1.65,944156.5,5.45,949874.2,9.03,953747.2,1,962956.4,32,963025.1,1,967914.6,1,969162.1,32,979302.9,1,980402,1,981064.7,3.5199999999999996,989910.2,32,999214.8,1],null,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[1000],null,6922.329999999998,[7.623,7.635455427878788,12.685687358490537,113.22545557324838,265.63660818181813,479.75498242424237,758.0770269323673,917.316267030303,959.4741440625003,981.0339990088238,995.9368614309091,"NaN","NaN","NaN","NaN"],[0,0,0.009749541446297895,0.0970096458911471,0.5126495640198654,1],[1000,7.623,1,7.655,32,8.474,32,9.11,3.8299999999999996,13.625499999999999,2,14.924,9.97,17.133,1,17.498,32,18.632,1,21.193,32,23.588,32,25.146,1,26.417,32,28.374971786833857,3.19,29.802482428115017,3.13,30.262,32,32.35,1,34.326,32,37.15666666666667,3,38.633,5.88,39.006,32,42.0185,2,46.556,32,48.750725075528706,3.3099999999999996,50.381,32,52.229,32,53.872,7.4799999999999995,54.44033333333333,3,55.428,8.75,61.87097920997921,4.81,69.11,1,69.196,32,69.90169902912622,2.06,75.955,32,76.341,1,76.63,6.97,77.422,1,80.57,5.26,82.49066666666667,3,85.889,32,86.826,0.43,88.487,32,92.71075,4,96.357,32,97.131,32,98.941,9.299999999999999,107.60549999999999,4,112.927,5.68,113.488,32,114.755,32,117.96381758957655,3.07,122.699,32,125.342,1,125.429,32,128.028,1,130.346,8.29,130.351,1,131.159,8.87,136.34616666666665,6,141.459,7.38,142.0495,2,143.222,32,145.8145,2,148.464,32,149.09,9.9,149.284,32,150.953626984127,5.04,155.78,32,158.661,32,159.38,1,160.624,9.47,164.1041047835991,4.39,165.031,32,165.411,32,168.77,32,170.08,1,173.451,32,177.387,32,177.885,1,181.332,32,188.0015,4,194.588,32,196.392,1,202.793,32,204.44059543817525,8.33,209.06627785058978,7.63,216.05649716446123,5.289999999999999,218.116,8.27,218.4627533632287,4.46,223.579,32,224.142,8.52,227.01844345238095,6.72,229.9,32,231.187,32,235.0025,2,236.599,32,237.473,1.49,237.665,32,239.89172586872587,7.77,241.57264248704664,7.72,245.533,32,247.61294915254237,8.85,248.30683796856104,8.27,249.5745,2,251.133,32,252.527,32,253.66000000000003,2,257.013,32,259.0968962264151,8.48,264.317,32,265.084,1,266.65,32,266.859,2.42,267.242,32,267.6805,2,267.932,9.18,270.489,3,271.556,32,273.86127510917026,9.16,281.544,7.1899999999999995,281.997,32,282.5911505376344,4.65,284.229,5.2299999999999995,284.59745910290235,7.58,285.3847112462006,3.2899999999999996,288.049,32,290.539,1,290.964,32,294.505,1,295.517,32,295.9989420935412,8.98,299.989,1,300.59,32,302.9397106918239,9.54,306.026,1,307.056,32,308.314,7.279999999999999,309.9,8.62,312.156,32,315.55600000000004,4,317.783,32,325.65525,8,329.356,32,330.748,32,332.5465991041433,8.93,336.549,32,338.778,2.7199999999999998,339.881,8.93,340.019,32,346.1282809224319,9.54,354.1580374064838,8.02,356.586,2.4499999999999997,357.605,32,361.39749736008446,9.469999999999999,365.3684285714286,5.25,365.885,32,365.919,32,367.184,32,370.3043827160494,9.72,370.7005,2,371.033,32,372.133,1,374.403,9.69,375.926,32,377.712,6.64,378.057,9.11,379.174,32,383.3080197044335,10.149999999999999,392.31483470225874,9.74,402.6195,2,404.56,32,406.253,3,408.335,32,411.0507159309021,10.42,413.2042483156881,10.389999999999999,415.6218314606742,8.899999999999999,417.476,32,418.455,5.029999999999999,420.207,32,421.221,32,421.87271122994656,9.35,424.357,32,426.877,2,427.607,32,430.209,5.54,430.986,32,431.243,9.799999999999999,431.27,32,431.414,32,436.1150290262172,10.68,443.656,32,445.708,32,445.88,1,448.444,32,449.829,2,451.17,32,452.73546691871456,10.58,454.364,32,455.48,1,456.314,32,459.568,32,459.735,32,465.98825157232704,6.359999999999999,467.228,32,469.35766666666666,3,471.073,32,475.62068203650335,10.41,476.834,32,477.493,32,479.987,1,480.912,32,483.784,1,487.268,32,491.877,9.52,494.67889433237275,10.41,503.2227958687728,8.23,509.009,9.43,510.429,2.9699999999999998,513.243,32,515.357,32,519.8119093406594,7.279999999999999,520.292,32,520.9387208121827,9.85,522.495,32,522.7940000000001,2,523.368,32,524.804,1,524.829,32,529.4397434554974,7.64,532.0756484018265,8.76,535.4244796954315,7.879999999999999,537.5294943820224,4.449999999999999,540.416,32,541.5158383371826,8.66,546.049,32,547.118,1,547.615,32,548.1064737945493,4.77,549.019,32,549.661,1,553.908,32,555.9573267326733,6.06,558.088,32,559.8435,2,561.7639922405432,10.31,566.8296000000001,5,570.924,32,571.7880854126679,10.42,578.099923076923,6.5,581.707893877551,9.8,585.9408974358975,1.95,587.738,32,589.358288184438,6.9399999999999995,592.252,5.359999999999999,593.244,32,594.467,1,595.449,32,596.249,32,597.0773333333333,3,599.812,32,600.473,32,603.3083517786562,5.06,604.47,9.76,607.9788326359833,9.56,609.402861167002,9.94,615.658834532374,9.73,623.5474772277228,10.1,626.78075,4,629.209,32,630.677,1.11,632.312,9.79,633.508,1,634.047,32,636.2257672176308,7.26,640.4939970326409,10.11,641.23,1,642.58,32,645.342318275154,9.74,652.1242432432432,9.620000000000001,655.184038647343,10.35,660.7769765625,10.24,663.271,5.3999999999999995,663.559,9.91,665.6765,2,667.731,32,668.071,32,674.1404331550802,9.35,680.103,3,682.254,32,683.204,3,685.427,32,686.5723252769385,9.93,689.42,5.84,690.252,9.6,692.625,32,695.683,32,696.765,32,699.1353281086729,9.57,702.086,2,703.208,32,707.2725834633386,6.41,707.942,9.17,712.8040000000001,5,719.28,32,721.8625,2,722.559,9.15,723.4370287859825,7.99,723.527,32,723.66,32,723.742,9.34,729.8748571428572,7,734.951,32,739.7199879649892,9.14,748.6074285714286,7,751.41,32,753.0667479674796,8.61,754.3212549019607,3.57,755.1,32,755.383,32,756.677,9.4,758.178,32,760.6021905882353,8.5,761.717,1,761.891,32,762.029,32,763.5295000000001,2,764.138,32,765.7165,2,767.892,8,769.059,4.14,769.273,32,774.039,1,776.131,32,776.3385000000001,2,777.173,32,779.7024519774011,3.54,785.259,32,786.5279289940829,8.45,787.566,1,787.66,32,787.774,1,787.798,8.42,789.841,1.47,789.964,32,793.1420415430267,6.739999999999999,796.673,32,799.7724401913875,8.36,804.86,32,806.034,32,807.8760791366907,5.56,810.63,32,815.7536666666666,3,820.287,7.76,825.51075,4,828.371,9.15,831.264424068768,6.9799999999999995,834.345,32,842.021375,8,849.422,32,850.944,1,852.214,32,852.531,8.92,856.7936766712141,7.33,860.561,8.53,862.683,32,865.275,1.67,866.553,32,866.8105465288036,6.77,870.7831779661017,4.72,875.061,9.26,876.0960107816712,7.42,878.5063333333333,3,885.743,32,886.49,1,887.063,32,887.1921552062869,5.09,887.672,3.42,887.878,32,889.8197098865478,6.17,890.962,6.56,891.6445000000001,2,891.78,32,896.586,8.36,897.873,1,898.593,6.069999999999999,898.676,32,900.1417228915662,5.81,902.1756567656765,6.06,902.508,1,903.862,6.6899999999999995,903.911,1,908.403,32,908.9225,4,913.2967948717949,3.9,913.957,7.029999999999999,917.253,1,917.411,32,917.428,1,920.335,32,923.215,2.48,923.503,6.46,924.5111252955082,4.23,928.242,5.56,928.923,2,929.845,32,933.5438269896194,5.78,939.8683333333333,3,942.607,32,942.734,1,943.605,32,944.615,32,946.4186666666667,3,950.41,32,951.898,9.15,953.059,32,954.175,1,955.109,8.45,955.6448709677419,4.65,956.653,7.66,957.82,1,958.413,32,959.79675,4,962.713,32,963.898,32,964.093,6.75,964.154,1,967.484,32,970.43,32,970.7236666666666,3,971.855,1,972.99,9.47,973.337,32,974.759,32,974.773,1,974.983,7.26,976.799,2,977.894,2,979.302,1,979.312,32,979.985,4.24,980.7695,2,981.414,32,982.454,1,984.344,2.44,987.976,2.8299999999999996,991.428,1.93,994.004,1,995.814,32,995.997,1,997.283,1]]}, +{"name":"random 27","compressions":[33.5],"ops":[{"op":"toJSON","d":0},{"op":"reset","d":0},{"op":"add","d":0,"values":[[28.477,32],[12.174,"Infinity"],[50.062,1],[19.58,1],[103.939,1],[5.761,8.12],[58.698,32],[4.911,4.6499999999999995],[34.324,0.26],[46.424,1],[42.556,1],[28.376,1],[0.695,1],[73.716,7.1899999999999995],[5.875,1],[62.165,1],[23.092,1],[12.413,1],[2.33,9.44],[16.442,32],[11.278,1],[42.468,32],[29.192,32],[8.423,1],[29.72,32],[4.97,2.9],[55.284,1.79],[33.957,1],[48.717,2.32],[2.401,32],[63.215,0.35000000000000003],[4.546,1],[119.804,9.44],[28.547,8.32],[130.154,1],[3.76,7.88],[8.862,1],[55.294,1],[22.821,1],[2.239,32],[40.621,1],[121.914,1],[30.391,32],[45.232,1],[6.203,0],[12.386,6.569999999999999],[20.781,1],[12.759,1],[38.159,1],[4.495,1]]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0}],"expect":[[33.5],null,null,[0.695,0.695,1.0068224969696968,2.3320662644787644,6.269741772086456,28.735604910714287,37.28501222209077,58.10136880896506,65.45766306271145,120.97125038314176,130.154,130.154,"NaN","NaN","NaN"],383.23,[0.695,0.695,1.0068224969696968,2.3320662644787644,6.269741772086456,28.735604910714287,37.28501222209077,58.10136880896506,65.45766306271145,120.97125038314176,130.154,130.154,"NaN","NaN","NaN"],[0,0.009809751824517508,0.27018931370785865,0.9674511226070657,1,1],[33.5,0.695,1,2.239,32,2.33,9.44,2.401,32,4.233031658637302,14.529999999999998,6.3668655126498,15.02,12.432674445740957,8.57,16.442,32,22.93,5,28.477,32,28.547,8.32,29.192,32,29.72,32,30.391,32,37.319398773006135,3.26,42.468,32,49.56638858397365,9.11,58.698,32,62.437222222222225,1.35,73.716,7.1899999999999995,103.939,1,119.804,9.44,121.914,1,130.154,1]]}, +{"name":"random 28","compressions":[33.5,33.5,100],"ops":[{"op":"add","d":0,"values":[[400.968,4.79],[248.303,1],[451.066,8.49],[102.023,32],[145.344,1.75]]},{"op":"reset","d":1},{"op":"add","d":0,"values":[[6,32]]},{"op":"merge","d":2,"from":1},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,null,null,80.03,[6,6,6,6,18.025380390625,78.06226078124999,157.90471226945718,422.71234277108437,451.066,451.066,451.066,451.066,"NaN","NaN","NaN"],[0,0,0.216581456521356,0.5913510956765822,1,1],[33.5,6,32,102.023,32,182.78363636363636,2.75,400.968,4.79,451.066,8.49],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[33.5],0,["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[0,0,0,0,0,0],[100]]}, +{"name":"random 29","compressions":[100,1000,33.5],"ops":[{"op":"add","d":0,"values":[[17,32],[13,32],[4,3.82],[12,1],[6,1],[4,2.0799999999999996],[11,2.3699999999999997],[10,5.76],[16,1],[0,1],[0,1],[16,5.42],[9,0.19],[18,1],[8,1],[5,1],[5,32],[10,1],[3,1],[1,1],[12,1],[16,1],[2,1],[14,32],[7,2.46],[5,32],[14,4.27],[18,4.3999999999999995],[5,1],[3,1],[4,1],[13,9.32],[8,2.7199999999999998],[15,1],[18,32],[10,3.4499999999999997],[4,1.33],[4,3.2399999999999998],[5,1],[10,32],[4,1],[8,1],[9,32],[12,32],[10,1],[18,1],[19,8.459999999999999],[0,1],[15,9.74],[10,1]]},{"op":"add","d":2,"values":[[4777.9,-1],[-797766,"NaN"],[635075.9,1],[188930.7,2.36],[633893.5,1],[-98639.1,32],[974425.8,-1],[-43175.1,3.19],[853056.7,1],[-31238.5,1],["NaN",1],[504302.8,6.77],[-924375.4,1],[405885.2,3.5799999999999996],[-178622.8,1],[910927.2,32],[619970.6,3.71],[-240738.5,32],[650330.3,1],[580920.6,32],[-697961.9,32],[-959463.9,1],[-306986.8,4.41],[-166818.8,2.78],[849462.1,32],[925509.8,1],[-786299.5,1],[611489.3,32],[74815,1],[980344.4,4.96],[712208.4,5.09],[-907316.6,32],[-197032.3,1],[364050.3,32],[-893990,32],[-493921.5,0],[-900742.6,1],[-71916.1,9.1],[729888.9,1],[812389.9,1],[-522301.6,1],[-316317.2,32],[-801521.9,32],[-768882.6,1],[372821.5,8.73],[-945415.1,4.74],[-38790.6,32],[345868.5,7.6899999999999995],[-568207.7,1],[-417649.6,1],[-661690.6,6.99],[-571966.9,32],[787553.5,32],[206954.8,32],[150182.5,0.64],[-418371.3,1],[-751276.5,32],[737520.1,1],[-842982.9,3.23],[759965.3,32],[764910,1],[547884.7,32],[-832818,1],[491420.6,0.31],[-709431.3,1],[982569.3,7.27],[369032.4,32],[887345.7,1],[935272.2,32],[-453951.8,1],[-192688.7,1],[274498.8,1],[635487.1,8.07],[-113265.7,9.41],[979800.8,1],[361033,0.41000000000000003],[663051.3,7.96],[30497.6,1],[74784.2,1],[-272820.2,1],[376589.1,0],[-761706.5,1],[-559533.8,"Infinity"],[974437.9,1],[-400862.6,32],[546181.7,6.72],[18649.6,32],[-757347.9,4.68],[-880877.9,2.34],[-29366.1,32],[289933,8.72],[-891218,1],[382781,32],[755257,32],[-877218.1,1],[-905512.9,6.04],[-328550.6,9.629999999999999],[-260960.2,32],[719206.6,32],[246884.8,1],[-929719.1,1],[-284694.9,32],[-841161.7,-1],[-566349.4,1],[-122181.3,32],[786783.8,9.47],[-243631.1,1],[685170,1.51],[-379179.2,2.92],[330114,1],[-814700.3,32],[322301,1],[-191892.3,32],[-110668,1.58],[56376.4,1.11],[398298.4,1],[546831.9,1],[438407.3,32],[-487296.8,2.3],[-521106.7,1],[-952964,1],[-987560,"Infinity"],[-80147.8,1],[936280.3,1],[-136168.5,32],[-298746.1,1],[940753.4,1],[-665432.2,1],[-785533,1],[-117365.1,1],[-414034.3,1],[895060.9,8.459999999999999],[992067.6,1],[-52179.3,1],[610694.2,9.94],[-852346.3,1],[864586.2,3.2199999999999998],[210543.2,3.7199999999999998],[-387185.2,1],[202084.8,1],[-404841,32],[-586055.1,1],[-890174.7,1],[-190482,1],[473530.8,1],[-466397.3,2.3299999999999996],[-570169.2,1],[235029.1,0.62],[485235.5,1],[450950.3,1],[761913.9,1.14],[817044.9,1],[-893631.6,"Infinity"],[953035.6,32],[-688547,32],[103906.9,1],[-145166.2,32],[495404.5,32],[-861441.9,32],[185562.1,1],[-211043.5,1],[-2213.9,6.21],[417957.4,32],[-525881,1],[406072.5,1],[453809.8,1],[616585.8,4.8999999999999995],[6804.5,1],[278493.9,1.8],[429648.5,9.2],[520246.9,1],[722758.3,1],[369253.1,1],[-33217.3,32],[-97776.4,1],[876861.9,1],[75355.8,1],[-79990.6,1],[347779.2,3.63],[-352258.6,32],[-204254.8,32],[-251726,1],[-500886.4,8.24],[-604079.7,1],[839846.9,1],[734018.5,0.87],[-188689,1],[653821.3,1],[-157776.5,32],[182738.5,32],[160715.5,-1],[91876.2,1],[576467.3,32],[804009.8,1],[-772069.6,1],[-428174.5,7.1499999999999995],[-84948.6,4.76],[544780.2,1],[731018.2,4.96],[-774766.5,32],[-112908.5,1.54],[-243548,1],[-199144.4,1.67],[567138.1,3.84],[367928.3,-1],[169730.9,1.41],[-252163.5,1],[282984.5,1],[-676007.7,1],[-928171.2,1],[29000.1,32],[775659.8,1],[-493880.1,7.4799999999999995],[-736823.7,1],[-218410.5,32],[-755915.5,2.4499999999999997],[983938.7,1],[914137.9,32],[-591610.1,1],[361146.1,1],[-459933.9,1],[-59169.5,0],[-704181.6,1],[-406171.1,3.5999999999999996],[-961200.7,0.06999999999999999],[74421.4,32],[522255.9,4.55],[178327.6,"NaN"],[-55819.1,1],[-231596.8,32],[-640062.5,1],[155004.3,1],[-255330.4,32],[567858.2,1],[-644123.4,7.609999999999999],[-245074.8,1],[979524.3,1],[576349.8,1],[64591.1,32],[748315,1],[838431.8,1],[-828939.1,6.3999999999999995],[805964.8,1],[813463.7,1],[269246.6,4.68],[-646675,1],[-732593,5.09],[-910744,1],[652007.4,32],[529655.3,1],[-841030.2,8.43],[-933545.1,1],[-38019,0.62],[468475.3,0.42],[943334.7,3.9],[-718331.4,32],[-614643.1,1],[-401785.7,1],[344661.4,1],[-137832.6,1],[-185767.8,1],[-660199.8,1],[884177.5,1],[181763.8,"NaN"],[-691348.7,6.83],[-100517.4,7.89],[386563.7,0.49],[-50438.1,1],[-497968.3,4.029999999999999],[220635.1,32],[905743.5,5.7299999999999995],[-453465,32],[402385.2,32],[-629962.1,1],[464394.3,5.6899999999999995],[-665015.1,1],[-444367.7,1],[-329074,32],[267956.1,1],[-699773.8,1],[-258180.3,32],[984516.8,1],[77301.2,1],[657101.9,1],[-161396.9,1],[223808.7,1],[-415387.2,1],[-89376.1,1],[-732489.3,1],[-997327.1,1],[-321359.6,0],[-17624.2,1.68],[-816884.3,1],[-239063.5,1],[-325092.3,1],[-955142.1,1],[75097.1,1],[561247.3,5.25],[-571001.2,1],[-488249.3,1]]},{"op":"add","d":1,"values":[[1,1],["NaN",1],[14,32],[8,4.72],[8,1],[11,1],[3,1.34],[7,0.65],[9,1],[11,1],[2,4.08],[19,1],[2,1],[15,1],[8,1],[18,1],[17,1.55],[7,1],[15,1],[18,4.13],[18,2.42],[19,32],[10,1],[3,1],[4,1],[7,32],[5,8.709999999999999],[18,1],[5,1],[8,1],[12,6.29],[14,32],[15,1],[1,9.76],[0,32],[11,1],[3,0],[7,1],[2,1],[0,32],[2,1],[16,32],[9,8.99],[19,32],[1,4.87],[12,1],[8,1],[1,3.0199999999999996],[2,1],[17,9.92]]},{"op":"add","d":0,"values":[[94.804,32],[386.702,1],[540.878,4.47],[974.143,32],[785.783,32],[279.84,1],[515.31,1],[224.043,1],[877.7,1],[598.065,3.9299999999999997],[374.876,5.1499999999999995],[922.095,1],[16.665,3.63],[199.214,0.84],[783.757,7.81],[519.802,32],[271.267,32],[590.21,5.859999999999999],[554.905,1],[232.151,1],[736.563,1],[532.116,32],[398.967,32],[489.5,1],[614.822,9.45],[123.254,"Infinity"],[832.696,1],[326.756,6.42],[187.913,1],[849.116,1],[412.346,32],[451.274,1],[672.951,3.78],[616.95,32],[529.774,32],[287.429,1],[859.814,"NaN"],[940.146,1],[365.944,6.27],[241.673,32],[928.927,32],[520.054,32],[428.293,1],[839.905,1],[136.612,1],[851.841,7.26],[88.266,32],[524.636,1],[926.472,1],[7.82,7.22],[108.474,5.819999999999999],[994.578,1],[299.26,32],[417.912,1],[3.875,1],[915.314,1],[741.661,1],[415.516,1],[664.505,1],[82.966,1],[283.374,5.92],[61.187,1],[402.611,1],[937.346,1],[468.763,2.48],[196.096,1],[871.968,1],[19.439,32],[973.226,1],[826.567,9.61],[112.137,1],[693.83,32],[585.843,"NaN"],[576.487,1],[763.453,1],[43.775,1.36],[747.097,1],[724.244,1],[122.13,32],[398.326,32],[722.297,1],[809.257,32],[786.145,1],[642.636,32],[862.306,32],[691.525,32],[514.004,1],[93.257,1],[353.35,1],[194.433,1],[13.68,32],[867.612,1],[434.113,1],[275.114,1],[868.521,1],[637.303,32],[187.622,1],[497.653,1],[919.246,1],[528.175,32],[763.229,9.53],[474.376,3.36],[586.443,1],[297.488,1.12],[265.739,1],[583.02,32],[743.423,1],[270.002,4.359999999999999],[810.357,32],[398.696,32],[180.239,1],[277.305,1],[670.468,1],[933.909,32],[901.233,"Infinity"],[196.79,1],[872.723,1],[611.482,32],[194.131,1],["NaN",7.2],[23.389,9.02],[914.292,32],[91.827,9.49],[949.706,8.959999999999999],[953.198,1],[907.961,1],[538.323,1],[678.18,1],[450.948,1],[582.612,1],[907.927,3.17],[588.351,1],[684.421,32],[586.823,3.36],[834.318,1],[935.409,1],[298.822,32],[623.341,1],[405.846,1],[811.853,1],[218.125,32],[250.65,1],[999.418,1],[681.801,4.87],[332.771,7.3999999999999995],[678.639,1],[232.104,1],[406.172,1],[305.357,1],[636.417,1.1300000000000001],[654.403,1],[247.831,2.63],[131.409,32],[418.581,5.9399999999999995],[260.996,2.05],[923.19,1],[924.081,32],[634.184,2.0399999999999996],[426.84,-1],[56.459,32],[672.364,1.69],[684.858,1],[818.482,1],[202.315,1],[309.409,0],[515.13,1],[94.621,"Infinity"],[709.561,9.74],[844.811,0.34],[933.296,32],[557.351,9.95],[557.686,1],[988.917,1],[110.162,1],[861.836,1],[850.333,1],[251.931,32],[412.608,4.54],[352.589,1],[247.045,-1],[147.931,1],[447.761,9.959999999999999],[673.774,8.7],[795.946,1],[128.557,1],[779.792,1],[409.913,1],[353.558,1.84],[443.786,32],[591.792,1],[237.78,1],[486.732,1],[509.782,32],[543.278,32],[334.844,32],[790.944,1],[43.894,1],[783.109,1],[713.423,"Infinity"],[71.443,32],[966.362,32],[253.267,1],[34.707,32],[44.584,3.98],[111.291,4.1],[435.465,1],[161.777,1],[838.807,1],[987.23,1],[158.65,1],[247.873,1],[597.649,1],[712.144,1.48],[451.478,1],[969.986,32],[475.155,1],[480.911,1],[126.798,1],[489.036,1],[873.212,1],[253.576,1.19],[456.143,1],[636.038,0.64],[146.135,2.9099999999999997],[941.969,9.69],[201.591,1],[883.847,3.6199999999999997],[710.003,1],[734.392,1],[362.522,0.04],[4.231,1],[754.413,1],[462.488,4.51],[3.629,4.779999999999999],[851.741,1],[593.495,32],[339.977,1],[566.169,-1],[700.775,32],[673.667,32],[941.178,32],[408.891,1],[564.581,32],[539.083,1],[535.211,32],[486.42,9.03],[638.163,2.48],[904.494,1],[405.026,7.359999999999999],[651.32,1],[51.279,2.01],[395.912,5.66],[712.687,32],[166.207,"Infinity"],[686.062,1],[640.474,8],[55.255,32],[239.283,1],[529.516,1],[788.752,1.6300000000000001],[925.808,"NaN"],[52.646,3.8],[645.947,1],[95.072,1],[760.377,3.36],[266.467,1],[104.023,3.3699999999999997],[440.619,32],[481.097,8.26],[247.089,32],[73.991,32],[265.116,1],[914.318,1],[282.935,32],[564.705,1],[10.18,0.56],[475.143,1],[848.194,1],[142.599,1],[780.545,6.66],[697.821,32],[954.333,1],["NaN",1],[840.142,"Infinity"],[870.498,1],[286.918,1],[116.63,32],[69.763,1],[341.484,1],[428.017,1],[904.641,1],[480.267,3.7199999999999998],[716.237,1],[855.379,4.47],[174.755,1],[806.474,32],[270.228,3.7899999999999996],[235.604,1],[234.058,"Infinity"],[616.545,1],[156.683,4.38],[125.852,1],[227.062,4.47],[603.309,9.54],[66.754,-1],[947.576,8.049999999999999],[184.261,2.1999999999999997],[569.813,1],[501.193,1],[460.388,32],[156.136,1],[711.257,32],[486.094,3.4899999999999998],[932.612,1],[30.283,1],[560.337,3.76],[453.914,1],[881.691,32],[416.265,7.87],[50.954,1],[697.361,1.15],[905.471,1],[571.702,32],[601.754,1],[220.672,-1],[499.158,32],[465.73,1],[556.489,32],[752.625,1],[250.554,32],[523.851,1],[685.215,32],[258.181,1],[674.467,1],[28.231,8.12],[987.618,32],[699.191,0.86],[107.392,4.71],[119.629,1],[771.362,"NaN"],[396.224,1],[760.946,3.1599999999999997],[890.715,1],[49.566,32],[466.227,32],[516.486,1],[124.688,4.76],[647.994,1],[888.493,0.08],[714.01,1],[920.722,32],[871.729,8.7],[331.457,1],[309.131,32],[523.783,1],[930.597,1],[188.205,0],[471.948,10],[637.874,1],[540.298,1],[343.226,1],[551.004,1],[699.399,32],[595.165,32],[913.904,1],[27.375,8.14],[624.022,1],[348.719,32],[142.503,1],[493.747,1],[456.302,7.13],[926.455,1],[88.672,1],[898.213,-1],[946.231,2.69],[16.404,4.12],[404.524,9.709999999999999],[884.277,32],[856.315,1],[149.173,1],[741.895,1],[737.093,1],[137.639,1],[239.523,1.68],[175.016,9.82],[339.76,6.3],[266.267,8.02],[630.149,32],[244.475,1],[330.156,1],[509.799,1],[92.916,1],[322.1,32],[134.25,1],[575.676,3.42],[555.124,32],[323.578,1],[413.713,1.77],[482.746,5.83],[476.961,1],[700.351,1],[136.848,5.1899999999999995],[553.885,1],[350.962,1],[548.926,1],[396.263,0.68],[654.157,6.91],[751.741,2.88],[601.756,32],[296.903,1],[999.253,32],[659.276,32],[758.292,1],[255.275,1],[587.027,1],[267.636,32],[831.505,-1],[750.919,1],[350.481,1],[553.998,7.02],[360.197,-1],[611.529,32],[918.359,1],[843.09,7.6899999999999995],[492.622,2.21],[930.09,1],[480.024,1],[319.345,32],[269.165,32],[534.392,32],[824.403,32],[43.12,1],[273.776,32],[232.999,1],[343.915,32],[672.951,32],[109.997,1],[350.126,4.85],[94.85,1],[225.538,1],[818.533,1],[672.41,0],[801.127,1.72],[169.616,1],[516.845,1],[831.228,1],[331.018,1],[102.222,8.629999999999999],[287.807,1.08],[507.2,1],[435.257,8.53],[867.662,32],[792.394,1],[928.613,0.6],[136.388,32],[35.296,1],[297.87,1],[627.329,1],[513.439,32],[776.789,32],[181.06,32],[662.926,1],[994.287,1],[976.058,2.17],[147.765,32],[204.193,1.53],[19.31,1],[623.27,1],[764.893,"NaN"],[945.531,1],[416.041,0.76],[555.047,32],[309.276,"Infinity"],[80.855,1],[974.419,0],[266.587,4.8999999999999995],[857.043,1],[243.096,32],[866.803,"NaN"],[939.121,1],[384.464,1],[754.042,5.08],[540.913,5.42],[116.054,1],[906.135,1],[982.323,1],[12.693,32],[776.209,32],[901.04,-1],[365.818,1],[578.849,32],[811.446,1],[760.634,32],[417.944,1],[343.203,1],[559.023,32],[442.915,0.39],[541.25,1],[437.056,32],[112.646,1],[706.4,1],[1.947,32],[869.569,32],[69.208,1],[145.122,"Infinity"],[223.673,1.26],[482.884,1],[574.452,1],[87.996,1],[608.98,32],[898.661,1],[73.725,1],[699.621,3.82],[823.641,1],[59.3,32],[96.557,8.83],[919.621,32],[885.116,3.0399999999999996],[635.626,1],[83.322,5.37],[501.546,1],[238.155,32],[614.604,32],[909.092,1],[973.644,1],[176.442,1],[951.812,6.9399999999999995],[895.57,1],[407.563,6.4799999999999995],[373.232,32],[319.348,0],[15.583,1],[527.416,1],[218.355,1],[865.783,2.8099999999999996],[927.875,0.29000000000000004],[931.686,2.36],[272.07,32],[34.98,1],[978.018,1],[802.041,0.91],[643.273,1],[577.414,"NaN"],[829.222,32],[977.072,32],[407.508,1],[41.741,1],[203.407,2.2399999999999998],[827.365,1],[185.815,3.03],[958.709,32],[86.358,1],[13.063,2.5799999999999996],[483.534,1],[440.111,8.33],[169.952,5.819999999999999],[14.348,32],[39.026,1],[114.095,6.66],[711.444,1],[293.966,32],[841.334,7.7299999999999995],[598.042,1],[366.234,7.06],[814.615,1],[895.236,1],[138.376,1],[679.488,32],[508.502,1],[526.461,0.2],[234.327,1],[167.306,32],[18.367,1],[521.389,1],[405.016,32],[160.907,4.96],[607.535,6.16],[451.021,0.05],[710.227,8.82],[564.09,1],[128.919,6.1899999999999995],[717.817,6.6],[901.872,1],[416.724,1],[382.073,6.87],[47.032,"Infinity"],[112.897,1],[822.946,1],[804.029,1],[491.746,1],[698.907,32],[13.775,1],[62.207,1],[13.383,1],[168.458,1],[914.612,32],[615.897,32],[166.483,1],[77.338,32],[557.292,32],[175.138,32],[63.446,1],[457.058,1],[467.265,1],[606.504,5.3],[433.068,8.43],[108.802,1],[230.325,32],[918.027,9.69],[873.374,1],[617.463,9.22],[318.495,1.3],[46.352,32],[157.437,6.62],[289.179,1],[456.368,2.3899999999999997],[26.225,1],[851.692,32],[229.367,1],[853.68,1],[180.472,1],[884.413,1.22],[507.541,1],[91.167,0.8200000000000001],[545.636,1],[284.819,1],[859.178,4.6899999999999995],[745.417,4.49],[130.183,1],[320.888,1.6],[873.187,0],[792.904,32],[550.155,3.26],[988.746,0.86],[364.152,1],[651.457,9.17],[631.681,"Infinity"],[87.674,1],[796.201,1.48],[221.878,32],[178.494,0],[189.961,1],[242.747,9.27],[994.111,7.29],[562.492,2.96],[449.727,1],[487.678,1],[392.697,1],[699.83,1],[120.481,1],[510.782,1.1300000000000001],[427.127,1],[189.296,32],[992.754,1],[16.843,32],[160.457,1],[287.842,1],[558.973,1],[231.525,1.66],[493.759,1],[585.389,0.58],[298.833,1],[496.821,1],[497.75,1],[427.063,1],[870.272,1],[728.455,1],[562.794,1],[932.564,32],[833.732,1],[468.363,1],[925.241,1],[1.925,1],[879.08,1],[713.633,1],[351.509,1],[909.273,1],[835.744,32],[993.836,1],[748.037,32],[342.644,0.25],[619.121,1],[457.248,0],[4.869,1],[686.1,1],[445.538,3.0399999999999996],[794.98,1],[29.245,0.4],[449.921,32],[500.064,32],[819.75,1],[349.066,1],[476.101,32],[644.47,1],[87.262,32],[396.342,32],[976.494,1],[143.304,4.24],[762.176,4.74],[233.232,3.46],[191.295,0.75],[588.505,32],[579.373,1],[405.431,1],[621.883,1],[28.129,1],[941.969,1],[707.868,4.45],[641.149,5.9799999999999995],[12.941,1],[499.751,1],[794.729,1],[65.065,3.3899999999999997],[780.12,5.74],[856.195,32],[289.925,32],[95.083,1],[671.196,32],[286.772,32],[516.528,1],[703.27,3.32],[23.401,1],[352.442,1],[793.799,1],[801.714,1],[858.144,32],[339.255,1],[392.809,9.77],[465.305,7.6499999999999995],[904.035,1],[651.187,1],[371.331,1],[104.851,4.7],[264.338,1],[458.588,1],[732.067,32],[356.349,32],[281.852,32],[24.631,32],[303.084,1],[70.901,9.26],[716.909,32],[165.917,1],[669.047,1],[807.867,1],[351.766,32],[93.937,5.06],[602.54,6.68],[277.488,1],[422.153,1],[386.962,1],[314.347,32],[451.962,1],[573.37,1],[219.438,1],[230.279,1],[93.698,1],[465.103,1],[972.59,1],[742.214,7.77],[783.117,32],[266.608,4.31],[493.327,1],[634.563,"Infinity"],[403.655,1],[952.638,32],[22.7,6.31],[978.326,3.3899999999999997],[702.535,32],[4.242,0.56],[545.915,1],[449.581,1],[58.303,4.4399999999999995],[224.313,7.46],[578.078,32],["NaN",1],[205.499,1],[369.533,32],[635.035,1],[354.225,6.95],[350.242,32],[267.933,3.6599999999999997],[261.706,1],[742.342,1],[951.495,9.799999999999999],[764.281,32],[450.353,1.09],[502.517,1],[453.722,6.09],[846.661,4.96],[172.188,4.6],[684.152,4.7],[346.883,6.2299999999999995],[417.493,4.12],[596.592,1],[131.187,32],[344.682,1],[834.37,1],[746.727,1],[500.304,0],[364.702,32],[363.225,32],[799.866,0],[890.188,8.82],[966.705,7.4799999999999995],[735,1],["NaN",32],[50.189,32],[774.747,1],[617.998,7.6499999999999995],[413.957,1],[922.588,1],[467.551,9.52],[217.161,1],[105.028,1],[826.541,8.49],[70.543,32],[243.26,5.9399999999999995],[514.672,1],[528.938,32],[897.397,0],[986.33,6],[246.437,1],[383.127,2.8299999999999996],[466.925,1],[670.381,7.64],[325.013,32],[112.964,32],[178.539,32],[131.77,1],[675.889,4.18],[424.54,1],[130.814,1],[486.966,32],[958.91,1],[164.927,3.7899999999999996],[202.27,1],[493.851,4.6499999999999995],[527.048,32],[514.844,1],[698.694,1],[372.703,1],[982.207,1.03],[296.341,1],[460.655,32],[617.69,32],[691.029,1],[271.688,0.63],[619.145,4.79],[248.202,1]]},{"op":"count","d":0},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":0,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":0},{"op":"count","d":1},{"op":"quantile","d":1,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":1,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":1},{"op":"count","d":2},{"op":"quantile","d":2,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"cdf","d":2,"x":[0,1,10,100,500,999]},{"op":"toJSON","d":2}],"expect":[null,null,null,null,7589.369999999999,[0,1.0412236987499999,4.931302583275351,48.38227476917769,236.9228555378134,484.63512070893086,699.8075469785923,884.2658376164078,937.74856828662,984.9084674537014,999.3471063000001,"NaN","NaN","NaN","NaN"],[0,0.0009195790023452535,0.023783924093831243,0.1581223413485164,0.5115276090970725,0.9976338207401054],[100,0,1,0.73125,4,1.947,32,3.6532404467960027,17.009999999999998,4.286605128205128,7.800000000000001,5,32,5,32,7.342262649232518,17.59,9,32,10,10.209999999999999,10.066904955320876,36.93,12,34,12.700515151515152,33,13.012150111358576,44.9,13.682878787878787,33,14,36.269999999999996,14.74861219702893,51.160000000000004,16.781243522012577,39.75,17.144385026737968,37.4,18.233248964565117,43.46,20.683939168218497,48.33,25.872923344947736,51.66,36.586509460083064,43.339999999999996,48.1032799582152,67.01,50.189,32,55.67703244837759,67.8,62.107412275836566,54.089999999999996,70.543,32,72.73250769230769,65,82.56673578055667,74.37,89.8300835117773,51.370000000000005,100.55941431353455,82.15999999999998,112.964,32,119.6541201164766,82.42,131.20466666666667,33,134.0120870356883,82.38,152.16057309417042,66.9,171.85319769503545,90.24,178.539,32,187.94809596951148,86.59,221.1478074287775,83.19,234.31003676092547,77.80000000000001,242.63412103150472,82.21,248.79636500072857,68.63,261.3594417975658,96.13,270.21654685353116,72.78,275.96083,100,284.9370610526315,76,294.4021910601266,101.12,307.6545871097684,99.3,322.65822009110525,83.42,335.3171810225702,108.55,350.1017438096923,113.08,362.5761675909494,90.16,364.89188279522335,67.83,385.8430412848759,97.13,399.27436672546656,107.71,410.41526419366073,114.84000000000002,437.4244717625155,96.68,448.81144732530106,103.75,460.655,32,465.42360164025064,108.52,483.73592516426316,117.19,503.4339275646411,107.13,517.9674458955225,107.2,527.9929999999999,64,530.0164536082474,97,537.9981719901721,109.89,554.4134810662681,80.28,557.591750347383,107.95,567.9987966477694,81.14,580.4589374880885,104.94,592.4049272624221,105.86,604.8351444984991,96.61,612.7429862494073,105.45,617.2313657102121,112.22,633.0442924480994,99.71000000000001,653.1859846029174,98.72,672.7431515380974,105.65,681.1052633592211,86.27,690.2826510133466,101.15,698.7132795787735,96.86,702.9111089219747,89.32999999999998,711.8736559386972,78.3,727.9447745098038,94.85999999999999,755.0276100657447,88.21999999999998,769.3294369124851,75.53,780.3892085604919,86.21000000000001,790.506768986538,78.74,807.8655230769231,65,818.373948192322,80.49,831.7539237532973,79.61,849.0885655703289,71.45,857.3523060398941,71.69,865.1062233686964,68.81,870.6176036960985,48.7,883.0302002366165,67.62,906.1917683562293,63.33,915.5557088834191,44.69,919.621,32,920.8850571428572,35,924.3525090554473,35.89,929.1839922992299,36.36,932.5654545454545,33,933.296,32,934.3641666666667,36,941.7472401897371,46.379999999999995,950.1504841481482,33.74999999999999,952.7043235294118,34,958.7150909090908,33,966.362,32,966.705,7.4799999999999995,970.2574857142856,35,974.143,32,976.1955394321767,3.17,977.072,32,983.1407861400894,13.42,987.618,32,993.2899429657795,13.15,999.253,32,999.418,1],352.45,[0,0,0,0,2,13.005454545454544,16.76944858420268,19,19,19,19,19,"NaN","NaN","NaN"],[0,0.23021705206412263,0.4472691161866932,1,1,1],[1000,0,32,0,32,1,1,1,9.76,1,4.87,1,3.0199999999999996,2,4.08,2,1,2,1,2,1,2,1,3,1.34,3,1,4,1,5,8.709999999999999,5,1,7,0.65,7,1,7,32,7,1,8,4.72,8,1,8,1,8,1,8,1,9,1,9,8.99,10,1,11,1,11,1,11,1,12,6.29,12,1,14,32,14,32,15,1,15,1,15,1,16,32,17,1.55,17,9.92,18,1,18,4.13,18,2.42,18,1,19,1,19,32,19,32],2480.9199999999996,[-966137.8744471745,-964133.1282440445,-913972.6958517625,-759657.2196257567,-363894.01152839966,-59654.234216580284,489266.4529441474,778918.7804788777,912358.5103030303,965481.3624360434,988541.4891581293,992067.6,"NaN","NaN","NaN"],[0.536355354624883,0.5363559530305624,0.5363613386816761,0.5364151951928133,0.5366545574645343,0.5369531618985063],[33.5,-966137.8744471745,4.07,-935094.6995893224,9.74,-907316.6,32,-904835.3005681818,7.04,-892542.7178896626,37.34,-855541.4904292597,45.66,-817068.6329949239,39.4,-800603.9205882354,34,-771221.6436506051,42.13,-733419.5015521663,74.09,-688008.6765460768,81.82,-554265.7804173355,80.99,-427257.6029102167,80.75,-376078.919965177,68.92,-322229.4859058704,79.03999999999999,-267995.3917525773,97,-242750.0911764706,102,-202562.41228215763,108.45,-146282.38144329897,97,-101338.38282634511,109.46999999999998,-31314.71932212938,106.51,37936.41513469882,99.11,154308.27742420224,113.13,297063.90751864744,100.54999999999998,375827.2827439511,75.22,412225.1339161738,77.78,480398.6855069459,96.46,562629.2532827273,75.09,601037.8225192195,84.55,657496.2172653131,57.629999999999995,736635.0246105919,73.83,766170.8996189197,44.61,793150.3538461538,39,865574.2750982962,53.41,910927.2,32,914482.503030303,33,936273.0720316622,37.9,953035.6,32,979431.0582914574,7.96,982927.1101402374,9.27,992067.6,1]]}, +{"name":"empty, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[100]]}, +{"name":"one value, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,5,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[5,5,5,5,5,5,5,5,5,5,5,5,"NaN","NaN",5],[100,5,1]]}, +{"name":"two values, sampled weight, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,0,32,3,32]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,0,0,1.5,3,3,3,3,3,3,"NaN","NaN","NaN"],[100,0,32,3,32]]}, +{"name":"ignored values, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,0,1,0,1,2,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,0,0,0,1.5,2,2,2,2,2,"NaN","NaN","NaN"],[100,0,1,0,1,2,1]]}, +{"name":"fromJSON, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,2,1,5,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[2,2,2,2,2,3.5,5,5,5,5,5,5,"NaN","NaN","NaN"],[1000,2,1,5,1]]}, +{"name":"merge into itself, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,1,1,1,1,2,1,2,1,3,1,3,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[1,1,1,1,1,2,3,3,3,3,3,3,"NaN","NaN","NaN"],[100,1,1,1,1,2,1,2,1,3,1,3,1]]}, +{"name":"random 0, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,0,1,0,4,0,1,0,1,0,1,0,1,0,32,0,1,0,1,0,32,0.510126582278481,2.37,1,32,1,9.01,1,2,1,32,1,4.96,1,32,1,32,1,2,1,32,1,32,1,2,1.555,32,2,1,2,6.029999999999999,2,5,2,1,2,9.84,2.539252100840336,4.76,3,2,3,5.92,3,3.8200000000000003,3,3.0599999999999996,3,32,3,1,3,32,3,1,3,32,3,32,3.6431226765799254,5.38,4,6.109999999999999,4,4.88,4,6.54,4,1,4,9.58,4,2.29,4,32,4,2,4,32,4.647,1,5,32,5,32,5,8.629999999999999,5,32,5,5.63,5,6.51,5,32,5,32,5.5,2,6,32,6,4.039999999999999,6,32,6,2,6,32,6,32,6.334664188351921,8.07,7,5.529999999999999,7,32,7,32,7,1,7,32,7,5.54,7,4.21,7,8.54,7,4.6899999999999995,7,8.49,7,1,7,8.97,7.92375,4,8,32,8,1,8,32,8,7.52,8,9.76,9,4.609999999999999,9,32,9,2,9,9.42,9,7.52,9,32,9,32,9,2,9,32,9.452040363269425,9.91,10,5,10,9.37,10,6.79,10.006746463547334,9.19,11,32,11,1,11,32,11.785637727759914,9.33,12,32,12,1,12,32,12,32,12,5,12,10.02,12,32,12,1,12,32,12,32,13,9.149999999999999,13,11.17,13,1,13,32,13,5.2,13,8.6,13,32,13,32,13,32,14,10.309999999999999,14,9.46,14,11.42,14,32,14.904942965779467,10.52,15,3.9699999999999998,15,32,15,1,15,32,15,12.01,15,32,15,32,15.956023102310231,12.12,16,6.14,16,32,16,10.52,16,2.84,16,32,17,32,17,1,17,32,17,11.1,17,32,17,8.73,17,32,17,3,17,32,17.217627856365613,9.19,18,32,18,12.15,18,32,18,1,18,32,18,2,18,32,18,1,18,32,18,8.64,18,32,19,6.42,19,32,19.114187192118226,10.15,20.309,32,21.2,1,25.031,32,26.546999999999997,2,28.784,32,30.102,11.5,31.643,32,32.797,32,36.53342144026187,12.219999999999999,38.425,32,42.14775609756098,8.2,49.741,32,49.966,32,51.482,1,52.816,32,53.989,1,54.028,32,54.995333333333335,3,59.244,32,60.29233333333333,3,62.216,32,66.97447848285923,13.71,67.946,32,69.92204761904762,10.08,71.03,32,73.35307632999229,12.969999999999999,77.19566666666667,9.75,78.40758447488585,10.95,80.547,32,80.863,1.96,81.596,32,82.357,32,85.3409290780142,9.870000000000001,91.027,8.72,93.68,32,98.22157478005865,13.64,103.9595832747716,14.23,107,1,107.755,32,108.678,6.38,109.441,32,113.795,32,114.005,32,115.293,32,123.34731990131579,12.16,131.8714983713355,6.14,135.844,32,137.553,1,139.046,32,143.08999999999997,3,144.949,32,148.28513911143483,13.73,152.08763034367144,11.93,157.426,8.4,158.665,9.129999999999999,159.88080962128967,9.77,162.762,32,164.02949999999998,2,168.775,32,173.66851172413791,14.5,184.15475849056605,13.25,191.71238285714287,10.5,193.474,32,194.899,32,196.054,3,197.015,32,205.3148991354467,10.41,213.81242391304346,11.04,217.928,32,219.04,32,220.673,32,221.312,9.6,225.316,9.73,225.771,32,226.69,1,226.74,32,226.985,32,229.2095450643777,13.98,233.883,32,235.30094362017803,3.37,235.919,32,241.82412076583213,13.58,246.937,32,247.97748514851486,10.1,252.213,32,253.457,1,259.353,32,259.399,1,260.025,32,263.1666666666667,3,268.315,32,269.333,1,269.62,32,271.039,32,274.259,32,276.578651799687,12.78,279.968,32,281.164,2.51,283.861,32,289.6016811414392,8.059999999999999,296.94,32,299.599,32,305.998,32,307.459,1,308.723,32,311.62760000000003,5,316.664,32,318.261,32,322.75825,8,326.26,32,328.6551522842639,11.82,329.266,32,331.525,32,334.453,9.12,335.192,32,336.83385365853655,12.3,338.077,2.9899999999999998,338.726,32,345.1275922798552,8.29,348.758,32,349.008,32,349.255,1,351.996,32,353.045,2,354.122,32,354.325,32,355.7436973047685,14.469999999999999,365.16169951422626,14.41,372.0443333333333,3,373.774,32,376.6952432432433,7.3999999999999995,378.717,32,384.0365474820144,13.9,393.10563796753706,14.17,406.431359500446,11.21,414.898,32,416.321,1,416.96,32,418.972899864682,14.78,426.962,32,427.606,32,429.833,32,430.933,1.91,431.659,32,440.7981625544267,13.78,444.9519421965318,10.379999999999999,449.0249834710744,9.68,450.318,32,451.797,5.38,452.888,32,455.367,1,455.758,32,457.29677027027026,5.92,459.389,32,461.7344765478424,5.33,463.102,32,464.458,32,464.837,1,466.049,32,467.404,2,468.323,32,469.441,1,469.86,32,470.011,32,474.9294266873546,12.89,480.244,32,480.969,32,481.2,9.299999999999999,481.582,32,489.8276349009901,8.08,491.829,8.61,492.42635890218156,14.209999999999999,497.4554266842801,7.57,498.886,32,499.324,1,499.434,32,503.751,2,505.661,32,506.478,8.6,509.757,32,512.3638624535316,5.38,517.475,10,519.281,32,520.8696987951807,1.6600000000000001,523.539,32,525.305,1,526.723,32,528.577,1,530.682,32,531.768,2,532.296,32,535.1753333333334,3,535.642,32,535.726,32,536.775,3.8699999999999997,536.986,32,541.2000256410256,10.14,542.182,6,543.143,8.6,543.649,32,547.9084552529182,12.849999999999998,550.6490614035088,9.120000000000001,554.3801312356101,13.03,560.971,32,563.077,1,564.264,32,564.627,1,565.862,32,567.6884649122808,4.5600000000000005,569.425,32,573.2684654190399,12.29,579.136,32,581.296,32,583.4806666666667,6,585.881,8.83,588.7701026615969,13.15,598.071,32,605.7068942486086,10.780000000000001,615.849,32,624.2415223880597,13.399999999999999,629.283716713881,10.59,630.634,32,634.2631666666667,6,637.649,32,638.9417995545656,13.47,644.283,32,646.1953333333333,10.799999999999999,647.2919284940411,9.23,648.5573625377643,9.93,651.4054554973821,5.7299999999999995,653.625,32,653.755,32,653.949,32,654.366,32,654.614,2,655.691,32,656.406,32,658.4859562890277,11.21,664.503759055118,12.7,670.737434002112,9.47,675.174,32,680.636125,8,685.316,32,694.9363206046141,12.57,696.786,32,697.9774835164835,5.46,698.246,32,701.4252254758419,6.83,703.998,32,708.9645714285714,7,712.4553195876289,11.64,718.3395773955773,4.07,719.224,32,721.101,1,721.148,32,721.724,32,725.812,0.91,726.695,32,728.6955,2,731.909,32,734.9480872483222,7.449999999999999,741.4848285714286,8.75,746.582,32,750.5907787610619,4.52,752.662,8.299999999999999,755.237,32,755.4109813084111,10.7,757.5744410876133,6.619999999999999,760.725,32,761.37971155596,10.99,762.724,1,763.975,32,764.442,32,766.2054194560669,9.559999999999999,769.021,32,770.571,32,771.472,32,773.556,1,775.767,32,775.873,3.96,776.617,32,781.1322248722317,5.87,786.56,32,787.471,32,788.4339488491048,3.91,790.905,32,792.749,32,795.1719635157546,6.029999999999999,797.402,32,798.34,32,801.7593333333333,3,803.511,32,804.114,32,804.944,1,805.026,32,808.3075652173914,3.91,810.397,32,810.9835628997868,9.379999999999999,820.8742928870292,4.78,823.507481236203,9.06,825.594,32,827.3601813471503,1.9300000000000002,828.17407028754,9.39,831.1372543859649,4.5600000000000005,832.792,32,837.2550625000001,6.4,841.792,32,843.5070000000001,2,846.2926155606408,8.74,851.8944802342605,6.83,856.531,9.02,857.499,1,857.751,32,863.410438442211,7.96,870.513,6.68,874.0649245063879,8.61,875.953,1,877.313,32,877.318,32,878.3876341463414,6.1499999999999995,880.7883472378804,8.87,886.3549183922046,8.21,893.929,7.74,894.368,9.16,895.0096666666667,3,897.164,32,897.881,2,898.634,9.49,901.148,9,903.562,1,905.662,32,908.174,8.73,909.307,1,910.496,9.58,913.05,6.97,915.837,2.84,917.943,8.69,920.4506062801933,8.28,920.92,32,927.8004285714285,2.8,929.783,32,930.163,32,930.8549494949494,1.98,931.178,32,931.836,1,933.425,32,934.2880673575129,3.86,934.859,7.27,936.5296623376623,1.54,936.642,32,939.8164210526315,3.2299999999999995,942.565,32,943.277,8.42,945.619,32,946.7283333333334,3,947.902,9.69,949.7254,5,955.7400880626222,5.109999999999999,956.755,7.779999999999999,958.4553333333333,1.5,959.193,32,960.0505570032573,6.14,961.347,1,962.939,32,965.252,32,965.8575000000001,2,967.482,8.91,968.377,32,969.9010000000001,2,971.41,32,972.265,32,975.908,3,976.809,32,977.221,8.15,978.619,1,979.245,32,979.256,32,980.273,32,981.798,3.8099999999999996,982.5935,2,983.095,6.569999999999999,985.5276666666666,3,990.194,32,993.7049999999999,2,996.05,1,996.328,32,998.084,32,998.343,0.41000000000000003,999.695,3.8699999999999997]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,1,7,18,329.52331421874993,659.7104067472885,879.3089197828015,956.3382483409974,987.9276818914287,998.2550482030238,999.695,"NaN","NaN","NaN"],[1000,0,1,0,4,0,1,0,1,0,1,0,1,0,32,0,1,0,1,0,32,0.510126582278481,2.37,1,32,1,9.01,1,2,1,32,1,4.96,1,32,1,32,1,2,1,32,1,32,1,2,1.555,32,2,1,2,6.029999999999999,2,5,2,1,2,9.84,2.539252100840336,4.76,3,2,3,5.92,3,3.8200000000000003,3,3.0599999999999996,3,32,3,1,3,32,3,1,3,32,3,32,3.6431226765799254,5.38,4,6.109999999999999,4,4.88,4,6.54,4,1,4,9.58,4,2.29,4,32,4,2,4,32,4.647,1,5,32,5,32,5,8.629999999999999,5,32,5,5.63,5,6.51,5,32,5,32,5.5,2,6,32,6,4.039999999999999,6,32,6,2,6,32,6,32,6.334664188351921,8.07,7,5.529999999999999,7,32,7,32,7,1,7,32,7,5.54,7,4.21,7,8.54,7,4.6899999999999995,7,8.49,7,1,7,8.97,7.92375,4,8,32,8,1,8,32,8,7.52,8,9.76,9,4.609999999999999,9,32,9,2,9,9.42,9,7.52,9,32,9,32,9,2,9,32,9.452040363269425,9.91,10,5,10,9.37,10,6.79,10.006746463547334,9.19,11,32,11,1,11,32,11.785637727759914,9.33,12,32,12,1,12,32,12,32,12,5,12,10.02,12,32,12,1,12,32,12,32,13,9.149999999999999,13,11.17,13,1,13,32,13,5.2,13,8.6,13,32,13,32,13,32,14,10.309999999999999,14,9.46,14,11.42,14,32,14.904942965779467,10.52,15,3.9699999999999998,15,32,15,1,15,32,15,12.01,15,32,15,32,15.956023102310231,12.12,16,6.14,16,32,16,10.52,16,2.84,16,32,17,32,17,1,17,32,17,11.1,17,32,17,8.73,17,32,17,3,17,32,17.217627856365613,9.19,18,32,18,12.15,18,32,18,1,18,32,18,2,18,32,18,1,18,32,18,8.64,18,32,19,6.42,19,32,19.114187192118226,10.15,20.309,32,21.2,1,25.031,32,26.546999999999997,2,28.784,32,30.102,11.5,31.643,32,32.797,32,36.53342144026187,12.219999999999999,38.425,32,42.14775609756098,8.2,49.741,32,49.966,32,51.482,1,52.816,32,53.989,1,54.028,32,54.995333333333335,3,59.244,32,60.29233333333333,3,62.216,32,66.97447848285923,13.71,67.946,32,69.92204761904762,10.08,71.03,32,73.35307632999229,12.969999999999999,77.19566666666667,9.75,78.40758447488585,10.95,80.547,32,80.863,1.96,81.596,32,82.357,32,85.3409290780142,9.870000000000001,91.027,8.72,93.68,32,98.22157478005865,13.64,103.9595832747716,14.23,107,1,107.755,32,108.678,6.38,109.441,32,113.795,32,114.005,32,115.293,32,123.34731990131579,12.16,131.8714983713355,6.14,135.844,32,137.553,1,139.046,32,143.08999999999997,3,144.949,32,148.28513911143483,13.73,152.08763034367144,11.93,157.426,8.4,158.665,9.129999999999999,159.88080962128967,9.77,162.762,32,164.02949999999998,2,168.775,32,173.66851172413791,14.5,184.15475849056605,13.25,191.71238285714287,10.5,193.474,32,194.899,32,196.054,3,197.015,32,205.3148991354467,10.41,213.81242391304346,11.04,217.928,32,219.04,32,220.673,32,221.312,9.6,225.316,9.73,225.771,32,226.69,1,226.74,32,226.985,32,229.2095450643777,13.98,233.883,32,235.30094362017803,3.37,235.919,32,241.82412076583213,13.58,246.937,32,247.97748514851486,10.1,252.213,32,253.457,1,259.353,32,259.399,1,260.025,32,263.1666666666667,3,268.315,32,269.333,1,269.62,32,271.039,32,274.259,32,276.578651799687,12.78,279.968,32,281.164,2.51,283.861,32,289.6016811414392,8.059999999999999,296.94,32,299.599,32,305.998,32,307.459,1,308.723,32,311.62760000000003,5,316.664,32,318.261,32,322.75825,8,326.26,32,328.6551522842639,11.82,329.266,32,331.525,32,334.453,9.12,335.192,32,336.83385365853655,12.3,338.077,2.9899999999999998,338.726,32,345.1275922798552,8.29,348.758,32,349.008,32,349.255,1,351.996,32,353.045,2,354.122,32,354.325,32,355.7436973047685,14.469999999999999,365.16169951422626,14.41,372.0443333333333,3,373.774,32,376.6952432432433,7.3999999999999995,378.717,32,384.0365474820144,13.9,393.10563796753706,14.17,406.431359500446,11.21,414.898,32,416.321,1,416.96,32,418.972899864682,14.78,426.962,32,427.606,32,429.833,32,430.933,1.91,431.659,32,440.7981625544267,13.78,444.9519421965318,10.379999999999999,449.0249834710744,9.68,450.318,32,451.797,5.38,452.888,32,455.367,1,455.758,32,457.29677027027026,5.92,459.389,32,461.7344765478424,5.33,463.102,32,464.458,32,464.837,1,466.049,32,467.404,2,468.323,32,469.441,1,469.86,32,470.011,32,474.9294266873546,12.89,480.244,32,480.969,32,481.2,9.299999999999999,481.582,32,489.8276349009901,8.08,491.829,8.61,492.42635890218156,14.209999999999999,497.4554266842801,7.57,498.886,32,499.324,1,499.434,32,503.751,2,505.661,32,506.478,8.6,509.757,32,512.3638624535316,5.38,517.475,10,519.281,32,520.8696987951807,1.6600000000000001,523.539,32,525.305,1,526.723,32,528.577,1,530.682,32,531.768,2,532.296,32,535.1753333333334,3,535.642,32,535.726,32,536.775,3.8699999999999997,536.986,32,541.2000256410256,10.14,542.182,6,543.143,8.6,543.649,32,547.9084552529182,12.849999999999998,550.6490614035088,9.120000000000001,554.3801312356101,13.03,560.971,32,563.077,1,564.264,32,564.627,1,565.862,32,567.6884649122808,4.5600000000000005,569.425,32,573.2684654190399,12.29,579.136,32,581.296,32,583.4806666666667,6,585.881,8.83,588.7701026615969,13.15,598.071,32,605.7068942486086,10.780000000000001,615.849,32,624.2415223880597,13.399999999999999,629.283716713881,10.59,630.634,32,634.2631666666667,6,637.649,32,638.9417995545656,13.47,644.283,32,646.1953333333333,10.799999999999999,647.2919284940411,9.23,648.5573625377643,9.93,651.4054554973821,5.7299999999999995,653.625,32,653.755,32,653.949,32,654.366,32,654.614,2,655.691,32,656.406,32,658.4859562890277,11.21,664.503759055118,12.7,670.737434002112,9.47,675.174,32,680.636125,8,685.316,32,694.9363206046141,12.57,696.786,32,697.9774835164835,5.46,698.246,32,701.4252254758419,6.83,703.998,32,708.9645714285714,7,712.4553195876289,11.64,718.3395773955773,4.07,719.224,32,721.101,1,721.148,32,721.724,32,725.812,0.91,726.695,32,728.6955,2,731.909,32,734.9480872483222,7.449999999999999,741.4848285714286,8.75,746.582,32,750.5907787610619,4.52,752.662,8.299999999999999,755.237,32,755.4109813084111,10.7,757.5744410876133,6.619999999999999,760.725,32,761.37971155596,10.99,762.724,1,763.975,32,764.442,32,766.2054194560669,9.559999999999999,769.021,32,770.571,32,771.472,32,773.556,1,775.767,32,775.873,3.96,776.617,32,781.1322248722317,5.87,786.56,32,787.471,32,788.4339488491048,3.91,790.905,32,792.749,32,795.1719635157546,6.029999999999999,797.402,32,798.34,32,801.7593333333333,3,803.511,32,804.114,32,804.944,1,805.026,32,808.3075652173914,3.91,810.397,32,810.9835628997868,9.379999999999999,820.8742928870292,4.78,823.507481236203,9.06,825.594,32,827.3601813471503,1.9300000000000002,828.17407028754,9.39,831.1372543859649,4.5600000000000005,832.792,32,837.2550625000001,6.4,841.792,32,843.5070000000001,2,846.2926155606408,8.74,851.8944802342605,6.83,856.531,9.02,857.499,1,857.751,32,863.410438442211,7.96,870.513,6.68,874.0649245063879,8.61,875.953,1,877.313,32,877.318,32,878.3876341463414,6.1499999999999995,880.7883472378804,8.87,886.3549183922046,8.21,893.929,7.74,894.368,9.16,895.0096666666667,3,897.164,32,897.881,2,898.634,9.49,901.148,9,903.562,1,905.662,32,908.174,8.73,909.307,1,910.496,9.58,913.05,6.97,915.837,2.84,917.943,8.69,920.4506062801933,8.28,920.92,32,927.8004285714285,2.8,929.783,32,930.163,32,930.8549494949494,1.98,931.178,32,931.836,1,933.425,32,934.2880673575129,3.86,934.859,7.27,936.5296623376623,1.54,936.642,32,939.8164210526315,3.2299999999999995,942.565,32,943.277,8.42,945.619,32,946.7283333333334,3,947.902,9.69,949.7254,5,955.7400880626222,5.109999999999999,956.755,7.779999999999999,958.4553333333333,1.5,959.193,32,960.0505570032573,6.14,961.347,1,962.939,32,965.252,32,965.8575000000001,2,967.482,8.91,968.377,32,969.9010000000001,2,971.41,32,972.265,32,975.908,3,976.809,32,977.221,8.15,978.619,1,979.245,32,979.256,32,980.273,32,981.798,3.8099999999999996,982.5935,2,983.095,6.569999999999999,985.5276666666666,3,990.194,32,993.7049999999999,2,996.05,1,996.328,32,998.084,32,998.343,0.41000000000000003,999.695,3.8699999999999997]]}, +{"name":"random 1, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,0,1,0,1,0,1,0,32,1,3.8899999999999997,1,2.5,1,32,2,32,2,32,2.6666666666666665,3,3,5.72,4,1.98,4,32,6.666666666666667,6,9,32,9,1,9,32,10.651567944250871,5.74,12,1.51,12.164473684210526,6.08,13.8,5,16,2.55,17,32,17,32,18,6.319999999999999,18,1,18,32,18,32,19,1,19,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,1,2,9,17,18,18,18.842854545454546,19,19,"NaN","NaN","NaN"],[100,0,1,0,1,0,1,0,32,1,3.8899999999999997,1,2.5,1,32,2,32,2,32,2.6666666666666665,3,3,5.72,4,1.98,4,32,6.666666666666667,6,9,32,9,1,9,32,10.651567944250871,5.74,12,1.51,12.164473684210526,6.08,13.8,5,16,2.55,17,32,17,32,18,6.319999999999999,18,1,18,32,18,32,19,1,19,1]]}, +{"name":"random 2, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,-988659.5,1,-983515.9,32,-977093.1,1,-975350.5,1,-973349.2,1,-969929.1,1,-959248.2,1,-956366.9,32,-951110.3,7.22,-941267.7,6.75,-934389.5,4.4399999999999995,-932046.3,32,-920336.3,9.2,-890571.5,6.91,-889344.2,1,-876695.6,9.89,-871882,2,-861255.05,2,-847187.4,32,-837356,32,-825526.2,32,-820225.6,32,-818737.2,3.8,-784066.8,2,-782109.5,1,-761041.2,9.86,-752914.8,2,-750304.6,1,-749458,32,-748854.4,4.04,-739263.5,8.2,-725570.6,2,-719859,1,-716474.5,32,-686725.9,2,-666931.5,7.3,-659538.1,3,-656136.15,2,-650438.5,32,-643002.6,3,-631219.5,1,-624040.7,32,-617084.4,6.16,-604268.2999999999,3,-595844.7,1,-586123.9,32,-585577.6,1,-560537.1,32,-558894.9,1,-556706.2,3.4299999999999997,-555517.5,3.8499999999999996,-553549,0.5,-543088.3,5.569999999999999,-542466.6,6.12,-539133.1,2,-537621.9,6.609999999999999,-534394.2,4.64,-504298,3,-472944.06706586824,3.34,-462749.6,2,-455549.6,32,-452978.4,1,-442734.3,32,-432087.89999999997,3,-425621.4,32,-414050.06666666665,3,-390486.3,1,-382878.8,32,-370010.5796875,2.56,-357059.4,32,-354255.5,2,-349381,9.799999999999999,-328437.8,8.41,-312611.4666666667,3,-302640.1,8.52,-296549.6,7.2,-283234.2,4,-271794.7,32,-268522.5,32,-256404.59999999998,4,-228687.5,3,-214844.9,32,-203809.39371727747,3.8200000000000003,-194691,32,-187946.8,32,-180884.5,2,-170101.7,32,-162322.3,32,-162306.6,9.24,-159433.6,32,-155371.6,1,-150268.8,6.029999999999999,-145928.2,2,-137073.7,32,-131213.5,1,-121528.5,4.8,-87575.025,4,-60115.6,32,-28952.66007326008,2.73,-4798.9,32,-1589.853,2,68.297,32,76.922,1,83.593,9.08,141.472,3,179.83,32,232.75,32,289.356,32,303.916,32,329.637,1,335.338,32,373.831,1,376.969,9.69,418.8945,4,452.02,1,469.077,32,472.483,1,477.663,32,494.683,1,544.412,32,563.621,3,602.758,32,602.809,32,607.016,8.1,641.276778290993,4.33,688.127,2.2899999999999996,761.832,32,775.472,32,805.151,32,826.0993125,3.2,863.981,32,924.883,3.94,924.989,32,956.313,32,9510.045,3,19173.1,32,27038.3,1,31144.4,7.63,43556.5,9.67,44933.3,9.15,57187.46666666667,3,78595.6,32,78729.8,2.51,79719.5,32,86079.23333333334,3,101607.8,9.549999999999999,105443.49444444444,3.5999999999999996,127402.1,2,135153.9,32,144774.4,5.77,149185.8,6.26,154148.0160762943,3.67,162395.1,1.62,164893.2,3.38,168286.4,32,170132.7,32,189596.40000000002,2,202649.2,32,214261.43247863246,3.51,238682.5,8.67,246067.68230452674,2.4299999999999997,252591.4,6.01,260686.7,2,268339.1,32,283117,3,297765.9,4,301807.2,2,312343.1,5.01,342050.3,2,350360.2,5.49,357615.75,2,370230.3,8.69,371204.8,32,380233.1085545723,3.3899999999999997,381355.1,1,395935.1,8.36,405428.44999999995,2,432579.7,32,433910.2,3.6999999999999997,454348.35748031497,1.27,456882.7,5.3,471304.5,4.7,480407.1710182768,3.83,493510.4,1,498294.8,9.32,509916.23333333334,3,521506.2,1,523931.1,32,528089.7,32,544406.7,2,549348.9,32,552904.8,32,552961.1,32,555245.4,2,558903.4,32,570794.9,1,587446.1,9.17,602632.2315789474,3.04,616184.2,32,619473.8,6.6899999999999995,634255.8,32,635085.55,2,640860.1,4.2299999999999995,644886.6,1,656508,32,666250.75,2,676757.7,1,701028.5,6.9399999999999995,727062.15,2,737545,1,756542.5,32,762812.3063063063,2.2199999999999998,765771.65,2,768156.7705069124,2.17,770601.2,32,775068.2,5.8999999999999995,790073.8,2.92,810004.1,7.4399999999999995,818124,3.09,818643.7,9.75,822899.6,8.83,833077.95,2,845208.1,1,853253.1,4.43,857384.25,2,863697,32,868946,2,876105.3,1.86,887388.1499999999,2,887858.3,32,889463.8,32,907100.1,1,923940,1,923955.3,9.67,941913.4,32,943609.2,1.82,945722.8,1,970989.9,1,972201.5,5,983700.2,5.52,987729.8,32]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-988659.5,-987901.7542,-978725.0750909091,-758389.4994940977,-357010.33174999995,483.506533333334,373690.83749263384,756742.2103703647,887622.4644632352,984871.3830490405,987729.8,987729.8,"NaN","NaN","NaN"],[1000,-988659.5,1,-983515.9,32,-977093.1,1,-975350.5,1,-973349.2,1,-969929.1,1,-959248.2,1,-956366.9,32,-951110.3,7.22,-941267.7,6.75,-934389.5,4.4399999999999995,-932046.3,32,-920336.3,9.2,-890571.5,6.91,-889344.2,1,-876695.6,9.89,-871882,2,-861255.05,2,-847187.4,32,-837356,32,-825526.2,32,-820225.6,32,-818737.2,3.8,-784066.8,2,-782109.5,1,-761041.2,9.86,-752914.8,2,-750304.6,1,-749458,32,-748854.4,4.04,-739263.5,8.2,-725570.6,2,-719859,1,-716474.5,32,-686725.9,2,-666931.5,7.3,-659538.1,3,-656136.15,2,-650438.5,32,-643002.6,3,-631219.5,1,-624040.7,32,-617084.4,6.16,-604268.2999999999,3,-595844.7,1,-586123.9,32,-585577.6,1,-560537.1,32,-558894.9,1,-556706.2,3.4299999999999997,-555517.5,3.8499999999999996,-553549,0.5,-543088.3,5.569999999999999,-542466.6,6.12,-539133.1,2,-537621.9,6.609999999999999,-534394.2,4.64,-504298,3,-472944.06706586824,3.34,-462749.6,2,-455549.6,32,-452978.4,1,-442734.3,32,-432087.89999999997,3,-425621.4,32,-414050.06666666665,3,-390486.3,1,-382878.8,32,-370010.5796875,2.56,-357059.4,32,-354255.5,2,-349381,9.799999999999999,-328437.8,8.41,-312611.4666666667,3,-302640.1,8.52,-296549.6,7.2,-283234.2,4,-271794.7,32,-268522.5,32,-256404.59999999998,4,-228687.5,3,-214844.9,32,-203809.39371727747,3.8200000000000003,-194691,32,-187946.8,32,-180884.5,2,-170101.7,32,-162322.3,32,-162306.6,9.24,-159433.6,32,-155371.6,1,-150268.8,6.029999999999999,-145928.2,2,-137073.7,32,-131213.5,1,-121528.5,4.8,-87575.025,4,-60115.6,32,-28952.66007326008,2.73,-4798.9,32,-1589.853,2,68.297,32,76.922,1,83.593,9.08,141.472,3,179.83,32,232.75,32,289.356,32,303.916,32,329.637,1,335.338,32,373.831,1,376.969,9.69,418.8945,4,452.02,1,469.077,32,472.483,1,477.663,32,494.683,1,544.412,32,563.621,3,602.758,32,602.809,32,607.016,8.1,641.276778290993,4.33,688.127,2.2899999999999996,761.832,32,775.472,32,805.151,32,826.0993125,3.2,863.981,32,924.883,3.94,924.989,32,956.313,32,9510.045,3,19173.1,32,27038.3,1,31144.4,7.63,43556.5,9.67,44933.3,9.15,57187.46666666667,3,78595.6,32,78729.8,2.51,79719.5,32,86079.23333333334,3,101607.8,9.549999999999999,105443.49444444444,3.5999999999999996,127402.1,2,135153.9,32,144774.4,5.77,149185.8,6.26,154148.0160762943,3.67,162395.1,1.62,164893.2,3.38,168286.4,32,170132.7,32,189596.40000000002,2,202649.2,32,214261.43247863246,3.51,238682.5,8.67,246067.68230452674,2.4299999999999997,252591.4,6.01,260686.7,2,268339.1,32,283117,3,297765.9,4,301807.2,2,312343.1,5.01,342050.3,2,350360.2,5.49,357615.75,2,370230.3,8.69,371204.8,32,380233.1085545723,3.3899999999999997,381355.1,1,395935.1,8.36,405428.44999999995,2,432579.7,32,433910.2,3.6999999999999997,454348.35748031497,1.27,456882.7,5.3,471304.5,4.7,480407.1710182768,3.83,493510.4,1,498294.8,9.32,509916.23333333334,3,521506.2,1,523931.1,32,528089.7,32,544406.7,2,549348.9,32,552904.8,32,552961.1,32,555245.4,2,558903.4,32,570794.9,1,587446.1,9.17,602632.2315789474,3.04,616184.2,32,619473.8,6.6899999999999995,634255.8,32,635085.55,2,640860.1,4.2299999999999995,644886.6,1,656508,32,666250.75,2,676757.7,1,701028.5,6.9399999999999995,727062.15,2,737545,1,756542.5,32,762812.3063063063,2.2199999999999998,765771.65,2,768156.7705069124,2.17,770601.2,32,775068.2,5.8999999999999995,790073.8,2.92,810004.1,7.4399999999999995,818124,3.09,818643.7,9.75,822899.6,8.83,833077.95,2,845208.1,1,853253.1,4.43,857384.25,2,863697,32,868946,2,876105.3,1.86,887388.1499999999,2,887858.3,32,889463.8,32,907100.1,1,923940,1,923955.3,9.67,941913.4,32,943609.2,1.82,945722.8,1,970989.9,1,972201.5,5,983700.2,5.52,987729.8,32]]}, +{"name":"random 3, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,1.155,3.86]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,1.155,"NaN","NaN",1.155],[100,1.155,3.86]]}, +{"name":"random 4, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,0.035,32,2.903,2,3.074,32,4.162,1,8.378,4.31,9.597,1,9.811,8.31,10.159,5.55,11.517704918032788,3.05,15,32,15.589,1,15.613,32,15.81,4.7299999999999995,15.883,32,16.48,1,17.735,32,18.192,1,18.538,8.95,18.558,7.7299999999999995,18.595,32,19.861223826714802,2.77,21.636,32,22.022942583732057,4.18,23.05704845814978,4.539999999999999,25.904100456621006,6.57,26.675,0.85,38.204,32,41.188542699724515,3.63,48.379,32,59.645,3,68.88,3.2899999999999996,72.755,32,76.697,2,125.621,5.99,125.879,32,167.806,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0.035,0.035,0.035,3.0452820588235294,15.45129893939394,18.553107913669066,40.38984456214739,75.03788176470589,125.78972887601999,157.09682778787882,167.806,167.806,"NaN","NaN","NaN"],[100,0.035,32,2.903,2,3.074,32,4.162,1,8.378,4.31,9.597,1,9.811,8.31,10.159,5.55,11.517704918032788,3.05,15,32,15.589,1,15.613,32,15.81,4.7299999999999995,15.883,32,16.48,1,17.735,32,18.192,1,18.538,8.95,18.558,7.7299999999999995,18.595,32,19.861223826714802,2.77,21.636,32,22.022942583732057,4.18,23.05704845814978,4.539999999999999,25.904100456621006,6.57,26.675,0.85,38.204,32,41.188542699724515,3.63,48.379,32,59.645,3,68.88,3.2899999999999996,72.755,32,76.697,2,125.621,5.99,125.879,32,167.806,1]]}, +{"name":"random 5, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[100]]}, +{"name":"random 6, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,-264768.5,1.49,0,7.45,0,1,0,32,0,1,0,32,0,5.79,0,32,0,2,0,32,0,32,0,34.25,0,33.95,0,37.24,0,35,0,44.07,0,32.58,0.3865186360031721,50.44,1,39.74,1,32,1,33,1,57.839999999999996,1,60.15,1.8536913946587537,60.66,2,38.1,2,65,2,70.25,2,74.23,2,57.559999999999995,2,49.870000000000005,2.5607506307005625,51.529999999999994,3,65,3,82.98,3,72.76,3,76.78,3,64,3.112349630283633,90.61000000000001,4,92.58,4,90.09,4,90.89999999999999,4.980137356046066,83.36,5.170588235294118,81.60000000000001,6,76.2,6,73,6,76.28999999999999,6.019607843137255,102,7,87.6,7,104.31,7.44197450147107,91.77000000000001,8,106.77,8.055531960076449,94.17999999999999,9,98.1,9,108.1,9.909611404920671,86.98,10,99,10,108.87,10,108.13,10.952228642179117,96.92,11,103,11,92.32000000000001,11,106.99000000000001,11,104.67,11.124425375421392,97.89,12,98.2,12,77.15,12,81.94,12,98.18999999999998,12,78.67,12.108352402745995,87.4,13,74.7,13,72.82,13,99,13,94.85,14,98.66999999999999,14,90.33,14.072739468741615,74.53999999999999,15,77.78,15,67,15,92.31,15,82.75,15.479572830001242,80.53,16,79.12,16,85.03,16.16695675007723,64.74,17,79.35,17,65,17,76.97,17,56.709999999999994,17,70.68,17.884485010967584,41.03,18,66.22,18,53.239999999999995,18,67.17,18,58.540000000000006,18,49.050000000000004,18,37.47,18,33,18.090069804098178,44.41,19,32,19,34,19,43.86,19,39.34,19,36.14,19,37.599999999999994,19,52.36,19,35.4,19,39.05,19.111358980195767,43.93,25.27634485276223,41.09,29.178117647058823,34,32.288,32,36.435866920152094,7.89,44.143,32,46.752,32,54.40863405196241,18.09,78.827,32,85.335,32,87.96,1,102.921,9.24,115.13,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-264768.5,0,0,1.9358499875608886,4.013302105170717,11,15,18,19,65.69899618072553,98.0981521699218,115.13,"NaN","NaN","NaN"],[100,-264768.5,1.49,0,7.45,0,1,0,32,0,1,0,32,0,5.79,0,32,0,2,0,32,0,32,0,34.25,0,33.95,0,37.24,0,35,0,44.07,0,32.58,0.3865186360031721,50.44,1,39.74,1,32,1,33,1,57.839999999999996,1,60.15,1.8536913946587537,60.66,2,38.1,2,65,2,70.25,2,74.23,2,57.559999999999995,2,49.870000000000005,2.5607506307005625,51.529999999999994,3,65,3,82.98,3,72.76,3,76.78,3,64,3.112349630283633,90.61000000000001,4,92.58,4,90.09,4,90.89999999999999,4.980137356046066,83.36,5.170588235294118,81.60000000000001,6,76.2,6,73,6,76.28999999999999,6.019607843137255,102,7,87.6,7,104.31,7.44197450147107,91.77000000000001,8,106.77,8.055531960076449,94.17999999999999,9,98.1,9,108.1,9.909611404920671,86.98,10,99,10,108.87,10,108.13,10.952228642179117,96.92,11,103,11,92.32000000000001,11,106.99000000000001,11,104.67,11.124425375421392,97.89,12,98.2,12,77.15,12,81.94,12,98.18999999999998,12,78.67,12.108352402745995,87.4,13,74.7,13,72.82,13,99,13,94.85,14,98.66999999999999,14,90.33,14.072739468741615,74.53999999999999,15,77.78,15,67,15,92.31,15,82.75,15.479572830001242,80.53,16,79.12,16,85.03,16.16695675007723,64.74,17,79.35,17,65,17,76.97,17,56.709999999999994,17,70.68,17.884485010967584,41.03,18,66.22,18,53.239999999999995,18,67.17,18,58.540000000000006,18,49.050000000000004,18,37.47,18,33,18.090069804098178,44.41,19,32,19,34,19,43.86,19,39.34,19,36.14,19,37.599999999999994,19,52.36,19,35.4,19,39.05,19.111358980195767,43.93,25.27634485276223,41.09,29.178117647058823,34,32.288,32,36.435866920152094,7.89,44.143,32,46.752,32,54.40863405196241,18.09,78.827,32,85.335,32,87.96,1,102.921,9.24,115.13,1]]}, +{"name":"random 7, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[33.5,0,2,0,32,0,8.51,0,33,0.02857142857142857,35,1,32,1,32,1,32,1,65,1,69,1.5914719775309587,78.33,2.0733148019457954,86.33999999999999,3,90.05,3.800963634277848,87.17,5.174462825632251,105.18,6.315149246748385,106.86999999999999,7.344851833249623,99.55,8.320577038669605,99.82000000000001,9,32,9,112.49,9.52757865392274,100.43999999999998,10,80.85000000000001,10.568327577701035,81.08,11.40077865567388,87.33,12,75.86,12.56397329336422,73.39,13,86.38,13.773306014927556,68.33,15.579661454968344,77.39,16.330348873108985,64.78,17,65,17,47.21,17.04085523627945,73.43,18,67,18.31733957480008,51.27,19,41.21,19,32,19,32,19,2,19,32,19,2.84,19,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,1,3.633376840693475,9.289817663783136,13.84817828268659,17.72283632762387,18.976230897825,19,19,19,"NaN","NaN","NaN"],[33.5,0,2,0,32,0,8.51,0,33,0.02857142857142857,35,1,32,1,32,1,32,1,65,1,69,1.5914719775309587,78.33,2.0733148019457954,86.33999999999999,3,90.05,3.800963634277848,87.17,5.174462825632251,105.18,6.315149246748385,106.86999999999999,7.344851833249623,99.55,8.320577038669605,99.82000000000001,9,32,9,112.49,9.52757865392274,100.43999999999998,10,80.85000000000001,10.568327577701035,81.08,11.40077865567388,87.33,12,75.86,12.56397329336422,73.39,13,86.38,13.773306014927556,68.33,15.579661454968344,77.39,16.330348873108985,64.78,17,65,17,47.21,17.04085523627945,73.43,18,67,18.31733957480008,51.27,19,41.21,19,32,19,32,19,2,19,32,19,3.84]]}, +{"name":"random 8, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,-982025.8,9.31,-947921.3,32,-837263.2,1,-798341.1,2.71,-790279.5,32,-682683.2,32,-668431.1,9.03,-661926.4,1,-600453.9,4.7299999999999995,-595523.2,0.96,-564286,32,-552631.3,1,-528687.9,3.03,-505525,1,-497329.5,3.34,-388122.9,1.8800000000000001,-309820,1,-296107.8,1,-283234.6,1,-223541.2,1,-183560.5,1,2,1,9.444,1,11,32,11,1,12,1,13,1,101.516,32,157.419,32,205.094,32,224.64,1,699.041,5.24,64735.5,1,162213.6,1,168421,1,176381.1,32,190690,1,214412.6,1,254242.6,1,322021,1.65,327335.6,1,407493.9,1,426419,1,466764.5,1,527581.4,1,554985.7,32,660562.6,32,700488.5,1,708744,3.6799999999999997,717481.6,1,720738.4,32,732012.2,8.75,757319.2,1,769439.3,1,786472.1,32,815863.2,1,886862.7,1,922430.9,32,940283.3,32,942965.7,1,951643.2,1,962085.1,32]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-982025.8,-982025.8,-979799.8848971195,-790738.902039758,-557690.4993181818,218.3201266666666,725537.0272638038,934687.1304875001,953215.4970030304,962085.1,962085.1,962085.1,"NaN","NaN","NaN"],[1000,-982025.8,9.31,-947921.3,32,-837263.2,1,-798341.1,2.71,-790279.5,32,-682683.2,32,-668431.1,9.03,-661926.4,1,-600453.9,4.7299999999999995,-595523.2,0.96,-564286,32,-552631.3,1,-528687.9,3.03,-505525,1,-497329.5,3.34,-388122.9,1.8800000000000001,-309820,1,-296107.8,1,-283234.6,1,-223541.2,1,-183560.5,1,2,1,9.444,1,11,32,11,1,12,1,13,1,101.516,32,157.419,32,205.094,32,224.64,1,699.041,5.24,64735.5,1,162213.6,1,168421,1,176381.1,32,190690,1,214412.6,1,254242.6,1,322021,1.65,327335.6,1,407493.9,1,426419,1,466764.5,1,527581.4,1,554985.7,32,660562.6,32,700488.5,1,708744,3.6799999999999997,717481.6,1,720738.4,32,732012.2,8.75,757319.2,1,769439.3,1,786472.1,32,815863.2,1,886862.7,1,922430.9,32,940283.3,32,942965.7,1,951643.2,1,962085.1,32]]}, +{"name":"random 9, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[5,0.34640261245128,474.65,2.312349668961755,1209.83,7.310367324561403,1824.0000000000002,12.971880046866586,1578.95,16.64407530880851,1037.86,18.873452782826973,346.59]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0.34640261245128,0.34640261245128,0.34640261245128,1.3031001789674193,4.086317027622674,9.438115851812917,14.532234307858342,17.34723460334049,18.389400336053885,18.873452782826973,18.873452782826973,18.873452782826973,"NaN","NaN","NaN"],[5,0.34640261245128,474.65,2.312349668961755,1209.83,7.310367324561403,1824.0000000000002,12.971880046866586,1578.95,16.64407530880851,1037.86,18.873452782826973,346.59]]}, +{"name":"random 10, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,0,4.18]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,0,0,0,0,0,0,0,0,0,"NaN","NaN",0],[1000,0,4.18]]}, +{"name":"random 11, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[20]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[20]]}, +{"name":"random 12, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,14.655,32,14.655,32,197.3488729281768,5.43,197.3488729281768,5.43,325.798,32,325.798,32,739.9,1,739.9,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[14.655,14.655,14.655,14.655,14.655,197.3488729281768,325.798,424.0280138181818,600.7868250909089,739.9,739.9,739.9,"NaN","NaN","NaN"],[100,14.655,32,14.655,32,197.3488729281768,5.43,197.3488729281768,5.43,325.798,32,325.798,32,739.9,1,739.9,1]]}, +{"name":"random 13, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[33.5,0,1,0,9.26,0,13.14,0,32,0.1821561338289963,40.35,1,48.1,1,54.32,1.7524100634845992,42.53,2.027027027027027,74,3,33,3.629516447959734,55.629999999999995,4.125252525252525,89.1,5.643353837924578,74.78,6.091032424365758,73.71,7,100.16999999999999,7.6736900988252845,107.25999999999999,8.94073995547546,94.33000000000001,9.291322314049587,116.16,10.092723643621845,110.22,11.049725180350395,116.44,12,103.14,12.142424751975785,118.94000000000001,13,99,13.062867215041129,102.12,14.017630465444288,113.44,15,84.42999999999999,15.351943597560975,104.96,16.03921568627451,102,17,67,17,67.88,17.26060606060606,67.64999999999999,18,66,18,41.01,18,66,18,35,18.243677617584492,42.31,19,32,19,33,19,7.12,19,32,34.057206278026904,4.46]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,1.97893311994753,6.767216895888013,12.000525883900487,15.665227559917156,18,18.21838002919058,19,33.68968820312465,34.057206278026904,"NaN","NaN","NaN"],[33.5,0,1,0,9.26,0,13.14,0,32,0.1821561338289963,40.35,1,48.1,1,54.32,1.7524100634845992,42.53,2.027027027027027,74,3,33,3.629516447959734,55.629999999999995,4.125252525252525,89.1,5.643353837924578,74.78,6.091032424365758,73.71,7,100.16999999999999,7.6736900988252845,107.25999999999999,8.94073995547546,94.33000000000001,9.291322314049587,116.16,10.092723643621845,110.22,11.049725180350395,116.44,12,103.14,12.142424751975785,118.94000000000001,13,99,13.062867215041129,102.12,14.017630465444288,113.44,15,84.42999999999999,15.351943597560975,104.96,16.03921568627451,102,17,67,17,67.88,17.26060606060606,67.64999999999999,18,66,18,41.01,18,66,18,35,18.243677617584492,42.31,19,32,19,33,19,7.12,19,32,34.057206278026904,4.46]]}, +{"name":"random 14, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[5]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[5]]}, +{"name":"random 15, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[100]]}, +{"name":"random 16, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[33.5,-279379.1,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,-279379.1,"NaN","NaN",-279379.1],[33.5,-279379.1,1]]}, +{"name":"random 17, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,-888778.7,0.56,-849867.9,1,-785802.6,1,-530927.9,32,-468612.9333333333,3,-386807.8,7.3999999999999995,-280648.1666666667,3,-141712.3638814016,3.71,-92086.9,1,-50570,32,-47378,1,-5929.1,6.359999999999999,84952.25,2,162170.1,9.59,184001.4,32,244830.4,1,407410.1,7.859999999999999,410303.6,1,441308.6,32,499098.35,2,581161.7,32,597983.8,6.29,618266.5123505977,5.02,661654.3108108108,1.85,681126.6,32,721174.9318091451,5.029999999999999,799095.8,32,800189.6,7.42,831117.2,1,908557.4,32,926898.45,2,941285.8,32,962921.2,1,964259,1,975486,1,978582.6,5.319999999999999]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-888778.7,-883969.225348718,-759479.4499230302,-443741.02644871804,99243.21533649685,546043.4134558821,799353.1565449011,930012.0418029411,948496.9443818182,977500.6518797468,978582.6,978582.6,"NaN","NaN","NaN"],[100,-888778.7,0.56,-849867.9,1,-785802.6,1,-530927.9,32,-468612.9333333333,3,-386807.8,7.3999999999999995,-280648.1666666667,3,-141712.3638814016,3.71,-92086.9,1,-50570,32,-47378,1,-5929.1,6.359999999999999,84952.25,2,162170.1,9.59,184001.4,32,244830.4,1,407410.1,7.859999999999999,410303.6,1,441308.6,32,499098.35,2,581161.7,32,597983.8,6.29,618266.5123505977,5.02,661654.3108108108,1.85,681126.6,32,721174.9318091451,5.029999999999999,799095.8,32,800189.6,7.42,831117.2,1,908557.4,32,926898.45,2,941285.8,32,962921.2,1,964259,1,975486,1,978582.6,5.319999999999999]]}, +{"name":"random 18, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[5,-727743.1499999999,64,-157577.61254772893,621.9499999999999,7.02639849371711,1489.7600000000002,17.60893635326422,1831.83,35.26127002557515,1708.6900000000005,7286.868730683409,1178.6499999999999,500530.1671018836,186.88,893447.2,6.3999999999999995]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-727743.1499999999,-727743.1499999999,-663105.9363226059,-107752.38706653508,9.200578776687657,22.120638945937298,2316.9003668357245,61744.40135123891,323303.5120721576,513540.66487996693,513540.66487996693,513540.66487996693,"NaN","NaN","NaN"],[5,-727743.1499999999,64,-157577.61254772893,621.9499999999999,7.02639849371711,1489.7600000000002,17.60893635326422,1831.83,35.26127002557515,1708.6900000000005,7286.868730683409,1178.6499999999999,513540.66487996693,193.28]]}, +{"name":"random 19, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[20,0.141,33,0.5319502292075966,91.62,0.971317616673674,166.48999999999998,1.5996826817801246,155.26999999999998,2.782297806956279,286.35999999999996,4.26857460182025,351.6,5.798136174667266,334.35,7.356706245246346,354.99,8.922438531001136,281.28,10.787517768278676,313.47999999999996,13.49585267835224,407.34,16.375925678219467,451.55,19.88293821062045,469.6600000000001,25.09424047867018,489.6899999999999,28.850131986303307,353.36999999999995,35.98230711610488,493.95,43.46533948454898,159.86,48.07828228248742,439.17,57.460482110912345,357.76,65.49857005532503,289.20000000000005,73.94527097375196,182.49,85.32599861288945,187.44,100.55990043868015,104.86000000000001,121.79772585847088,105.42,140.45257686027523,42.87,190.733,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0.141,0.141,0.4706549303117889,3.2521910790474657,7.995689497608577,19.805847206635335,44.45291414545344,68.30188842539019,85.6039404481166,128.72660222496867,176.05329407720976,190.733,"NaN","NaN","NaN"],[20,0.141,33,0.5319502292075966,91.62,0.971317616673674,166.48999999999998,1.5996826817801246,155.26999999999998,2.782297806956279,286.35999999999996,4.26857460182025,351.6,5.798136174667266,334.35,7.356706245246346,354.99,8.922438531001136,281.28,10.787517768278676,313.47999999999996,13.49585267835224,407.34,16.375925678219467,451.55,19.88293821062045,469.6600000000001,25.09424047867018,489.6899999999999,28.850131986303307,353.36999999999995,35.98230711610488,493.95,43.46533948454898,159.86,48.07828228248742,439.17,57.460482110912345,357.76,65.49857005532503,289.20000000000005,73.94527097375196,182.49,85.32599861288945,187.44,100.55990043868015,104.86000000000001,121.79772585847088,105.42,140.45257686027523,42.87,190.733,1]]}, +{"name":"random 20, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[20,12.105339361702127,28.2,21.855691869774063,56.21,54.16293910084184,167.49,95.20946367374914,233.44,135.80636878956452,312.78000000000003,187.98511918774997,392.49,243.8445583967918,443.86,302.13713493886166,483.33,349.643610180782,540.4300000000001,411.23378665242507,505.55999999999995,466.94274865576654,182.26,496.39902297769146,478.29,564.4388381795196,442.96,622.6536063338325,313.87,670.0999835356688,432.44999999999993,730.7850219172274,518.77,796.907702469571,482.27,842.780271634075,355.91999999999996,878.9801517531045,328.56,913.9345930563916,249.15,950.7361934659912,242.73,982.7230132667805,152.26,992.6456473175023,68.22,997.782,9.54]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[12.105339361702127,12.105339361702127,27.027566564196608,150.65852439654472,299.51230607893933,514.9110226307045,769.4629324876588,896.4148372707946,947.7932924525097,989.894924661083,997.4317768411674,997.782,"NaN","NaN","NaN"],[20,12.105339361702127,28.2,21.855691869774063,56.21,54.16293910084184,167.49,95.20946367374914,233.44,135.80636878956452,312.78000000000003,187.98511918774997,392.49,243.8445583967918,443.86,302.13713493886166,483.33,349.643610180782,540.4300000000001,411.23378665242507,505.55999999999995,466.94274865576654,182.26,496.39902297769146,478.29,564.4388381795196,442.96,622.6536063338325,313.87,670.0999835356688,432.44999999999993,730.7850219172274,518.77,796.907702469571,482.27,842.780271634075,355.91999999999996,878.9801517531045,328.56,913.9345930563916,249.15,950.7361934659912,242.73,982.7230132667805,152.26,992.6456473175023,68.22,997.782,9.54]]}, +{"name":"random 21, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,0,1,0,4,0,2,0,7.819999999999999,0,5.34,0,10.92,0,4,0,32,0,13.62,0,32,0,14.969999999999999,0,32,0,31.86,0,36,0.07908796546141393,37.06,1,4.12,1,40.16,1,36.57,1,34.31,1.0406022635408245,49.48,2,4.569999999999999,2,49.41,2,52.489999999999995,2,38.03,2,42.6,2.2381719136894236,56.54,3,37.24,3,33,3,43.59,3,63.52,3,35.31,3,37.940000000000005,3,50.989999999999995,3.317790674404643,49.970000000000006,4,39.55,4,71.77,4,45.779999999999994,4.273263908959537,55.36,5,66,5,70.42,5,73.43,5,54.36,5.384139740856159,60.97,6,68,6,84.86,6,64.28999999999999,6.576649993900207,81.97,7,75.97999999999999,7,89.53,7,84.93,7,66.11,7,66,7.577296239210852,97.32000000000001,8,68.98,8,90.64999999999999,8,68.59,8.274128659629554,100.41999999999999,9,33,9,75,9.289876119092234,96.06,10,34,10,87.92999999999999,10,89.70000000000002,10,97,10.91415408525755,90.07999999999998,11,75.25,11,80.07000000000001,11,95.82,11.606707805664287,86.85999999999999,12,69.57,12,86.82000000000001,12,70.52,12.502724568709102,84.05,13,35,13,91.57,13,70.33999999999999,13,86.44999999999999,13.894273644684345,85.21999999999998,14,67,14,75.11000000000001,14,84.89999999999999,14.59330512692882,80.36,15,59.22,15,78.03999999999999,15,85.41999999999999,15.454013015184382,73.75999999999999,16,65,16,81.58000000000001,16,60.79,16,74.68,16.934138309549944,81.99,17,53.4,17,74.67,17,44.199999999999996,17,67,17,67.34,17.744950559247847,61.69,18,67.45,18,32,18,64,18.43840116809637,54.79,19,34,19,33,19,33.41,19,32,19,33,19,54.35,19,42.47,19,35.39,19,32,19,32,19,34,19,33,19,36.89,19,13.97,19.014676470588235,34,19.778,32,23.197594977462973,15.53,27.283,32,32.131,1,32.648,32,33.282,1,33.33,32,41.03599899345747,19.869999999999997,45.785,32,54.82165846153846,9.75,86.014,1,394.245,7.21,571.3143444108761,3.3099999999999996,704.976,1,822.136,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,2.4535276672412847,6,10.978378855078477,16,19,19,40.863516540567474,472.8977889256459,822.136,"NaN","NaN","NaN"],[100,0,1,0,4,0,2,0,7.819999999999999,0,5.34,0,10.92,0,4,0,32,0,13.62,0,32,0,14.969999999999999,0,32,0,31.86,0,36,0.07908796546141393,37.06,1,4.12,1,40.16,1,36.57,1,34.31,1.0406022635408245,49.48,2,4.569999999999999,2,49.41,2,52.489999999999995,2,38.03,2,42.6,2.2381719136894236,56.54,3,37.24,3,33,3,43.59,3,63.52,3,35.31,3,37.940000000000005,3,50.989999999999995,3.317790674404643,49.970000000000006,4,39.55,4,71.77,4,45.779999999999994,4.273263908959537,55.36,5,66,5,70.42,5,73.43,5,54.36,5.384139740856159,60.97,6,68,6,84.86,6,64.28999999999999,6.576649993900207,81.97,7,75.97999999999999,7,89.53,7,84.93,7,66.11,7,66,7.577296239210852,97.32000000000001,8,68.98,8,90.64999999999999,8,68.59,8.274128659629554,100.41999999999999,9,33,9,75,9.289876119092234,96.06,10,34,10,87.92999999999999,10,89.70000000000002,10,97,10.91415408525755,90.07999999999998,11,75.25,11,80.07000000000001,11,95.82,11.606707805664287,86.85999999999999,12,69.57,12,86.82000000000001,12,70.52,12.502724568709102,84.05,13,35,13,91.57,13,70.33999999999999,13,86.44999999999999,13.894273644684345,85.21999999999998,14,67,14,75.11000000000001,14,84.89999999999999,14.59330512692882,80.36,15,59.22,15,78.03999999999999,15,85.41999999999999,15.454013015184382,73.75999999999999,16,65,16,81.58000000000001,16,60.79,16,74.68,16.934138309549944,81.99,17,53.4,17,74.67,17,44.199999999999996,17,67,17,67.34,17.744950559247847,61.69,18,67.45,18,32,18,64,18.43840116809637,54.79,19,34,19,33,19,33.41,19,32,19,33,19,54.35,19,42.47,19,35.39,19,32,19,32,19,34,19,33,19,36.89,19,13.97,19.014676470588235,34,19.778,32,23.197594977462973,15.53,27.283,32,32.131,1,32.648,32,33.282,1,33.33,32,41.03599899345747,19.869999999999997,45.785,32,54.82165846153846,9.75,86.014,1,394.245,7.21,571.3143444108761,3.3099999999999996,704.976,1,822.136,1]]}, +{"name":"random 22, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,0,1,0,9.04,0,32,0,5.66,0,32,0,32,0,9.48,0,32,0.5,2,1,32,1,17.509999999999998,1,32,1.296296296296296,22.68,2,12.57,2,32,2,12.83,2,32,2,32,2.379506641366224,10.54,3,32,3,1,3,32,3,32,3,2.83,3,32,4,3.5799999999999996,4,32,4,0.91,4,32,4,14.16,4,32,4,5.359999999999999,4,32,4,33.3,4,3,4,32.9,4,12.01,5,35,5,34,5,35.49,5,7.4799999999999995,5,32,6,10.25,6,36,6,9.5,7,34,7,8.21,7,33,7,32,7,33,8,22.630000000000003,8,32,8,9.93,8,32,8.045801526717558,36.68,9,10.17,9,37,9,37.15,10,36.1,10,13.89,10,33,10,19.57,11,36.69,11,34,11,36.34,11,33.95,11,32,11.030303030303031,33,12,33,12,34.29,12,33.94,12.951248513674198,33.64,13,28.32,13,32,14,16.32,14,32,14,6.18,14,32,14,1,14,32,14.333333333333334,3,15,32,15,21.800000000000004,15,32,15,32,15,3.82,16,32,16,21.51,17,32,17,15.189999999999998,17,10.1,17,32,17.10427528675704,19.18,18,32,18,32,18,11.92,18,7.79,18,32,18.619771863117872,7.890000000000001,19,32,19,3,19,6.05,19,9.59,19,1,19,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0,0,0,1.2091847516865812,4,8.03082333379274,13,17,18,19,19,19,"NaN","NaN","NaN"],[100,0,1,0,9.04,0,32,0,5.66,0,32,0,32,0,9.48,0,32,0.5,2,1,32,1,17.509999999999998,1,32,1.296296296296296,22.68,2,12.57,2,32,2,12.83,2,32,2,32,2.379506641366224,10.54,3,32,3,1,3,32,3,32,3,2.83,3,32,4,3.5799999999999996,4,32,4,0.91,4,32,4,14.16,4,32,4,5.359999999999999,4,32,4,33.3,4,3,4,32.9,4,12.01,5,35,5,34,5,35.49,5,7.4799999999999995,5,32,6,10.25,6,36,6,9.5,7,34,7,8.21,7,33,7,32,7,33,8,22.630000000000003,8,32,8,9.93,8,32,8.045801526717558,36.68,9,10.17,9,37,9,37.15,10,36.1,10,13.89,10,33,10,19.57,11,36.69,11,34,11,36.34,11,33.95,11,32,11.030303030303031,33,12,33,12,34.29,12,33.94,12.951248513674198,33.64,13,28.32,13,32,14,16.32,14,32,14,6.18,14,32,14,1,14,32,14.333333333333334,3,15,32,15,21.800000000000004,15,32,15,32,15,3.82,16,32,16,21.51,17,32,17,15.189999999999998,17,10.1,17,32,17.10427528675704,19.18,18,32,18,32,18,11.92,18,7.79,18,32,18.619771863117872,7.890000000000001,19,32,19,3,19,6.05,19,9.59,19,1,19,1]]}, +{"name":"random 23, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100,-996665.1,7.56,-989912.3837004405,2.27,-980282.4,32,-972873.0666666668,3,-946369.6,8.049999999999999,-943338.1,3.1199999999999997,-941607,32,-938706.3,32,-923646.0361452841,17.07,-877407.1,1,-873321.4,32,-870204.5,32,-858520.7,32,-847921.474111675,7.88,-846956.4,32,-834197.375,4,-826034.6,32,-815567.695335277,3.4299999999999997,-786540.3,32,-775020.2,1,-773639.8,32,-737694.115455305,11.969999999999999,-694781.2,32,-665035.1579862699,21.849999999999998,-614395.3,32,-611155.8,1,-597028.5,32,-592296,32,-586975.7784810127,3.95,-579962.7,32,-578472.7136752136,9.36,-558980.9,32,-539435.2250000001,8,-509634.7,32,-499801.9467484663,8.15,-487968.6856182403,34.21,-449381.48633093527,6.949999999999999,-423968.80208519514,33.57,-400762.9235294117,34,-393380.31176470587,34,-358613.60000000003,33,-340229.3,4.75,-339914.71212121216,33,-326691.3532031894,36.370000000000005,-281072.13094339625,7.949999999999999,-255937.1,32,-238499.9934268186,22.82,-200469.15,34,-178175.79903691815,37.38,-145291.76416201936,34.07,-123272.34267100978,18.42,-99338.75907887772,37.78,-64677.73611111111,36,-19679.2508131165,37.51,575.6170367428003,10.07,875.1136969696969,33,12120.7,32,14928.022717622083,37.68,60777.4,7.83,64406.69696969697,33,73917.82370160529,10.59,87616.74644194756,37.38,98732.85428571429,35,106852.38924731183,37.2,209537.3674050633,12.64,263171.4,32,266338.2553165707,33.01,296303.1664937759,19.28,322281.2303030303,33,343438.7485714286,35,370041.1,9.14,370282.5,32,372368.02558139537,5.16,376577.2617647059,34,385027.11818181816,33,408881.04422745545,17.409999999999997,467839.2,32,469430.9,32,474468.9992647059,10.879999999999999,500425.8,32,514145.3,32,530105.8589307412,8.229999999999999,534092.7,32,535613.7,1,547585.7,32,580986.9448261416,23.869999999999997,614432.6,32,659408.8052489907,22.29,694672.6,32,734854.9772750125,19.89,755048,32,765761.7,2,777693,32,782760.8,1,800398.5,32,837305.7337429594,19.53,862031.3,7.6,871896.7,32,882871.9,1,890680.5,32,896679.8,32,902182.5,1,904455.8,32,920517.0012931034,9.28,940686.8,3,962498.1,32,973562.95,2,988761.9,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-996665.1,-996665.1,-981145.642192231,-847682.8675233823,-554250.8466500001,-3489.8303774261844,468944.4366875,780908.7494545454,891957.2260312501,955899.8701600003,973283.4649064705,988761.9,"NaN","NaN","NaN"],[100,-996665.1,7.56,-989912.3837004405,2.27,-980282.4,32,-972873.0666666668,3,-946369.6,8.049999999999999,-943338.1,3.1199999999999997,-941607,32,-938706.3,32,-923646.0361452841,17.07,-877407.1,1,-873321.4,32,-870204.5,32,-858520.7,32,-847921.474111675,7.88,-846956.4,32,-834197.375,4,-826034.6,32,-815567.695335277,3.4299999999999997,-786540.3,32,-775020.2,1,-773639.8,32,-737694.115455305,11.969999999999999,-694781.2,32,-665035.1579862699,21.849999999999998,-614395.3,32,-611155.8,1,-597028.5,32,-592296,32,-586975.7784810127,3.95,-579962.7,32,-578472.7136752136,9.36,-558980.9,32,-539435.2250000001,8,-509634.7,32,-499801.9467484663,8.15,-487968.6856182403,34.21,-449381.48633093527,6.949999999999999,-423968.80208519514,33.57,-400762.9235294117,34,-393380.31176470587,34,-358613.60000000003,33,-340229.3,4.75,-339914.71212121216,33,-326691.3532031894,36.370000000000005,-281072.13094339625,7.949999999999999,-255937.1,32,-238499.9934268186,22.82,-200469.15,34,-178175.79903691815,37.38,-145291.76416201936,34.07,-123272.34267100978,18.42,-99338.75907887772,37.78,-64677.73611111111,36,-19679.2508131165,37.51,575.6170367428003,10.07,875.1136969696969,33,12120.7,32,14928.022717622083,37.68,60777.4,7.83,64406.69696969697,33,73917.82370160529,10.59,87616.74644194756,37.38,98732.85428571429,35,106852.38924731183,37.2,209537.3674050633,12.64,263171.4,32,266338.2553165707,33.01,296303.1664937759,19.28,322281.2303030303,33,343438.7485714286,35,370041.1,9.14,370282.5,32,372368.02558139537,5.16,376577.2617647059,34,385027.11818181816,33,408881.04422745545,17.409999999999997,467839.2,32,469430.9,32,474468.9992647059,10.879999999999999,500425.8,32,514145.3,32,530105.8589307412,8.229999999999999,534092.7,32,535613.7,1,547585.7,32,580986.9448261416,23.869999999999997,614432.6,32,659408.8052489907,22.29,694672.6,32,734854.9772750125,19.89,755048,32,765761.7,2,777693,32,782760.8,1,800398.5,32,837305.7337429594,19.53,862031.3,7.6,871896.7,32,882871.9,1,890680.5,32,896679.8,32,902182.5,1,904455.8,32,920517.0012931034,9.28,940686.8,3,962498.1,32,973562.95,2,988761.9,1]]}, +{"name":"random 24, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,5.507,3.61,10.48,1,12.17,1,14.874,1,19.774,32,20.312,5.71,22.579,32,26.204,1,29.276,1,31.2,1,35.048,1,35.67853846153846,1.3,40.129,1,43.49,6.109999999999999,44.501,1,51.531,32,52.691,1,55.035,32,56.226,32,57.266,4.25,59.633,32,60.899,1,65.017,5.58,73.8945,2,85.561,1,89.219,5.41,90.455,1,100.353,7.09,111.037,1,112.753,32,115.3415,2,116.837,1,116.871,2.17,122.529,32,126.769,1,127.159,2.6199999999999997,141.086,2,145.577,8.64,152.65699999999998,2,154.921,5.87,158.937,32,160.061,1,164.921,32,171.9675,2,176.215,32,180.506,4.39,193.2385,2,195.69,2,199.0855,2,203.2585,2,207.176,7.34,208.47,32,214.466,1,216.515,32,218.465,32,226.757,4.77,227.258,7.779999999999999,227.444,32,228.607,3.15,229.499,32,231.742,32,233.96756906077349,1.81,237.763,32,239.25,3.46,241.814,32,245.864,32,250.379,6.8,251.593,8.82,252.348,1,256.974,32,260.68,32,263.781,3,277.101,2,277.657,32,292.496,6.83,306.963,3,320.715,32,323.28366666666665,3,327.518,32,333.849,4.4399999999999995,334.049,6.67,336.845,2,338.9,32,340.716,1,342.295,7.279999999999999,352.9236666666667,3,359.7280769230769,3.25,363.204,1,377.356,32,379.829,2,387.936,5.7299999999999995,390.488,5.46,393.2645765765766,1.11,397.29,32,398.8072157434402,3.4299999999999997,401.3415,2,403.724,32,410.128,4.35,417.87033333333335,3,420.2,6.92,420.914,8.2,429.5942937062937,2.86,438.2675909090909,2.64,444.43,3,454.915,1,457.911,3.0399999999999996,475.01366079295155,2.27,486.811,6.75,488.422,32,489.233,2.86,496.38366666666667,3,502.465,32,506.64486021505377,2.79,525.8906666666667,3,536.103,2,537.129,32,541.0285,2,546.312,3.4099999999999997,549.268,9.53,550.921,3.9899999999999998,552.455,9.83,558.8595,2,566.316,4.08,568.426,1,569.407,3.8099999999999996,573.7483333333333,3,577.462,1,579.145,32,586.4083333333333,3,590.781,2,594.3267642276422,2.46,598.993,1,600.169,5.779999999999999,604.296512605042,2.38,618.2436411960133,3.01,636.144,3,649.991,32,656.417,1,657.044,32,662.027,1,663.586,9.89,666.401,5.85,673.7725,2,687.062,4.85,688.903,32,690.353,32,692.127,7.24,693.907,32,694.729,2,695.517,8.83,698.324,9.54,699.3285,2,700.165,32,704.649,1,714.551,32,722.2661165048544,2.06,738.9259999999999,2,746.346,1.37,749.696,3.59,750.154,1,750.935,3.2399999999999998,758.2825,2,773.558,2,778.338,1,783.344,6.6899999999999995,784.112,1,785.536,32,786.538,32,788.685,32,790.817,1,797.209,9.459999999999999,797.878,1,798.23,6.33,806.479,2,816.1165000000001,2,823.7685,2,844.4,32,845.974,1,850.974,32,853.829,6.97,856.239,1,858.366,3.5399999999999996,863.988,1,867.117,1.96,867.666,8.75,880.407,32,882.245,1,884.237,32,886.168,1,913.545,32,918.826,5.05,929.646,6.81,935.243,1,938.207,1.51,940.329,1,941.031,32,941.876,0.29000000000000004,946.952,32,956.714,32,958.638,1.19,958.842,1,959.377,5.02,960.487,1,960.91,1,962.855,1,967.543,32,969.876,32,970.192,0.51,979.309,1,989.345,1,990.505,1,991.406,9.18,995.984,1,996.527,1,998.271,8.69]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[5.507,6.3813202819956585,19.623287878787878,60.710634545454546,224.9923848245852,401.37583602941174,716.6564611835767,914.7494385964911,957.0708008436276,981.9936299999993,998.271,998.271,"NaN","NaN","NaN"],[1000,5.507,3.61,10.48,1,12.17,1,14.874,1,19.774,32,20.312,5.71,22.579,32,26.204,1,29.276,1,31.2,1,35.048,1,35.67853846153846,1.3,40.129,1,43.49,6.109999999999999,44.501,1,51.531,32,52.691,1,55.035,32,56.226,32,57.266,4.25,59.633,32,60.899,1,65.017,5.58,73.8945,2,85.561,1,89.219,5.41,90.455,1,100.353,7.09,111.037,1,112.753,32,115.3415,2,116.837,1,116.871,2.17,122.529,32,126.769,1,127.159,2.6199999999999997,141.086,2,145.577,8.64,152.65699999999998,2,154.921,5.87,158.937,32,160.061,1,164.921,32,171.9675,2,176.215,32,180.506,4.39,193.2385,2,195.69,2,199.0855,2,203.2585,2,207.176,7.34,208.47,32,214.466,1,216.515,32,218.465,32,226.757,4.77,227.258,7.779999999999999,227.444,32,228.607,3.15,229.499,32,231.742,32,233.96756906077349,1.81,237.763,32,239.25,3.46,241.814,32,245.864,32,250.379,6.8,251.593,8.82,252.348,1,256.974,32,260.68,32,263.781,3,277.101,2,277.657,32,292.496,6.83,306.963,3,320.715,32,323.28366666666665,3,327.518,32,333.849,4.4399999999999995,334.049,6.67,336.845,2,338.9,32,340.716,1,342.295,7.279999999999999,352.9236666666667,3,359.7280769230769,3.25,363.204,1,377.356,32,379.829,2,387.936,5.7299999999999995,390.488,5.46,393.2645765765766,1.11,397.29,32,398.8072157434402,3.4299999999999997,401.3415,2,403.724,32,410.128,4.35,417.87033333333335,3,420.2,6.92,420.914,8.2,429.5942937062937,2.86,438.2675909090909,2.64,444.43,3,454.915,1,457.911,3.0399999999999996,475.01366079295155,2.27,486.811,6.75,488.422,32,489.233,2.86,496.38366666666667,3,502.465,32,506.64486021505377,2.79,525.8906666666667,3,536.103,2,537.129,32,541.0285,2,546.312,3.4099999999999997,549.268,9.53,550.921,3.9899999999999998,552.455,9.83,558.8595,2,566.316,4.08,568.426,1,569.407,3.8099999999999996,573.7483333333333,3,577.462,1,579.145,32,586.4083333333333,3,590.781,2,594.3267642276422,2.46,598.993,1,600.169,5.779999999999999,604.296512605042,2.38,618.2436411960133,3.01,636.144,3,649.991,32,656.417,1,657.044,32,662.027,1,663.586,9.89,666.401,5.85,673.7725,2,687.062,4.85,688.903,32,690.353,32,692.127,7.24,693.907,32,694.729,2,695.517,8.83,698.324,9.54,699.3285,2,700.165,32,704.649,1,714.551,32,722.2661165048544,2.06,738.9259999999999,2,746.346,1.37,749.696,3.59,750.154,1,750.935,3.2399999999999998,758.2825,2,773.558,2,778.338,1,783.344,6.6899999999999995,784.112,1,785.536,32,786.538,32,788.685,32,790.817,1,797.209,9.459999999999999,797.878,1,798.23,6.33,806.479,2,816.1165000000001,2,823.7685,2,844.4,32,845.974,1,850.974,32,853.829,6.97,856.239,1,858.366,3.5399999999999996,863.988,1,867.117,1.96,867.666,8.75,880.407,32,882.245,1,884.237,32,886.168,1,913.545,32,918.826,5.05,929.646,6.81,935.243,1,938.207,1.51,940.329,1,941.031,32,941.876,0.29000000000000004,946.952,32,956.714,32,958.638,1.19,958.842,1,959.377,5.02,960.487,1,960.91,1,962.855,1,967.543,32,969.876,32,970.192,0.51,979.309,1,989.345,1,990.505,1,991.406,9.18,995.984,1,996.527,1,998.271,8.69]]}, +{"name":"random 25, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[20]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[20]]}, +{"name":"random 26, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[1000,7.623,1,7.655,32,8.474,32,9.11,3.8299999999999996,13.625499999999999,2,14.924,9.97,17.133,1,17.498,32,18.632,1,21.193,32,23.588,32,25.146,1,26.417,32,28.374971786833857,3.19,29.802482428115017,3.13,30.262,32,32.35,1,34.326,32,37.15666666666667,3,38.633,5.88,39.006,32,42.0185,2,46.556,32,48.750725075528706,3.3099999999999996,50.381,32,52.229,32,53.872,7.4799999999999995,54.44033333333333,3,55.428,8.75,61.87097920997921,4.81,69.11,1,69.196,32,69.90169902912622,2.06,75.955,32,76.341,1,76.63,6.97,77.422,1,80.57,5.26,82.49066666666667,3,85.889,32,86.826,0.43,88.487,32,92.71075,4,96.357,32,97.131,32,98.941,9.299999999999999,107.60549999999999,4,112.927,5.68,113.488,32,114.755,32,117.96381758957655,3.07,122.699,32,125.342,1,125.429,32,128.028,1,130.346,8.29,130.351,1,131.159,8.87,136.34616666666665,6,141.459,7.38,142.0495,2,143.222,32,145.8145,2,148.464,32,149.09,9.9,149.284,32,150.953626984127,5.04,155.78,32,158.661,32,159.38,1,160.624,9.47,164.1041047835991,4.39,165.031,32,165.411,32,168.77,32,170.08,1,173.451,32,177.387,32,177.885,1,181.332,32,188.0015,4,194.588,32,196.392,1,202.793,32,204.44059543817525,8.33,209.06627785058978,7.63,216.05649716446123,5.289999999999999,218.116,8.27,218.4627533632287,4.46,223.579,32,224.142,8.52,227.01844345238095,6.72,229.9,32,231.187,32,235.0025,2,236.599,32,237.473,1.49,237.665,32,239.89172586872587,7.77,241.57264248704664,7.72,245.533,32,247.61294915254237,8.85,248.30683796856104,8.27,249.5745,2,251.133,32,252.527,32,253.66000000000003,2,257.013,32,259.0968962264151,8.48,264.317,32,265.084,1,266.65,32,266.859,2.42,267.242,32,267.6805,2,267.932,9.18,270.489,3,271.556,32,273.86127510917026,9.16,281.544,7.1899999999999995,281.997,32,282.5911505376344,4.65,284.229,5.2299999999999995,284.59745910290235,7.58,285.3847112462006,3.2899999999999996,288.049,32,290.539,1,290.964,32,294.505,1,295.517,32,295.9989420935412,8.98,299.989,1,300.59,32,302.9397106918239,9.54,306.026,1,307.056,32,308.314,7.279999999999999,309.9,8.62,312.156,32,315.55600000000004,4,317.783,32,325.65525,8,329.356,32,330.748,32,332.5465991041433,8.93,336.549,32,338.778,2.7199999999999998,339.881,8.93,340.019,32,346.1282809224319,9.54,354.1580374064838,8.02,356.586,2.4499999999999997,357.605,32,361.39749736008446,9.469999999999999,365.3684285714286,5.25,365.885,32,365.919,32,367.184,32,370.3043827160494,9.72,370.7005,2,371.033,32,372.133,1,374.403,9.69,375.926,32,377.712,6.64,378.057,9.11,379.174,32,383.3080197044335,10.149999999999999,392.31483470225874,9.74,402.6195,2,404.56,32,406.253,3,408.335,32,411.0507159309021,10.42,413.2042483156881,10.389999999999999,415.6218314606742,8.899999999999999,417.476,32,418.455,5.029999999999999,420.207,32,421.221,32,421.87271122994656,9.35,424.357,32,426.877,2,427.607,32,430.209,5.54,430.986,32,431.243,9.799999999999999,431.27,32,431.414,32,436.1150290262172,10.68,443.656,32,445.708,32,445.88,1,448.444,32,449.829,2,451.17,32,452.73546691871456,10.58,454.364,32,455.48,1,456.314,32,459.568,32,459.735,32,465.98825157232704,6.359999999999999,467.228,32,469.35766666666666,3,471.073,32,475.62068203650335,10.41,476.834,32,477.493,32,479.987,1,480.912,32,483.784,1,487.268,32,491.877,9.52,494.67889433237275,10.41,503.2227958687728,8.23,509.009,9.43,510.429,2.9699999999999998,513.243,32,515.357,32,519.8119093406594,7.279999999999999,520.292,32,520.9387208121827,9.85,522.495,32,522.7940000000001,2,523.368,32,524.804,1,524.829,32,529.4397434554974,7.64,532.0756484018265,8.76,535.4244796954315,7.879999999999999,537.5294943820224,4.449999999999999,540.416,32,541.5158383371826,8.66,546.049,32,547.118,1,547.615,32,548.1064737945493,4.77,549.019,32,549.661,1,553.908,32,555.9573267326733,6.06,558.088,32,559.8435,2,561.7639922405432,10.31,566.8296000000001,5,570.924,32,571.7880854126679,10.42,578.099923076923,6.5,581.707893877551,9.8,585.9408974358975,1.95,587.738,32,589.358288184438,6.9399999999999995,592.252,5.359999999999999,593.244,32,594.467,1,595.449,32,596.249,32,597.0773333333333,3,599.812,32,600.473,32,603.3083517786562,5.06,604.47,9.76,607.9788326359833,9.56,609.402861167002,9.94,615.658834532374,9.73,623.5474772277228,10.1,626.78075,4,629.209,32,630.677,1.11,632.312,9.79,633.508,1,634.047,32,636.2257672176308,7.26,640.4939970326409,10.11,641.23,1,642.58,32,645.342318275154,9.74,652.1242432432432,9.620000000000001,655.184038647343,10.35,660.7769765625,10.24,663.271,5.3999999999999995,663.559,9.91,665.6765,2,667.731,32,668.071,32,674.1404331550802,9.35,680.103,3,682.254,32,683.204,3,685.427,32,686.5723252769385,9.93,689.42,5.84,690.252,9.6,692.625,32,695.683,32,696.765,32,699.1353281086729,9.57,702.086,2,703.208,32,707.2725834633386,6.41,707.942,9.17,712.8040000000001,5,719.28,32,721.8625,2,722.559,9.15,723.4370287859825,7.99,723.527,32,723.66,32,723.742,9.34,729.8748571428572,7,734.951,32,739.7199879649892,9.14,748.6074285714286,7,751.41,32,753.0667479674796,8.61,754.3212549019607,3.57,755.1,32,755.383,32,756.677,9.4,758.178,32,760.6021905882353,8.5,761.717,1,761.891,32,762.029,32,763.5295000000001,2,764.138,32,765.7165,2,767.892,8,769.059,4.14,769.273,32,774.039,1,776.131,32,776.3385000000001,2,777.173,32,779.7024519774011,3.54,785.259,32,786.5279289940829,8.45,787.566,1,787.66,32,787.774,1,787.798,8.42,789.841,1.47,789.964,32,793.1420415430267,6.739999999999999,796.673,32,799.7724401913875,8.36,804.86,32,806.034,32,807.8760791366907,5.56,810.63,32,815.7536666666666,3,820.287,7.76,825.51075,4,828.371,9.15,831.264424068768,6.9799999999999995,834.345,32,842.021375,8,849.422,32,850.944,1,852.214,32,852.531,8.92,856.7936766712141,7.33,860.561,8.53,862.683,32,865.275,1.67,866.553,32,866.8105465288036,6.77,870.7831779661017,4.72,875.061,9.26,876.0960107816712,7.42,878.5063333333333,3,885.743,32,886.49,1,887.063,32,887.1921552062869,5.09,887.672,3.42,887.878,32,889.8197098865478,6.17,890.962,6.56,891.6445000000001,2,891.78,32,896.586,8.36,897.873,1,898.593,6.069999999999999,898.676,32,900.1417228915662,5.81,902.1756567656765,6.06,902.508,1,903.862,6.6899999999999995,903.911,1,908.403,32,908.9225,4,913.2967948717949,3.9,913.957,7.029999999999999,917.253,1,917.411,32,917.428,1,920.335,32,923.215,2.48,923.503,6.46,924.5111252955082,4.23,928.242,5.56,928.923,2,929.845,32,933.5438269896194,5.78,939.8683333333333,3,942.607,32,942.734,1,943.605,32,944.615,32,946.4186666666667,3,950.41,32,951.898,9.15,953.059,32,954.175,1,955.109,8.45,955.6448709677419,4.65,956.653,7.66,957.82,1,958.413,32,959.79675,4,962.713,32,963.898,32,964.093,6.75,964.154,1,967.484,32,970.43,32,970.7236666666666,3,971.855,1,972.99,9.47,973.337,32,974.759,32,974.773,1,974.983,7.26,976.799,2,977.894,2,979.302,1,979.312,32,979.985,4.24,980.7695,2,981.414,32,982.454,1,984.344,2.44,987.976,2.8299999999999996,991.428,1.93,994.004,1,995.814,32,995.997,1,997.283,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[7.623,7.635455427878789,12.685687358490492,113.22545557324838,265.6366081818181,479.75498242424226,758.0770269323672,917.316267030303,959.4741440625,981.0339990088236,995.9368614309091,997.283,"NaN","NaN","NaN"],[1000,7.623,1,7.655,32,8.474,32,9.11,3.8299999999999996,13.625499999999999,2,14.924,9.97,17.133,1,17.498,32,18.632,1,21.193,32,23.588,32,25.146,1,26.417,32,28.374971786833857,3.19,29.802482428115017,3.13,30.262,32,32.35,1,34.326,32,37.15666666666667,3,38.633,5.88,39.006,32,42.0185,2,46.556,32,48.750725075528706,3.3099999999999996,50.381,32,52.229,32,53.872,7.4799999999999995,54.44033333333333,3,55.428,8.75,61.87097920997921,4.81,69.11,1,69.196,32,69.90169902912622,2.06,75.955,32,76.341,1,76.63,6.97,77.422,1,80.57,5.26,82.49066666666667,3,85.889,32,86.826,0.43,88.487,32,92.71075,4,96.357,32,97.131,32,98.941,9.299999999999999,107.60549999999999,4,112.927,5.68,113.488,32,114.755,32,117.96381758957655,3.07,122.699,32,125.342,1,125.429,32,128.028,1,130.346,8.29,130.351,1,131.159,8.87,136.34616666666665,6,141.459,7.38,142.0495,2,143.222,32,145.8145,2,148.464,32,149.09,9.9,149.284,32,150.953626984127,5.04,155.78,32,158.661,32,159.38,1,160.624,9.47,164.1041047835991,4.39,165.031,32,165.411,32,168.77,32,170.08,1,173.451,32,177.387,32,177.885,1,181.332,32,188.0015,4,194.588,32,196.392,1,202.793,32,204.44059543817525,8.33,209.06627785058978,7.63,216.05649716446123,5.289999999999999,218.116,8.27,218.4627533632287,4.46,223.579,32,224.142,8.52,227.01844345238095,6.72,229.9,32,231.187,32,235.0025,2,236.599,32,237.473,1.49,237.665,32,239.89172586872587,7.77,241.57264248704664,7.72,245.533,32,247.61294915254237,8.85,248.30683796856104,8.27,249.5745,2,251.133,32,252.527,32,253.66000000000003,2,257.013,32,259.0968962264151,8.48,264.317,32,265.084,1,266.65,32,266.859,2.42,267.242,32,267.6805,2,267.932,9.18,270.489,3,271.556,32,273.86127510917026,9.16,281.544,7.1899999999999995,281.997,32,282.5911505376344,4.65,284.229,5.2299999999999995,284.59745910290235,7.58,285.3847112462006,3.2899999999999996,288.049,32,290.539,1,290.964,32,294.505,1,295.517,32,295.9989420935412,8.98,299.989,1,300.59,32,302.9397106918239,9.54,306.026,1,307.056,32,308.314,7.279999999999999,309.9,8.62,312.156,32,315.55600000000004,4,317.783,32,325.65525,8,329.356,32,330.748,32,332.5465991041433,8.93,336.549,32,338.778,2.7199999999999998,339.881,8.93,340.019,32,346.1282809224319,9.54,354.1580374064838,8.02,356.586,2.4499999999999997,357.605,32,361.39749736008446,9.469999999999999,365.3684285714286,5.25,365.885,32,365.919,32,367.184,32,370.3043827160494,9.72,370.7005,2,371.033,32,372.133,1,374.403,9.69,375.926,32,377.712,6.64,378.057,9.11,379.174,32,383.3080197044335,10.149999999999999,392.31483470225874,9.74,402.6195,2,404.56,32,406.253,3,408.335,32,411.0507159309021,10.42,413.2042483156881,10.389999999999999,415.6218314606742,8.899999999999999,417.476,32,418.455,5.029999999999999,420.207,32,421.221,32,421.87271122994656,9.35,424.357,32,426.877,2,427.607,32,430.209,5.54,430.986,32,431.243,9.799999999999999,431.27,32,431.414,32,436.1150290262172,10.68,443.656,32,445.708,32,445.88,1,448.444,32,449.829,2,451.17,32,452.73546691871456,10.58,454.364,32,455.48,1,456.314,32,459.568,32,459.735,32,465.98825157232704,6.359999999999999,467.228,32,469.35766666666666,3,471.073,32,475.62068203650335,10.41,476.834,32,477.493,32,479.987,1,480.912,32,483.784,1,487.268,32,491.877,9.52,494.67889433237275,10.41,503.2227958687728,8.23,509.009,9.43,510.429,2.9699999999999998,513.243,32,515.357,32,519.8119093406594,7.279999999999999,520.292,32,520.9387208121827,9.85,522.495,32,522.7940000000001,2,523.368,32,524.804,1,524.829,32,529.4397434554974,7.64,532.0756484018265,8.76,535.4244796954315,7.879999999999999,537.5294943820224,4.449999999999999,540.416,32,541.5158383371826,8.66,546.049,32,547.118,1,547.615,32,548.1064737945493,4.77,549.019,32,549.661,1,553.908,32,555.9573267326733,6.06,558.088,32,559.8435,2,561.7639922405432,10.31,566.8296000000001,5,570.924,32,571.7880854126679,10.42,578.099923076923,6.5,581.707893877551,9.8,585.9408974358975,1.95,587.738,32,589.358288184438,6.9399999999999995,592.252,5.359999999999999,593.244,32,594.467,1,595.449,32,596.249,32,597.0773333333333,3,599.812,32,600.473,32,603.3083517786562,5.06,604.47,9.76,607.9788326359833,9.56,609.402861167002,9.94,615.658834532374,9.73,623.5474772277228,10.1,626.78075,4,629.209,32,630.677,1.11,632.312,9.79,633.508,1,634.047,32,636.2257672176308,7.26,640.4939970326409,10.11,641.23,1,642.58,32,645.342318275154,9.74,652.1242432432432,9.620000000000001,655.184038647343,10.35,660.7769765625,10.24,663.271,5.3999999999999995,663.559,9.91,665.6765,2,667.731,32,668.071,32,674.1404331550802,9.35,680.103,3,682.254,32,683.204,3,685.427,32,686.5723252769385,9.93,689.42,5.84,690.252,9.6,692.625,32,695.683,32,696.765,32,699.1353281086729,9.57,702.086,2,703.208,32,707.2725834633386,6.41,707.942,9.17,712.8040000000001,5,719.28,32,721.8625,2,722.559,9.15,723.4370287859825,7.99,723.527,32,723.66,32,723.742,9.34,729.8748571428572,7,734.951,32,739.7199879649892,9.14,748.6074285714286,7,751.41,32,753.0667479674796,8.61,754.3212549019607,3.57,755.1,32,755.383,32,756.677,9.4,758.178,32,760.6021905882353,8.5,761.717,1,761.891,32,762.029,32,763.5295000000001,2,764.138,32,765.7165,2,767.892,8,769.059,4.14,769.273,32,774.039,1,776.131,32,776.3385000000001,2,777.173,32,779.7024519774011,3.54,785.259,32,786.5279289940829,8.45,787.566,1,787.66,32,787.774,1,787.798,8.42,789.841,1.47,789.964,32,793.1420415430267,6.739999999999999,796.673,32,799.7724401913875,8.36,804.86,32,806.034,32,807.8760791366907,5.56,810.63,32,815.7536666666666,3,820.287,7.76,825.51075,4,828.371,9.15,831.264424068768,6.9799999999999995,834.345,32,842.021375,8,849.422,32,850.944,1,852.214,32,852.531,8.92,856.7936766712141,7.33,860.561,8.53,862.683,32,865.275,1.67,866.553,32,866.8105465288036,6.77,870.7831779661017,4.72,875.061,9.26,876.0960107816712,7.42,878.5063333333333,3,885.743,32,886.49,1,887.063,32,887.1921552062869,5.09,887.672,3.42,887.878,32,889.8197098865478,6.17,890.962,6.56,891.6445000000001,2,891.78,32,896.586,8.36,897.873,1,898.593,6.069999999999999,898.676,32,900.1417228915662,5.81,902.1756567656765,6.06,902.508,1,903.862,6.6899999999999995,903.911,1,908.403,32,908.9225,4,913.2967948717949,3.9,913.957,7.029999999999999,917.253,1,917.411,32,917.428,1,920.335,32,923.215,2.48,923.503,6.46,924.5111252955082,4.23,928.242,5.56,928.923,2,929.845,32,933.5438269896194,5.78,939.8683333333333,3,942.607,32,942.734,1,943.605,32,944.615,32,946.4186666666667,3,950.41,32,951.898,9.15,953.059,32,954.175,1,955.109,8.45,955.6448709677419,4.65,956.653,7.66,957.82,1,958.413,32,959.79675,4,962.713,32,963.898,32,964.093,6.75,964.154,1,967.484,32,970.43,32,970.7236666666666,3,971.855,1,972.99,9.47,973.337,32,974.759,32,974.773,1,974.983,7.26,976.799,2,977.894,2,979.302,1,979.312,32,979.985,4.24,980.7695,2,981.414,32,982.454,1,984.344,2.44,987.976,2.8299999999999996,991.428,1.93,994.004,1,995.814,32,995.997,1,997.283,1]]}, +{"name":"random 27, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[33.5,0.695,1,2.239,32,2.33,9.44,2.401,32,4.233031658637302,14.529999999999998,6.3668655126498,15.02,12.432674445740957,8.57,16.442,32,22.93,5,28.477,32,28.547,8.32,29.192,32,29.72,32,30.391,32,37.319398773006135,3.26,42.468,32,49.56638858397365,9.11,58.698,32,62.437222222222225,1.35,73.716,7.1899999999999995,103.939,1,119.804,9.44,121.914,1,130.154,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[0.695,0.695,1.0068224969696968,2.3320662644787644,6.269741772086456,28.735604910714287,37.28501222209077,58.10136880896506,65.45766306271145,120.97125038314176,130.154,130.154,"NaN","NaN","NaN"],[33.5,0.695,1,2.239,32,2.33,9.44,2.401,32,4.233031658637302,14.529999999999998,6.3668655126498,15.02,12.432674445740957,8.57,16.442,32,22.93,5,28.477,32,28.547,8.32,29.192,32,29.72,32,30.391,32,37.319398773006135,3.26,42.468,32,49.56638858397365,9.11,58.698,32,62.437222222222225,1.35,73.716,7.1899999999999995,103.939,1,119.804,9.44,121.914,1,130.154,1]]}, +{"name":"random 28, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[100]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",["NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN","NaN"],[100]]}, +{"name":"random 29, read back","compressions":[100],"ops":[{"op":"fromJSON","d":0,"json":[33.5,-966137.8744471745,4.07,-935094.6995893224,9.74,-907316.6,32,-904835.3005681818,7.04,-892542.7178896626,37.34,-855541.4904292597,45.66,-817068.6329949239,39.4,-800603.9205882354,34,-771221.6436506051,42.13,-733419.5015521663,74.09,-688008.6765460768,81.82,-554265.7804173355,80.99,-427257.6029102167,80.75,-376078.919965177,68.92,-322229.4859058704,79.03999999999999,-267995.3917525773,97,-242750.0911764706,102,-202562.41228215763,108.45,-146282.38144329897,97,-101338.38282634511,109.46999999999998,-31314.71932212938,106.51,37936.41513469882,99.11,154308.27742420224,113.13,297063.90751864744,100.54999999999998,375827.2827439511,75.22,412225.1339161738,77.78,480398.6855069459,96.46,562629.2532827273,75.09,601037.8225192195,84.55,657496.2172653131,57.629999999999995,736635.0246105919,73.83,766170.8996189197,44.61,793150.3538461538,39,865574.2750982962,53.41,910927.2,32,914482.503030303,33,936273.0720316622,37.9,953035.6,32,979431.0582914574,7.96,982927.1101402374,9.27,992067.6,1]},{"op":"quantile","d":0,"q":[0,0.001,0.01,0.1,0.25,0.5,0.75,0.9,0.95,0.99,0.999,1,-0.1,1.1,"NaN"]},{"op":"toJSON","d":0}],"expect":["ok",[-966137.8744471745,-964133.1282440444,-913972.6958517625,-759657.2196257566,-363894.01152839954,-59654.234216580124,489266.4529441478,778918.780478878,912358.5103030304,965481.362436044,988541.4891581303,992067.6,"NaN","NaN","NaN"],[33.5,-966137.8744471745,4.07,-935094.6995893224,9.74,-907316.6,32,-904835.3005681818,7.04,-892542.7178896626,37.34,-855541.4904292597,45.66,-817068.6329949239,39.4,-800603.9205882354,34,-771221.6436506051,42.13,-733419.5015521663,74.09,-688008.6765460768,81.82,-554265.7804173355,80.99,-427257.6029102167,80.75,-376078.919965177,68.92,-322229.4859058704,79.03999999999999,-267995.3917525773,97,-242750.0911764706,102,-202562.41228215763,108.45,-146282.38144329897,97,-101338.38282634511,109.46999999999998,-31314.71932212938,106.51,37936.41513469882,99.11,154308.27742420224,113.13,297063.90751864744,100.54999999999998,375827.2827439511,75.22,412225.1339161738,77.78,480398.6855069459,96.46,562629.2532827273,75.09,601037.8225192195,84.55,657496.2172653131,57.629999999999995,736635.0246105919,73.83,766170.8996189197,44.61,793150.3538461538,39,865574.2750982962,53.41,910927.2,32,914482.503030303,33,936273.0720316622,37.9,953035.6,32,979431.0582914574,7.96,982927.1101402374,9.27,992067.6,1]]} +]} diff --git a/rust/PARITY.md b/rust/PARITY.md index 5e2ec6b4ae..8c8a4a3e42 100644 --- a/rust/PARITY.md +++ b/rust/PARITY.md @@ -7,35 +7,38 @@ updated with each milestone. ## Ported -| Area | JS source | Rust | Vectors | -| -------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -| JSON parse and stringify | `JSON.parse`, `JSON.stringify`, property order | `json` | `json-parse`, `json-stringify-strings`, `sweep-json`, `harden-json`, `generated/harden-json-fuzz` | -| JS numbers | `Number#toString`, `Number(string)` | `json::number` | `number-format`, `number-parse` | -| String orders | `compareUTF8`, JS `<` | `strings` | `string-compare` | -| Hashes | `packages/shared/src/hash.ts` | `hash::xxhash32` | `hash` | -| Value comparison | `packages/zql/src/ivm/data.ts` | `compare` | `compare-values` | -| Row keys | `packages/zero-client/src/client/keys.ts` | `keys` | `primary-key-string`, `aggregate-row-key` | -| `LIKE` and `ILIKE` | `packages/zql/src/builder/like.ts` | `like` | `like` | -| TTL | `packages/zql/src/query/ttl.ts` | `ttl` | `ttl` | -| AST, normalization, wire schema | `packages/zero-protocol/src/ast.ts` | `ast` | `ast`, `ast-features`, `generated/ast-fuzz` | -| Query hashes | `packages/zero-protocol/src/query-hash-visitor.ts` | `hash::query` | `ast`, `query-internals-hash`, `name-args-hash`, `sweep-name-args-hash` | -| Query builder | `packages/zql/src/query/query-impl.ts`, `expression.ts` | `query` | `sweep-query-hash` | -| Name mapping | `packages/zero-types/src/name-mapper.ts` | `schema::NameMapper` | `ast-features` | -| Wire messages | `packages/zero-protocol/src` (`up.ts`, `down.ts`) | `protocol` | `protocol-upstream`, `protocol-downstream`, `sweep-downstream`, `protocol-client-schema`, `generated/protocol-*-fuzz`, `generated/harden-downstream-text` | -| Binary poke chunks | `decodePokeChunks` | `protocol::poke_chunk` | `protocol-poke-chunks`, `generated/protocol-poke-chunks-fuzz`, `generated/harden-poke-bytes` | -| `Sec-WebSocket-Protocol` | `encodeSecProtocols`, `decodeSecProtocols` | `protocol::sec_protocols` | `protocol-sec-protocols` | -| Connect URL | `createConnectionURL` in `zero.ts` | `protocol::ConnectionUrl` | a unit test against `URLSearchParams`; `tests/walking_skeleton.rs` | -| Client schema | `clientSchemaFrom` | `schema::Schema::client_schema` | `tests/walking_skeleton.rs` (zero-cache rejects a wrong one) | -| Protocol version | `PROTOCOL_VERSION` (57) | `protocol::PROTOCOL_VERSION` | `meta` | -| IVM operators and memory source | `packages/zql/src/ivm` | `ivm` | `ivm`, `ivm-features`, `bughunt-ivm`, `restored-ivm`, `restored-ivm-rebaselined`, `generated/ivm-fuzz`, `generated/ivm-features-fuzz`, `generated/sweep-ivm-*`, `generated/harden-ivm-*`, `generated/restored-chinook-decpush` | -| Pipeline builder | `packages/zql/src/builder/builder.ts` | `builder` | the IVM vectors above | -| Views and change application | `array-view.ts`, `view-apply-change.ts` | `ivm::ArrayView` | the IVM vectors above | -| Typed queries and codegen | `packages/zql/src/query/query.ts`, `packages/zerogen` | `typed`, `zero-rust codegen` | the query vectors through `AnyQuery`, which typed queries build (`rust/codegen-tests`) | -| Typed CRUD in mutators | `tx.mutate.` (`crud.ts`) | `typed::TypedTableMutator`, generated `mutate` | `rust/codegen-tests/tests/typed.rs`; the CRUD itself is `client::Transaction`'s, which the client vectors check | -| Client engine | `packages/zero-client/src/client` (`zero.ts`, `connection-manager.ts`, `query-manager.ts`, `zero-poke-handler.ts`, `mutation-tracker.ts`, `context.ts`, `ivm-branch.ts`, `crud-impl.ts`) | `client`, on memory storage | `client`, `client-harden-connection`, `client-harden-mutations`, `harden-queries`, `bughunt-client`, `generated/client-aggregates-fuzz` | -| Synced aggregates and groups | `packages/zql/src/builder/builder.ts`, `crud-impl.ts` | `builder`, `client::Transaction` | the client vectors above | -| WebSocket and timers | the browser `WebSocket`, `setTimeout`, microtasks | `tokio_transport` (`tokio-transport` feature) | `tests/tokio_transport.rs`; `tests/client_e2e.rs` against `zero-cache` | -| Storage and the client lifecycle | Replicache's persistence (`kv/`, `persist/`), `mem-fallback-store.ts`, zero-swift's `ReplicaDatabase` | `client::{ZeroStorage, StorageBackend}`, SQLite behind `sqlite` | every client file again as `(sqlite)`; `tests/sqlite_storage.rs`; `tests/client_e2e.rs` | +| Area | JS source | Rust | Vectors | +| -------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| JSON parse and stringify | `JSON.parse`, `JSON.stringify`, property order | `json` | `json-parse`, `json-stringify-strings`, `sweep-json`, `harden-json`, `generated/harden-json-fuzz` | +| JS numbers | `Number#toString`, `Number(string)` | `json::number` | `number-format`, `number-parse` | +| String orders | `compareUTF8`, JS `<` | `strings` | `string-compare` | +| Hashes | `packages/shared/src/hash.ts` | `hash::xxhash32` | `hash` | +| Value comparison | `packages/zql/src/ivm/data.ts` | `compare` | `compare-values` | +| Row keys | `packages/zero-client/src/client/keys.ts` | `keys` | `primary-key-string`, `aggregate-row-key` | +| `LIKE` and `ILIKE` | `packages/zql/src/builder/like.ts` | `like` | `like` | +| TTL | `packages/zql/src/query/ttl.ts` | `ttl` | `ttl` | +| AST, normalization, wire schema | `packages/zero-protocol/src/ast.ts` | `ast` | `ast`, `ast-features`, `generated/ast-fuzz` | +| Query hashes | `packages/zero-protocol/src/query-hash-visitor.ts` | `hash::query` | `ast`, `query-internals-hash`, `name-args-hash`, `sweep-name-args-hash` | +| Query builder | `packages/zql/src/query/query-impl.ts`, `expression.ts` | `query` | `sweep-query-hash` | +| Name mapping | `packages/zero-types/src/name-mapper.ts` | `schema::NameMapper` | `ast-features` | +| Wire messages | `packages/zero-protocol/src` (`up.ts`, `down.ts`) | `protocol` | `protocol-upstream`, `protocol-downstream`, `sweep-downstream`, `protocol-client-schema`, `generated/protocol-*-fuzz`, `generated/harden-downstream-text` | +| Binary poke chunks | `decodePokeChunks` | `protocol::poke_chunk` | `protocol-poke-chunks`, `generated/protocol-poke-chunks-fuzz`, `generated/harden-poke-bytes` | +| `Sec-WebSocket-Protocol` | `encodeSecProtocols`, `decodeSecProtocols` | `protocol::sec_protocols` | `protocol-sec-protocols` | +| Connect URL | `createConnectionURL` in `zero.ts` | `protocol::ConnectionUrl` | a unit test against `URLSearchParams`; `tests/walking_skeleton.rs` | +| Client schema | `clientSchemaFrom` | `schema::Schema::client_schema` | `tests/walking_skeleton.rs` (zero-cache rejects a wrong one) | +| Protocol version | `PROTOCOL_VERSION` (57) | `protocol::PROTOCOL_VERSION` | `meta` | +| IVM operators and memory source | `packages/zql/src/ivm` | `ivm` | `ivm`, `ivm-features`, `bughunt-ivm`, `restored-ivm`, `restored-ivm-rebaselined`, `generated/ivm-fuzz`, `generated/ivm-features-fuzz`, `generated/sweep-ivm-*`, `generated/harden-ivm-*`, `generated/restored-chinook-decpush` | +| Pipeline builder | `packages/zql/src/builder/builder.ts` | `builder` | the IVM vectors above | +| Views and change application | `array-view.ts`, `view-apply-change.ts` | `ivm::ArrayView` | the IVM vectors above | +| Typed queries and codegen | `packages/zql/src/query/query.ts`, `packages/zerogen` | `typed`, `zero-rust codegen` | the query vectors through `AnyQuery`, which typed queries build (`rust/codegen-tests`) | +| Typed CRUD in mutators | `tx.mutate.
` (`crud.ts`) | `typed::TypedTableMutator`, generated `mutate` | `rust/codegen-tests/tests/typed.rs`; the CRUD itself is `client::Transaction`'s, which the client vectors check | +| Client engine | `packages/zero-client/src/client` (`zero.ts`, `connection-manager.ts`, `query-manager.ts`, `zero-poke-handler.ts`, `mutation-tracker.ts`, `context.ts`, `ivm-branch.ts`, `crud-impl.ts`) | `client`, on memory storage | `client`, `client-harden-connection`, `client-harden-mutations`, `harden-queries`, `bughunt-client`, `generated/client-aggregates-fuzz` | +| Synced aggregates and groups | `packages/zql/src/builder/builder.ts`, `crud-impl.ts` | `builder`, `client::Transaction` | the client vectors above | +| WebSocket and timers | the browser `WebSocket`, `setTimeout`, microtasks | `tokio_transport` (`tokio-transport` feature) | `tests/tokio_transport.rs`; `tests/client_e2e.rs` against `zero-cache` | +| Storage and the client lifecycle | Replicache's persistence (`kv/`, `persist/`), `mem-fallback-store.ts`, zero-swift's `ReplicaDatabase` | `client::{ZeroStorage, StorageBackend}`, SQLite behind `sqlite` | every client file again as `(sqlite)`; `tests/sqlite_storage.rs`; `tests/client_e2e.rs` | +| Inspector and query metrics | `packages/zero-client/src/client/inspector`, `metrics.ts`, `query-manager.ts`, `packages/zero-protocol/src/inspect-up.ts`, `inspect-down.ts`, `packages/zql/src/planner/planner-debug.ts` | `client::Inspector`, `client::Metrics` | `client-inspector`, also as `(sqlite)`; `tests/inspector.rs` | +| TDigest | `packages/shared/src/tdigest.ts` | `tdigest` | `tdigest` | +| AST to ZQL | `packages/zero/src/ast-to-zql.ts` | `ast::ast_to_zql` | `ast-to-zql` | ## Not ported yet @@ -72,7 +75,8 @@ factory. | `onOnlineChange` (deprecated) | `connection().subscribe(listener)` | | `server`, `getQueriesURL` (deprecated) | `cache_url`, `query_url` | | `batchViewUpdates` | `batch_view_updates` | -| `slowMaterializeThreshold`, `maxRecentQueries` (deprecated) | not ported | +| `slowMaterializeThreshold` | `slow_materialize_threshold_ms` (5,000, as in JS) | +| `maxRecentQueries` (deprecated) | not ported: JS keeps no recent queries by default either | Two defaults differ from JS. `storage` is `ZeroStorage::Memory`, since SQLite is an opt-in feature, where JS keeps its data in IndexedDB. @@ -83,20 +87,21 @@ whose window can stay hidden for long can set JS's 300,000. ### The client -| JS | Rust | -| ---------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- | -| `new Zero(options)` | `Zero::new(schema, context, mutators, options, scheduler, socket_factory)?` | -| `zero.clientID`, `await zero.clientGroupID` | `client_id()`, `client_group_id()`, known at once | -| `zero.userID`, `zero.schema`, `zero.context`, `zero.closed` | `user_id()`, `schema()`, `context()`, `closed()` | -| `zero.materialize(query)` | `materialize(&query, &ttl)?`, a `MaterializedView` with `data`, `add_listener`, `destroy`, `update_ttl` | -| `zero.run(query, {type})` | `run(&query, RunType, ttl)`, a `Deferred` to await or read once settled | -| `zero.preload(query)` | `preload(&query, &Ttl::DEFAULT_PRELOAD)`, a `Preload` with `cleanup`, `cached`, and `complete` | -| `zero.mutate(request)` | `mutate(name, args)`, a `MutatorResult` whose `client` and `server` are `Deferred` | -| `zero.connection.state`, `.subscribe`, `.connect({auth})` | `connection().state()`, `.subscribe(listener)`, `.connect(auth)` | -| `zero.close()`, `zero.delete()`, `dropAllDatabases()` | `close()`, `delete()`, `client::drop_all_databases(&storage)`, which return the `DroppedDatabases` | -| `escapeLike(text)` | `like::escape_like` | -| `zero.mutate.issue.insert(...)` (CRUD mutators) | not ported: write a mutator | -| `zero.mutateBatch`, `zero.inspector`, `zero.online`, `zero.server`, `zero.version` | not ported; `protocol::PROTOCOL_VERSION` is the sync protocol's version | +| JS | Rust | +| ---------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- | +| `new Zero(options)` | `Zero::new(schema, context, mutators, options, scheduler, socket_factory)?` | +| `zero.clientID`, `await zero.clientGroupID` | `client_id()`, `client_group_id()`, known at once | +| `zero.userID`, `zero.schema`, `zero.context`, `zero.closed` | `user_id()`, `schema()`, `context()`, `closed()` | +| `zero.materialize(query)` | `materialize(&query, &ttl)?`, a `MaterializedView` with `data`, `add_listener`, `destroy`, `update_ttl` | +| `zero.run(query, {type})` | `run(&query, RunType, ttl)`, a `Deferred` to await or read once settled | +| `zero.preload(query)` | `preload(&query, &Ttl::DEFAULT_PRELOAD)`, a `Preload` with `cleanup`, `cached`, and `complete` | +| `zero.mutate(request)` | `mutate(name, args)`, a `MutatorResult` whose `client` and `server` are `Deferred` | +| `zero.connection.state`, `.subscribe`, `.connect({auth})` | `connection().state()`, `.subscribe(listener)`, `.connect(auth)` | +| `zero.close()`, `zero.delete()`, `dropAllDatabases()` | `close()`, `delete()`, `client::drop_all_databases(&storage)`, which return the `DroppedDatabases` | +| `escapeLike(text)` | `like::escape_like` | +| `zero.mutate.issue.insert(...)` (CRUD mutators) | not ported: write a mutator | +| `zero.inspector` | `inspector()`, an `Inspector`; see below | +| `zero.mutateBatch`, `zero.online`, `zero.server`, `zero.version` | not ported; `protocol::PROTOCOL_VERSION` is the sync protocol's version | Rust adds `reconnect_now` (the network may be back, so skip the backoff), `when_pending_settled`, and `flush_storage` (wait for the store's queued @@ -107,6 +112,37 @@ reload. Without `on_client_state_not_found`, Rust replaces the client inside the same `Zero`, as Swift does: a new client ID and client group on the same store, with the views and preloads moved to the new client. +### The inspector + +| JS | Rust | +| --------------------------------------------------------------------- | ------------------------------------------------------------------------------------- | +| `inspector.client`, `.clientGroup` | `client()`, `client_group()`, an `InspectorClient` and an `InspectorClientGroup` | +| `await inspector.metrics()`, `.serverVersion()` | `metrics()`, `server_version()`, a `Deferred` and a `Deferred` | +| `await inspector.clients()`, `.clientsWithQueries()` | `clients()`, `clients_with_queries()`, a `Deferred>` | +| `await client.queries()`, `.map()`, `.rows(table)` | `queries()`, `map()`, `rows(table)`; a query is an `InspectorQuery`, with JS's fields | +| `await inspector.analyzeQuery(query, options)` | `analyze_query(&query, AnalyzeQueryOptions)`, a `Deferred` | +| `inspector.analyzeQuery` with a server AST, or a name and arguments | `analyze_server_ast(&ast, options)`, `analyze_named_query(name, args, options)` | +| the password prompt | `authenticate(password)`, a `Deferred` | +| `formatPlannerEvents(events)` | `format_planner_events(&events)` | +| the `TDigest` of `query-materialization-client` and the other metrics | `tdigest::TDigest`, which reads and writes JS's JSON form | + +`Inspector` takes the context's type (`Inspector`, `()` by default), +since `analyze_query` builds a query with it. The client records JS's +metrics, `query-update-client` sampled as JS samples it, and logs a query's +end-to-end materialization as JS does, as one line: the message, the query +ID, its AST as JSON, and the milliseconds, a warning past +`slow_materialize_threshold_ms`. At the debug level it asks zero-cache for +its timings (`debugPerf`), as JS does. + +zero-cache can require its admin password. Where JS prompts for it, an RPC +the server refuses fails with an error that starts with "Authentication +failed" and says to call `authenticate(password)`. A password the server +accepted is presented again before the next RPC on a new connection, as JS +presents its `adminPassword`, and forgotten when the server refuses it. An +RPC waits for the connection, and fails with an error when the connection +drops before the answer or the client closes, where JS's would wait for an +answer that never comes. + ### Queries Generated code (`zero-rust codegen`) has a row struct per table with @@ -189,6 +225,11 @@ GPUI app on the same model. listener calls, mutation and `run` settlements, connection states) and every message the server received, as Swift's `ClientConformanceTests` does. +- `client-inspector` stubs JS's password prompt to answer nothing, so an + RPC the server refuses fails with "Authentication failed"; the Rust + error goes on to say to call `authenticate(password)`, and the runner + compares its part before the colon. A query's milliseconds come from the + manual clock, so its metrics and log lines are compared exactly. - The IVM vectors (`ivm/harness.ts`) are programs of query builder calls. Rust replays each with its own builder, must build JS's AST and format or diff --git a/rust/conformance/src/suites/ast.rs b/rust/conformance/src/suites/ast.rs index c97b42a4ca..56fffb850d 100644 --- a/rust/conformance/src/suites/ast.rs +++ b/rust/conformance/src/suites/ast.rs @@ -1,7 +1,8 @@ //! The AST, its normalization, and query hashes: `primitives/ast.test.ts`, //! `primitives/ast-features.test.ts`, `primitives/hash.test.ts` (the query //! hashes), and `primitives/sweep-wire.test.ts` (the name-and-args hashes -//! and the hashes of queries the query builder builds). +//! and the hashes of queries the query builder builds), and +//! `primitives/ast-to-zql.test.ts`. use crate::case::{Case, ensure, quote, same}; use crate::{Outcome, Source, Suite}; @@ -17,6 +18,12 @@ use zero_client::schema::{NameMapper, Schema}; pub fn suites() -> Vec { vec![ + Suite { + variant: None, + file: "ast-to-zql", + source: Source::Checked, + check: ast_to_zql, + }, Suite { variant: None, file: "ast", @@ -313,3 +320,19 @@ fn expression(eb: &ExpressionBuilder, e: &Value, error: &OpError) -> Condition { Condition::And(Vec::new()) }) } + +fn ast_to_zql(c: &Value, _: &Value) -> Result { + let ast = Ast::from_json(c.field("ast")?).map_err(|e| e.to_string())?; + let what = json::stringify(c.field("ast")?); + same( + format!("astToZQL({what})"), + zero_client::ast::ast_to_zql(&ast, false).as_str(), + c.str("zql")?, + )?; + same( + format!("astToZQL({what}, redactLiterals)"), + zero_client::ast::ast_to_zql(&ast, true).as_str(), + c.str("redacted")?, + )?; + Ok(Outcome::Pass) +} diff --git a/rust/conformance/src/suites/client.rs b/rust/conformance/src/suites/client.rs index 1fe4177384..4575b6c671 100644 --- a/rust/conformance/src/suites/client.rs +++ b/rust/conformance/src/suites/client.rs @@ -1,5 +1,5 @@ //! Client scenarios: `client/client.test.ts`, `client/harden-*.test.ts`, -//! `harden-queries`, and `client/bughunt.test.ts` with its seeded +//! `harden-queries`, `client/inspector.test.ts`, and `client/bughunt.test.ts` with its seeded //! aggregate scenarios (`generated/client-aggregates-fuzz`). //! //! Each case is a scenario of steps an app and a server take @@ -17,9 +17,11 @@ use std::cell::{Cell, RefCell}; use std::collections::HashMap; use std::rc::{Rc, Weak}; use std::sync::Arc; +use zero_client::ast::Ast; use zero_client::ast::{Direction, JsonPathSegment, SimpleOperator, System}; use zero_client::client::{ - ApplicationError, Error, MaterializedView, Mutator, RunType, SocketMessage, Transaction, Zero, + AnalyzeQueryOptions, ApplicationError, Deferred, Error, InspectorClient, InspectorQuery, + LogLevel, MaterializedView, Mutator, PlanDebugEvent, RunType, SocketMessage, Transaction, Zero, ZeroOptions, ZeroStorage, }; use zero_client::decode::JsonCodable; @@ -37,6 +39,7 @@ pub fn suites() -> Vec { "client-harden-mutations", "harden-queries", "bughunt-client", + "client-inspector", ] .into_iter() .map(|file| Suite { @@ -556,6 +559,97 @@ struct Runner { /// The scenario's own storage, as `#scenario-` in `harness.ts`. scenario_key: u64, restarts: Cell, + /// The current client's log, and how much of it was reported. + log: RefCell>, + logs_seen: Cell, + /// The `inspect` calls, and how many inspector requests were sent. + inspect_calls: RefCell>, + inspect_count: Cell, +} + +/// The messages of `addMetric`'s materialization logs. +const MATERIALIZATION_LOGS: [&str; 2] = [ + "Slow query materialization (including server/network)", + "Materialized query (including server/network)", +]; + +/// A materialization log line, ` `, as +/// the arguments JS logs. +fn materialization_log(level: LogLevel, line: &str) -> Option { + let message = MATERIALIZATION_LOGS + .into_iter() + .find(|m| line.starts_with(&format!("{m} ")))?; + let rest = &line[message.len() + 1..]; + let (id, rest) = rest.split_once(' ')?; + let (ast, ms) = rest.rsplit_once(' ')?; + let mut o = Object::new(); + o.insert("level", s(level.as_str())); + o.insert( + "args", + Value::Array(vec![ + s(message), + s(id), + json::parse(ast).ok()?, + json::parse(ms).ok()?, + ]), + ); + Some(Value::Object(o)) +} + +/// What JS's `errorMessage` gives for an inspector error. Where zero-cache +/// refuses an unauthenticated request JS prompts for the password, and its +/// error without one is `Authentication failed`; the Rust error goes on to +/// say to call `authenticate(password)` (rust/PARITY.md). +fn inspect_error(e: &Error) -> String { + let m = e.message(); + match m.strip_prefix("Authentication failed:") { + Some(_) => "Authentication failed".into(), + None => m, + } +} + +fn opt_num(n: Option) -> Value { + n.map_or(Value::Null, Value::Number) +} + +/// A query's fields as `queriesJSON` in `harness.ts` gives them. +fn query_json(q: &InspectorQuery) -> Value { + let mut o = Object::new(); + o.insert("name", q.name.clone().map_or(Value::Null, Value::String)); + o.insert("args", q.args.clone().map_or(Value::Null, Value::Array)); + o.insert("got", Value::Bool(q.got)); + o.insert("ttl", q.ttl.to_json()); + o.insert("inactivatedAt", opt_num(q.inactivated_at)); + o.insert("rowCount", Value::Number(q.row_count)); + o.insert("deleted", Value::Bool(q.deleted)); + o.insert("id", s(&q.id)); + o.insert("clientID", s(&q.client_id)); + o.insert("metrics", q.metrics.to_json()); + o.insert( + "clientZQL", + q.client_zql.clone().map_or(Value::Null, Value::String), + ); + o.insert( + "serverZQL", + q.server_zql.clone().map_or(Value::Null, Value::String), + ); + o.insert("hydrateClient", opt_num(q.hydrate_client)); + o.insert("hydrateServer", opt_num(q.hydrate_server)); + o.insert("hydrateTotal", opt_num(q.hydrate_total)); + o.insert("updateClientP50", opt_num(q.update_client_p50)); + o.insert("updateClientP95", opt_num(q.update_client_p95)); + o.insert("updateServerP50", opt_num(q.update_server_p50)); + o.insert("updateServerP95", opt_num(q.update_server_p95)); + Value::Object(o) +} + +fn analyze_options(v: Option<&Value>) -> AnalyzeQueryOptions { + let flag = |k: &str| v.and_then(|o| o.get(k)).and_then(Value::as_bool); + AnalyzeQueryOptions { + vended_rows: flag("vendedRows"), + synced_rows: flag("syncedRows"), + join_plans: flag("joinPlans"), + } } thread_local! { @@ -613,7 +707,7 @@ impl Runner { let factory = MockSocketFactory::new(); let events: Rc>> = Rc::default(); let options = scenario.get("options").cloned().unwrap_or_default(); - let zero = Self::make_zero( + let (zero, log) = Self::make_zero( &schema, &options, None, @@ -645,6 +739,10 @@ impl Runner { listeners: RefCell::default(), scenario_key, restarts: Cell::new(0), + log: RefCell::new(log), + logs_seen: Cell::new(0), + inspect_calls: RefCell::default(), + inspect_count: Cell::new(0), })) } @@ -656,10 +754,11 @@ impl Runner { factory: &Rc, events: &Rc>>, scenario_key: u64, - ) -> Result { + ) -> Result<(Zero, Rc), String> { let get = |k: &str| o.get(k); + let log = Rc::new(RecordingLogSink::default()); let mut options = ZeroOptions { - log_sink: Some(Rc::new(RecordingLogSink::default())), + log_sink: Some(log.clone()), storage: STORAGE.with(|s| s.borrow().clone()), ..ZeroOptions::default() }; @@ -686,6 +785,17 @@ impl Runner { if let Some(v) = get("maxHeaderLength").and_then(Value::as_f64) { options.max_header_length = v as usize; } + if let Some(v) = get("slowMaterializeThreshold").and_then(Value::as_f64) { + options.slow_materialize_threshold_ms = v; + } + if let Some(l) = get("logLevel").and_then(Value::as_str) { + options.log_level = match l { + "debug" => LogLevel::Debug, + "info" => LogLevel::Info, + "error" => LogLevel::Error, + _ => LogLevel::Warn, + }; + } options.hidden_disconnect_delay_ms = get("hiddenTabDisconnectDelay") .and_then(Value::as_f64) .unwrap_or(300_000.0); @@ -740,6 +850,7 @@ impl Runner { scheduler.clone(), Some(factory.clone()), ) + .map(|z| (z, log)) .map_err(|e| e.to_string()) } @@ -763,7 +874,7 @@ impl Runner { .or_else(|| self.scenario.get("options")) .cloned() .unwrap_or_default(); - let new = Self::make_zero( + let (new, log) = Self::make_zero( &self.schema, &options, step.get("mutators"), @@ -785,6 +896,9 @@ impl Runner { ids.insert("$clientID".into(), new.client_id()); } *self.zero.borrow_mut() = Rc::new(new); + *self.log.borrow_mut() = log; + self.logs_seen.set(0); + self.inspect_calls.borrow_mut().clear(); self.views.borrow_mut().clear(); self.listeners.borrow_mut().clear(); self.retired.borrow_mut().clear(); @@ -1068,6 +1182,7 @@ impl Runner { .connect(step.get("auth").and_then(Value::as_str).map(str::to_owned)), "close" => self.zero().close(), "restart" => self.restart(step)?, + "inspect" => self.inspect(step)?, "listen" => { let name = string("view")?; let view = self @@ -1135,6 +1250,135 @@ impl Runner { Ok(()) } + /// An `inspect` step: calls the inspector and records how its result + /// settles (`inspect` in `harness.ts`). + fn inspect(&self, step: &Value) -> Result<(), String> { + let call = step.str("call")?.to_owned(); + let entry = pending(); + { + let mut calls = self.inspect_calls.borrow_mut(); + calls.retain(|(n, _)| *n != call); + calls.push((call, entry.clone())); + } + fn record( + entry: Settled, + d: Deferred, + convert: impl Fn(&T) -> Value + 'static, + ) { + d.on_settle(move |r| { + let mut o = Object::new(); + match r { + Ok(v) => o.insert("resolved", convert(v)), + Err(e) => o.insert("rejected", Value::String(inspect_error(e))), + }; + *entry.borrow_mut() = Value::Object(o); + }); + } + let placeholders = self.placeholders.borrow().clone(); + let clients = move |clients: &Vec| { + let mut out: Vec<(String, Value)> = clients + .iter() + .map(|c| { + let id = placeholders + .get(c.id()) + .cloned() + .unwrap_or_else(|| c.id().to_owned()); + let mut o = Object::new(); + o.insert("id", Value::String(id.clone())); + o.insert("clientGroupID", s(c.client_group().id())); + (id, Value::Object(o)) + }) + .collect(); + out.sort_by(|a, b| a.0.cmp(&b.0)); + Value::Array(out.into_iter().map(|(_, v)| v).collect()) + }; + let queries = |q: &Vec| Value::Array(q.iter().map(query_json).collect()); + let zero = self.zero(); + let inspector = zero.inspector(); + let options = analyze_options(step.get("options")); + match step.str("method")? { + "metrics" => record(entry, inspector.metrics(), |m| m.to_json()), + "serverVersion" => record(entry, inspector.server_version(), |v| s(v)), + "clients" => record(entry, inspector.clients(), clients), + "clientsWithQueries" => record(entry, inspector.clients_with_queries(), clients), + "clientQueries" => record(entry, inspector.client().queries(), queries), + "clientMap" => { + let placeholders = self.placeholders.borrow().clone(); + record(entry, inspector.client().map(), move |m| { + Value::Array( + m.iter() + .map(|(k, v)| { + let mut k = k.clone(); + for (id, placeholder) in &placeholders { + k = k.replace(id.as_str(), placeholder); + } + Value::Array(vec![Value::String(k), v.clone()]) + }) + .collect(), + ) + }) + } + "clientRows" => { + let table = step.get("table").and_then(Value::as_str).unwrap_or(""); + record(entry, inspector.client().rows(table), |rows| { + Value::Array(rows.iter().cloned().map(Value::Object).collect()) + }) + } + "clientGroupClients" => record(entry, inspector.client_group().clients(), clients), + "clientGroupClientsWithQueries" => record( + entry, + inspector.client_group().clients_with_queries(), + clients, + ), + "clientGroupQueries" => record(entry, inspector.client_group().queries(), queries), + "analyzeQuery" => { + let q = request( + step.get("query").and_then(Value::as_str).unwrap_or(""), + step.get("args"), + )?; + record(entry, inspector.analyze_query(&q, options), |r| r.to_json()) + } + "analyzeServerAST" => { + let ast = Ast::from_json(step.field("ast")?).map_err(|e| e.to_string())?; + record(entry, inspector.analyze_server_ast(&ast, options), |r| { + r.to_json() + }) + } + "analyzeNamedQuery" => { + let name = step.get("name").and_then(Value::as_str).unwrap_or(""); + let args = step + .get("queryArgs") + .and_then(Value::as_array) + .cloned() + .unwrap_or_default(); + record( + entry, + inspector.analyze_named_query(name, args, options), + |r| r.to_json(), + ) + } + "authenticate" => { + let password = step.get("password").and_then(Value::as_str).unwrap_or(""); + record(entry, inspector.authenticate(password), |b| Value::Bool(*b)) + } + "formatPlannerEvents" => { + let events: Vec = step + .get("events") + .and_then(Value::as_array) + .map(|a| a.iter().cloned().map(PlanDebugEvent).collect()) + .unwrap_or_default(); + let mut o = Object::new(); + o.insert( + "resolved", + Value::String(inspector.format_planner_events(&events)), + ); + *entry.borrow_mut() = Value::Object(o); + } + m => return Err(format!("Unknown inspector method {m}")), + } + Ok(()) + } + /// Settles the work due now (`settle` in `harness.ts`). fn settle(&self) { self.zero().dispatch(|| {}); @@ -1182,6 +1426,18 @@ impl Runner { let from = sent_counts.get(i).copied().unwrap_or(0); for m in &s.messages()[from..] { let v = json::parse(m).unwrap_or_else(|_| Value::String(m.clone())); + if v.at(0).and_then(Value::as_str) == Some("inspect") + && let Some(id) = v.at(1).and_then(|b| b.get("id")).and_then(Value::as_str) + && !self.placeholders.borrow().contains_key(id) + { + let n = self.inspect_count.get(); + self.inspect_count.set(n + 1); + let placeholder = format!("$inspect.{n}"); + self.placeholders + .borrow_mut() + .insert(id.to_owned(), placeholder.clone()); + self.ids.borrow_mut().insert(placeholder, id.to_owned()); + } sent.push(self.normalize(&v, None)); } } @@ -1247,6 +1503,25 @@ impl Runner { if !events.is_empty() { result.insert("events", Value::Array(events)); } + if !self.inspect_calls.borrow().is_empty() { + let mut o = Object::new(); + for (name, v) in self.inspect_calls.borrow().iter() { + o.insert(name.clone(), v.borrow().clone()); + } + result.insert("inspector", self.normalize(&Value::Object(o), None)); + } + let logs: Vec = { + let entries = self.log.borrow().entries(); + let seen = self.logs_seen.replace(entries.len()); + entries[seen..] + .iter() + .filter_map(|(level, line)| materialization_log(*level, line)) + .map(|l| self.normalize(&l, None)) + .collect() + }; + if !logs.is_empty() { + result.insert("logs", Value::Array(logs)); + } if !self.listeners.borrow().is_empty() { let mut o = Object::new(); for (name, l) in self.listeners.borrow().iter() { diff --git a/rust/conformance/src/suites/primitives.rs b/rust/conformance/src/suites/primitives.rs index eece4e8d2a..4dea2ecdc1 100644 --- a/rust/conformance/src/suites/primitives.rs +++ b/rust/conformance/src/suites/primitives.rs @@ -1,5 +1,5 @@ -//! String orders and hashes: `primitives/compare.test.ts` and -//! `primitives/hash.test.ts`. +//! String orders, hashes, and the t-digest: `primitives/compare.test.ts`, +//! `primitives/hash.test.ts`, and `primitives/tdigest.test.ts`. use crate::case::{Case, quote, same}; use crate::{Outcome, Source, Suite}; @@ -7,6 +7,7 @@ use std::cmp::Ordering; use zero_client::hash::xxhash32; use zero_client::json::Value; use zero_client::strings; +use zero_client::tdigest::TDigest; pub fn suites() -> Vec { vec![ @@ -22,6 +23,12 @@ pub fn suites() -> Vec { source: Source::Checked, check: hash, }, + Suite { + variant: None, + file: "tdigest", + source: Source::Checked, + check: tdigest, + }, ] } @@ -69,3 +76,104 @@ fn hash(c: &Value, _: &Value) -> Result { )?; Ok(Outcome::Pass) } + +/// A vector number: NaN and the infinities are strings. +fn num(v: &Value) -> Result { + match v { + Value::Number(n) => Ok(*n), + Value::String(s) if s == "NaN" => Ok(f64::NAN), + Value::String(s) if s == "Infinity" => Ok(f64::INFINITY), + Value::String(s) if s == "-Infinity" => Ok(f64::NEG_INFINITY), + _ => Err(format!("not a vector number: {v}")), + } +} + +fn enc(n: f64) -> Value { + if n.is_nan() { + Value::from("NaN") + } else if n.is_infinite() { + Value::from(if n > 0.0 { "Infinity" } else { "-Infinity" }) + } else { + Value::Number(n) + } +} + +/// Numbers compare by bits but for the sign of zero, which JSON drops. +fn same_numbers(got: &Value, want: &Value) -> bool { + match (got, want) { + (Value::Number(a), Value::Number(b)) => a == b, + (Value::Array(a), Value::Array(b)) => { + a.len() == b.len() && a.iter().zip(b).all(|(a, b)| same_numbers(a, b)) + } + (a, b) => a == b, + } +} + +fn tdigest(c: &Value, _: &Value) -> Result { + let mut digests: Vec = c + .arr("compressions")? + .iter() + .map(|n| TDigest::new(n.as_f64().unwrap_or(100.0))) + .collect(); + let expect = c.arr("expect")?; + for (i, op) in c.arr("ops")?.iter().enumerate() { + let d = op.num("d")? as usize; + let got = match op.str("op")? { + "add" => { + for pair in op.arr("values")? { + let pair = pair.as_array().ok_or("a value pair")?; + digests[d].add(num(&pair[0])?, num(&pair[1])?); + } + Value::Null + } + "merge" => { + let from = op.num("from")? as usize; + // JS merges a digest into itself by processing it, then + // adding its centroids: reading its count processes it. + digests[from].count(); + let from = digests[from].clone(); + digests[d].merge(&from); + Value::Null + } + "quantile" => Value::Array( + op.arr("q")? + .iter() + .map(|q| num(q).map(|q| enc(digests[d].quantile(q)))) + .collect::>()?, + ), + "cdf" => Value::Array( + op.arr("x")? + .iter() + .map(|x| num(x).map(|x| enc(digests[d].cdf(x)))) + .collect::>()?, + ), + "count" => enc(digests[d].count()), + "toJSON" => Value::Array(digests[d].to_vec().into_iter().map(enc).collect()), + "fromJSON" => match TDigest::from_json_value(op.field("json")?) { + Ok(t) => { + digests[d] = t; + Value::from("ok") + } + Err(e) => { + let mut o = zero_client::json::Object::new(); + o.insert("threw", Value::String(e)); + Value::Object(o) + } + }, + "reset" => { + digests[d].reset(); + Value::Null + } + other => return Err(format!("unknown op {other}")), + }; + let want = expect.get(i).unwrap_or(&Value::Null); + if !same_numbers(&got, want) { + return Err(format!( + "{} op {i} ({}): Rust {got}, JS {want}", + c.str("name")?, + op.str("op")? + )); + } + } + Ok(Outcome::Pass) +} diff --git a/rust/zero-client/src/ast/mod.rs b/rust/zero-client/src/ast/mod.rs index 7c5337e800..f3f7912e03 100644 --- a/rust/zero-client/src/ast/mod.rs +++ b/rust/zero-client/src/ast/mod.rs @@ -3,10 +3,12 @@ mod coding; mod normalize; pub mod strict; +mod zql; pub(crate) use coding::is_homogeneous; pub(crate) use normalize::cmp_related; pub use normalize::normalize_condition; +pub use zql::ast_to_zql; use crate::json::{Object, Value}; diff --git a/rust/zero-client/src/ast/zql.rs b/rust/zero-client/src/ast/zql.rs new file mode 100644 index 0000000000..73a96cad15 --- /dev/null +++ b/rust/zero-client/src/ast/zql.rs @@ -0,0 +1,310 @@ +//! An AST as the query builder code that makes it (`astToZQL` in +//! `packages/ast-to-zql/src/ast-to-zql.ts`), for the inspector. + +use super::*; +use crate::json::{self, number}; +use crate::query::SUBQUERY_ALIAS_PREFIX; + +/// The builder calls after the table that make `ast`, such as +/// `.where('id', '=', 123)`: `astToZQL`. The inspector prefixes the table +/// name. With `redact_literals`, every literal and the `start` row read +/// `?`, so the code can be logged without row data or arguments. +pub fn ast_to_zql(ast: &Ast, redact_literals: bool) -> String { + let mut code = String::new(); + if let Some(w) = &ast.where_ { + code += &condition(w, Prefix::Where, &mut Vec::new(), redact_literals); + } + if let Some(related) = &ast.related { + for r in related { + if r.hidden == Some(true) { + if let Some(nested) = r.subquery.related.as_ref().and_then(|n| n.first()) { + code += &transform_related(nested, redact_literals); + } + } else { + code += &transform_related(r, redact_literals); + } + } + } + let distinct = ast.aggregate.as_ref().and_then(|a| a.distinct.as_ref()); + if let Some(group_by) = &ast.group_by { + let cols = string_list(group_by); + code += &match &ast.aggregate { + Some(a) => format!(".groupBy({cols}).{}({})", a.fn_.as_str(), aggregate_arg(a)), + None => format!(".distinct({cols})"), + }; + } else if let Some(d) = distinct { + code += &format!(".distinct({})", string_list(d)); + } + if let Some(order_by) = ast.order_by.as_ref().filter(|o| !o.is_empty()) { + code += &ordering(order_by); + } + if let Some(limit) = ast.limit { + code += &format!(".limit({})", number::format(limit)); + } + if let Some(start) = &ast.start { + let row = if redact_literals { + "?".to_owned() + } else { + json::stringify(&Value::Object(start.row.clone())) + }; + let inclusive = if start.exclusive { + "" + } else { + ", { inclusive: true }" + }; + code += &format!(".start({row}{inclusive})"); + } + if distinct.is_some() { + code += ".count()"; + } + code +} + +#[derive(Clone, Copy, PartialEq)] +enum Prefix { + Where, + Cmp, +} + +impl Prefix { + fn as_str(self) -> &'static str { + match self { + Prefix::Where => ".where", + Prefix::Cmp => "cmp", + } + } +} + +/// The names a builder callback destructures, in the order first needed +/// (a JS `Set`). +type Args = Vec<&'static str>; + +fn add(args: &mut Args, name: &'static str) { + if !args.contains(&name) { + args.push(name); + } +} + +/// `code` at `prefix`: a callback of its own at the top level, or the +/// enclosing callback's args extended inside one. +fn wrap(prefix: Prefix, args: &mut Args, needed: &[&'static str], code: String) -> String { + if prefix == Prefix::Where { + let mut sorted = needed.to_vec(); + sorted.sort_unstable(); + return format!(".where(({{{}}}) => {code})", sorted.join(", ")); + } + for name in needed { + add(args, name); + } + code +} + +fn condition(c: &Condition, prefix: Prefix, args: &mut Args, redact: bool) -> String { + match c { + Condition::Simple { op, left, right } => { + let l = value_position(left, redact); + let r = value_position(right, redact); + let code = if *op == SimpleOperator::Eq { + format!("{l}, {r}") + } else { + format!("{l}, '{}', {r}", op.as_str()) + }; + if matches!(left, ValuePosition::Json { .. }) { + return wrap(prefix, args, &["cmp", "json"], format!("cmp({code})")); + } + format!("{}({code})", prefix.as_str()) + } + Condition::And(cs) | Condition::Or(cs) => { + let is_and = matches!(c, Condition::And(_)); + if cs.len() == 1 { + return condition(&cs[0], prefix, args, redact); + } + if is_and { + let parts: Vec = cs + .iter() + .map(|c| condition(c, prefix, args, redact)) + .collect(); + if prefix == Prefix::Where { + return parts.concat(); + } + add(args, "and"); + return format!("and({})", parts.join(", ")); + } + let mut own = Args::new(); + let inner = if prefix == Prefix::Where { + &mut own + } else { + &mut *args + }; + let code: Vec = cs + .iter() + .map(|c| condition(c, Prefix::Cmp, inner, redact)) + .collect(); + let mut needed = inner.clone(); + add(&mut needed, "cmp"); + add(&mut needed, "or"); + wrap(prefix, args, &needed, format!("or({})", code.join(", "))) + } + Condition::CorrelatedSubquery { + related, + op, + flip, + scalar, + } => exists(related, *op, *flip, *scalar, prefix, args, redact), + } +} + +/// Whether a subquery has more than its table (JS's truthiness: an empty +/// `orderBy` counts, a `limit` of 0 doesn't). +fn has_props(ast: &Ast) -> bool { + ast.where_.is_some() + || ast.related.as_ref().is_some_and(|r| !r.is_empty()) + || ast.order_by.is_some() + || ast.limit.is_some_and(|l| l != 0.0 && !l.is_nan()) +} + +fn exists( + related: &CorrelatedSubquery, + op: CorrelatedSubqueryOperator, + flip: Option, + scalar: Option, + prefix: Prefix, + args: &mut Args, + redact: bool, +) -> String { + let alias = related.subquery.alias.as_deref().unwrap_or_default(); + let relationship = alias.strip_prefix(SUBQUERY_ALIAS_PREFIX).unwrap_or(alias); + let next = next_exists_subquery(related); + let props = has_props(next); + let mut parts = Vec::new(); + if let Some(f) = flip { + parts.push(format!("flip: {f}")); + } + if let Some(s) = scalar { + parts.push(format!("scalar: {s}")); + } + let options = if parts.is_empty() { + String::new() + } else { + format!(", {{{}}}", parts.join(", ")) + }; + if op == CorrelatedSubqueryOperator::Exists { + let sub = if props { + format!(", q => q{}", ast_to_zql(next, redact)) + } else { + String::new() + }; + if prefix == Prefix::Where { + return format!(".whereExists('{relationship}'{sub}{options})"); + } + add(args, "exists"); + return format!("exists('{relationship}'{sub}{options})"); + } + let sub = if props { + format!(", q => q{}", ast_to_zql(next, redact)) + } else { + String::new() + }; + wrap( + prefix, + args, + &["exists", "not"], + format!("not(exists('{relationship}'{sub}{options}))"), + ) +} + +/// Past the hidden hop of a junction relationship, whose two hops are both +/// EXISTS conditions. +fn next_exists_subquery(related: &CorrelatedSubquery) -> &Ast { + if let Some(Condition::CorrelatedSubquery { related: inner, .. }) = &related.subquery.where_ + && inner + .subquery + .alias + .as_deref() + .is_some_and(|a| a.contains(&format!("{SUBQUERY_ALIAS_PREFIX}zhidden_"))) + { + return next_exists_subquery(inner); + } + &related.subquery +} + +fn transform_related(related: &CorrelatedSubquery, redact: bool) -> String { + let Some(alias) = &related.subquery.alias else { + return String::new(); + }; + let mut code = format!(".related('{alias}'"); + if has_props(&related.subquery) { + code += ", q => q"; + code += &ast_to_zql(&related.subquery, redact); + } + code.push(')'); + code +} + +fn ordering(order_by: &[OrderPart]) -> String { + order_by + .iter() + .map(|o| format!(".orderBy('{}', '{}')", o.field, o.direction.as_str())) + .collect() +} + +fn value_position(v: &ValuePosition, redact: bool) -> String { + match v { + ValuePosition::Literal(_) if redact => "?".into(), + ValuePosition::Literal(l) => literal(l), + ValuePosition::Column(name) => format!("'{name}'"), + ValuePosition::Json { column, path } => { + format!("json('{column}', {})", path_segments(path)) + } + ValuePosition::Static { field, .. } => { + let field = match field { + StaticField::Single(f) => format!("'{f}'"), + StaticField::Path(p) => { + let parts: Vec = p.iter().map(|f| format!("'{f}'")).collect(); + format!("[{}]", parts.join(", ")) + } + }; + format!("authParam({field})") + } + } +} + +fn path_segments(path: &[JsonPathSegment]) -> String { + let parts: Vec = path.iter().map(|s| literal(&s.to_json())).collect(); + parts.join(", ") +} + +fn literal(v: &Value) -> String { + match v { + Value::Null => "null".into(), + Value::Array(_) => json::stringify(v), + Value::String(s) => js_string_literal(s), + Value::Number(n) => number::format(*n), + Value::Bool(b) => b.to_string(), + Value::Object(_) => json::stringify(v), + } +} + +/// A single-quoted JS string literal for `s`, escaped as `JSON.stringify` +/// escapes it. +fn js_string_literal(s: &str) -> String { + let quoted = json::stringify(&Value::String(s.to_owned())); + let inner = "ed[1..quoted.len() - 1]; + format!("'{}'", inner.replace("\\\"", "\"").replace('\'', "\\'")) +} + +fn string_list(items: &[String]) -> String { + let parts: Vec = items.iter().map(|s| js_string_literal(s)).collect(); + parts.join(", ") +} + +fn aggregate_arg(a: &Aggregate) -> String { + let Some(field) = &a.field else { + return String::new(); + }; + let name = js_string_literal(field); + match &a.path { + None => name, + Some(path) => format!("({{json}}) => json({name}, {})", path_segments(path)), + } +} diff --git a/rust/zero-client/src/builder/mod.rs b/rust/zero-client/src/builder/mod.rs index 205c3c48a4..4adf42dfb9 100644 --- a/rust/zero-client/src/builder/mod.rs +++ b/rust/zero-client/src/builder/mod.rs @@ -64,6 +64,11 @@ pub trait BuilderDelegate { fn aggregate_key_columns(&self, _table: &str, columns: &[String]) -> Vec { columns.to_vec() } + /// Wraps each source connection of query `query_id`'s pipeline + /// (`decorateSourceInput`), as the client does to time its pushes. + fn decorate_source_input(&self, input: Rc, _query_id: &str) -> Rc { + input + } } /// `OptimisticAggregate`: how a mutation of a child row moves a synced @@ -189,7 +194,7 @@ impl Builder<'_> { None, None, )?; - return Ok(conn); + return Ok(self.delegate.decorate_source_input(conn, self.query_id)); } if ast_in.group_by.is_some() && self.delegate.aggregates_from_source() { return self.group_from_source(ast_in); @@ -239,7 +244,7 @@ impl Builder<'_> { }; let conn = source.connect(sort, ast.where_.as_ref(), Some(&split_edit_keys))?; let fully_applied_filters = conn.fully_applied_filters(); - let mut end: Rc = conn; + let mut end: Rc = self.delegate.decorate_source_input(conn, self.query_id); if let Some(start) = &ast.start { end = Skip::new(end, start); @@ -655,7 +660,9 @@ impl Builder<'_> { direction: Direction::Asc, }) .collect(); - Ok(source.connect(Some(sort), None, None)?) + Ok(self + .delegate + .decorate_source_input(source.connect(Some(sort), None, None)?, self.query_id)) } /// `groupFromSource`: a synced client reads a grouped query's rows from @@ -709,7 +716,9 @@ impl Builder<'_> { ) else { return err(format!("Group source not found: {table}")); }; - Ok(source.connect(Some(sort), None, None)?) + Ok(self + .delegate + .decorate_source_input(source.connect(Some(sort), None, None)?, self.query_id)) } #[allow(clippy::too_many_arguments)] diff --git a/rust/zero-client/src/client/database.rs b/rust/zero-client/src/client/database.rs index 84241519d2..a3add67af9 100644 --- a/rust/zero-client/src/client/database.rs +++ b/rust/zero-client/src/client/database.rs @@ -318,6 +318,20 @@ impl ReplicaDatabase { } } + /// The clients that used the database, oldest first. + pub(crate) fn clients(&self) -> Vec { + self.clients.borrow().clone() + } + + /// The entries of client group `id`'s stored snapshot with its pending + /// mutations applied, if the group is there. + pub(crate) fn group_entries(&self, id: &str) -> Option { + if !self.groups.borrow().iter().any(|g| g.id == id) { + return None; + } + self.load_group(id).ok().map(|g| g.entries) + } + pub(crate) fn deleted_clients(&self) -> Vec { self.deleted_clients.borrow().clone() } diff --git a/rust/zero-client/src/client/engine.rs b/rust/zero-client/src/client/engine.rs index 7498e60521..26c3ccb217 100644 --- a/rust/zero-client/src/client/engine.rs +++ b/rust/zero-client/src/client/engine.rs @@ -221,6 +221,11 @@ pub struct ZeroOptions { /// first hydration), with its listener calls. It must call the function /// it is given, once, before it returns. pub batch_view_updates: Option, + /// How long, in ms, a query may take to materialize, including the + /// server's and the network's time, before the client logs a warning + /// (`slowMaterializeThreshold`). Faster materializations are logged at + /// debug level. + pub slow_materialize_threshold_ms: f64, } impl Default for ZeroOptions { @@ -247,6 +252,7 @@ impl Default for ZeroOptions { hidden_disconnect_delay_ms: 0.0, get_traceparent: None, batch_view_updates: None, + slow_materialize_threshold_ms: 5_000.0, } } } @@ -366,6 +372,8 @@ struct ReadyPromise(Rc>); #[derive(Default)] struct ReadyState { settled: Option, + /// Why the connection failed, once it has. + error: Option, waiters: Vec>, } @@ -505,6 +513,23 @@ impl SocketEvents for SocketHandle { type VisibilityWaiter = (bool, u64, Box); +/// What an inspector request hears: zero-cache's answer, the `inspect` +/// body, or why there is none. +pub(crate) type InspectAnswer = Box)>; + +/// An inspector request (`rpcNoAuthTry` in `lazy-inspector.ts`), waiting +/// for the connection or, once sent, for the answer with its ID. +struct InspectRequest { + id: String, + /// What to send, until it is. + body: Option, + sent: bool, + /// Waiting for the next connection attempt: the last one's socket + /// closed before the request went out. + parked: bool, + done: InspectAnswer, +} + pub(crate) struct Engine { me: Weak, pub(crate) schema: Arc, @@ -521,14 +546,14 @@ pub(crate) struct Engine { mutators: Rc>, client_schema: crate::protocol::ClientSchema, - store: RefCell, + pub(crate) store: RefCell, pub(crate) database: Rc, lifecycle_timers: RefCell>>, ivm_main: Rc, pub(crate) context: Rc, pub(crate) connection_manager: Rc, mutation_tracker: Rc, - query_manager: Rc, + pub(crate) query_manager: Rc, poke_handler: RefCell, /// The current token: `options.auth`, then the last one `connect` @@ -591,6 +616,8 @@ pub(crate) struct Engine { /// What `Zero` does when the app must be updated to sync, besides /// calling `ZeroOptions::on_update_needed`. pub(crate) on_update_needed: RefCell>, + /// The inspector's requests, oldest first. + inspect_requests: RefCell>, } fn noop() -> Rc { @@ -808,15 +835,33 @@ impl Engine { }), )) }; + let query_manager = { + let (s, p) = (me.clone(), me.clone()); + QueryManager::new( + client_id.clone(), + scheduler.clone(), + options.query_change_throttle_ms, + Box::new(move |mut body| { + if let Some(e) = s.upgrade() { + body.traceparent = e.traceparent(); + e.send_if_connected(Upstream::ChangeDesiredQueries(body)); + } + }), + Box::new(move || p.upgrade().map_or(0, |e| e.mutation_tracker.size())), + log.clone(), + options.slow_materialize_threshold_ms, + ) + }; let context = { let (a, u, c) = (me.clone(), me.clone(), me.clone()); let l = event_loop.clone(); QueryContext::new( ivm_main.clone(), - Box::new(move |id, ttl, got| match a.upgrade() { - Some(e) => e - .query_manager - .add_custom(&id.name, &id.args, ttl, Some(got)), + Box::new(move |id, ast, ttl, got| match a.upgrade() { + Some(e) => { + e.query_manager + .add_custom(ast, &id.name, &id.args, ttl, Some(got)) + } None => Box::new(|| {}), }), Rc::new(move |id, ttl| { @@ -832,21 +877,7 @@ impl Engine { }), true, options.batch_view_updates.clone(), - ) - }; - let query_manager = { - let (s, p) = (me.clone(), me.clone()); - QueryManager::new( - client_id.clone(), - scheduler.clone(), - options.query_change_throttle_ms, - Box::new(move |mut body| { - if let Some(e) = s.upgrade() { - body.traceparent = e.traceparent(); - e.send_if_connected(Upstream::ChangeDesiredQueries(body)); - } - }), - Box::new(move || p.upgrade().map_or(0, |e| e.mutation_tracker.size())), + Some(query_manager.clone()), ) }; Engine { @@ -913,6 +944,7 @@ impl Engine { waiting_for_write_lock: RefCell::default(), on_client_state_not_found: RefCell::new(None), on_update_needed: RefCell::new(None), + inspect_requests: RefCell::default(), } }); @@ -1697,7 +1729,8 @@ impl Engine { last_mutation_id: self.last_mutation_id_received.get(), wsid, profile_id: self.profile_id.clone(), - debug_perf: false, + // JS asks for the server's timings when it logs at debug level. + debug_perf: self.options.log_level == LogLevel::Debug, additional_params: self .additional_connect_params .borrow() @@ -1810,7 +1843,19 @@ impl Engine { if !attempt.aborted.get() { self.disconnect(error.clone(), None); } + ready.0.borrow_mut().error.get_or_insert(error.clone()); ready.settle(false, &self.event_loop); + let parked: Vec = { + let mut requests = self.inspect_requests.borrow_mut(); + let (parked, rest) = std::mem::take(&mut *requests) + .into_iter() + .partition(|r| r.parked); + *requests = rest; + parked + }; + for r in parked { + (r.done)(Err(error.clone().into())); + } if self.connection_ready.borrow().is(&ready) { *self.connection_ready.borrow_mut() = ReadyPromise::default(); } @@ -1818,6 +1863,19 @@ impl Engine { return; } ready.settle(true, &self.event_loop); + let parked: Vec = self + .inspect_requests + .borrow_mut() + .iter_mut() + .filter(|r| r.parked) + .map(|r| { + r.parked = false; + r.id.clone() + }) + .collect(); + for id in parked { + self.inspect_when_connected(id); + } *self.additional_connect_params.borrow_mut() = None; match Self::connection_error(&self.connection_manager.state()) { Some(error) => self.loop_failed(error), @@ -1874,6 +1932,22 @@ impl Engine { } } } + // The answers to the inspector's requests would have come on the + // socket that closed. + let lost: Vec = { + let mut requests = self.inspect_requests.borrow_mut(); + let (lost, waiting) = std::mem::take(&mut *requests) + .into_iter() + .partition(|r| r.sent); + *requests = waiting; + lost + }; + for r in lost { + (r.done)(Err(Error::Message(format!( + "The inspector's request got no answer: the connection to zero-cache closed ({})", + reason.message() + )))); + } } // MARK: Messages @@ -2082,7 +2156,7 @@ impl Engine { Downstream::TransformError(errors) => { self.query_manager.handle_transform_errors(&errors) } - Downstream::Inspect(_) => {} + Downstream::Inspect(body) => self.inspect_answered(body.0), } } @@ -2377,6 +2451,97 @@ impl Engine { self.database.release(); self.database.remove_failure_listener(&self.client_id); self.connection_manager.closed(); + let requests = std::mem::take(&mut *self.inspect_requests.borrow_mut()); + for r in requests { + (r.done)(Err(ConnectionError::client( + ClientErrorKind::ClientClosed, + "Zero instance closed by user", + ) + .into())); + } + } + + // MARK: The inspector + + /// Sends an inspector request (`rpcNoAuthTry`) once connected, with a + /// new ID; `done` hears the answer with that ID, or why there is none. + pub(crate) fn inspect(&self, body: Object, done: InspectAnswer) { + if self.rep_closed.get() { + return done(Err(ConnectionError::client( + ClientErrorKind::ClientClosed, + "Zero instance closed by user", + ) + .into())); + } + let id = random_id(); + self.inspect_requests.borrow_mut().push(InspectRequest { + id: id.clone(), + body: Some(body), + sent: false, + parked: false, + done, + }); + self.inspect_when_connected(id); + } + + /// Sends request `id` once the connection is ready (`getSocket`), or + /// fails it when connecting fails. + fn inspect_when_connected(&self, id: String) { + let ready = self.connection_ready.borrow().clone(); + let w = self.me.clone(); + let r = ready.clone(); + ready.on_settle(&self.event_loop, move |connected| { + if let Some(e) = w.upgrade() { + let error = r.0.borrow().error.clone(); + e.inspect_ready(id, connected, error); + } + }); + } + + fn inspect_ready(&self, id: String, connected: bool, error: Option) { + let mut requests = self.inspect_requests.borrow_mut(); + let Some(i) = requests.iter().position(|r| r.id == id && !r.sent) else { + return; + }; + if !connected { + let r = requests.remove(i); + drop(requests); + let error = error.unwrap_or_else(|| { + ConnectionError::client(ClientErrorKind::Internal, "Not connected to zero-cache") + }); + return (r.done)(Err(error.into())); + } + let socket = self.socket.borrow().clone(); + match socket { + Some(socket) if self.status_is(ConnectionStatus::Connected) => { + let r = &mut requests[i]; + r.sent = true; + let mut body = r.body.take().unwrap_or_default(); + body.insert("id", Value::from(id.as_str())); + let text = Upstream::Inspect(crate::protocol::InspectUpBody(Value::Object(body))) + .to_text(); + drop(requests); + socket.send(&text); + } + // The connection dropped since: wait for the next attempt. + _ => requests[i].parked = true, + } + } + + /// zero-cache answered an inspector request. + fn inspect_answered(&self, body: Value) { + let Value::Object(body) = body else { return }; + let Some(id) = body.get("id").and_then(Value::as_str) else { + return; + }; + let request = { + let mut requests = self.inspect_requests.borrow_mut(); + let Some(i) = requests.iter().position(|r| r.sent && r.id == id) else { + return; + }; + requests.remove(i) + }; + (request.done)(Ok(body)); } // MARK: Storage and the client lifecycle diff --git a/rust/zero-client/src/client/inspector.rs b/rust/zero-client/src/client/inspector.rs new file mode 100644 index 0000000000..25d284a557 --- /dev/null +++ b/rust/zero-client/src/client/inspector.rs @@ -0,0 +1,959 @@ +//! The inspector (`packages/zero-client/src/client/inspector`): the +//! client's queries and metrics, what the server knows of them, and the +//! server's analysis of a query, for debugging and tooling. +//! +//! Its RPCs go over the sync socket as `inspect` messages +//! (`packages/zero-protocol/src/inspect-up.ts` and `inspect-down.ts`). + +use super::engine::Engine; +use super::planner_debug; +use super::{ClientErrorKind, ConnectionError, Deferred, Error}; +use crate::ast::{Ast, ast_to_zql}; +use crate::decode::JsonCodable; +use crate::json::{Object, Value}; +use crate::keys::ENTITIES_PREFIX; +use crate::map::OrderedMap; +use crate::query::ZeroQuery; +use crate::schema::{NameMapper, Schema}; +use crate::tdigest::TDigest; +use crate::ttl::Ttl; +use std::cell::{Cell, RefCell}; +use std::rc::Rc; +use std::sync::Arc; + +/// The client's and the server's query metrics (`Metrics` in +/// `lazy-inspector.ts`), each a digest of times in ms. +#[derive(Clone, Debug, Default, PartialEq)] +pub struct Metrics { + /// `query-materialization-client`: building and hydrating a view. + pub query_materialization_client: TDigest, + /// `query-materialization-end-to-end`: from materializing a query + /// until the server has sent its rows. + pub query_materialization_end_to_end: TDigest, + /// `query-update-client`: a change through a query's pipeline. Only one + /// change in 32 is timed, and counts 32 times. + pub query_update_client: TDigest, + /// `query-materialization-server`: the server hydrating a query. + pub query_materialization_server: TDigest, + /// `query-update-server`: a change through the server's pipeline. + pub query_update_server: TDigest, +} + +impl Metrics { + /// The digests by JS name, as their JSON forms. + pub fn to_json(&self) -> Value { + let mut o = Object::new(); + o.insert( + "query-materialization-client", + self.query_materialization_client.to_json(), + ); + o.insert( + "query-materialization-end-to-end", + self.query_materialization_end_to_end.to_json(), + ); + o.insert("query-update-client", self.query_update_client.to_json()); + o.insert( + "query-materialization-server", + self.query_materialization_server.to_json(), + ); + o.insert("query-update-server", self.query_update_server.to_json()); + Value::Object(o) + } +} + +/// One query's client metrics (`QueryClientMetrics`): the last +/// materialization's times, and its updates. +#[derive(Clone, Debug, Default)] +pub(crate) struct QueryClientMetrics { + pub(crate) query_materialization_client: Option, + pub(crate) query_materialization_end_to_end: Option, + pub(crate) query_update_client: TDigest, +} + +/// What [`Inspector::analyze_query`] asks the server for besides the +/// basics (`AnalyzeQueryOptions`). Options left `None` are not sent. +#[derive(Clone, Debug, Default, PartialEq)] +pub struct AnalyzeQueryOptions { + /// The rows the query read from each source. + pub vended_rows: Option, + /// The rows the query synced, by table. + pub synced_rows: Option, + /// The planner's debug events, for + /// [`Inspector::format_planner_events`]. + pub join_plans: Option, +} + +impl AnalyzeQueryOptions { + /// The options as sent; `None` when none is set. + fn to_json(&self) -> Option { + let mut o = Object::new(); + for (key, v) in [ + ("vendedRows", self.vended_rows), + ("syncedRows", self.synced_rows), + ("joinPlans", self.join_plans), + ] { + if let Some(v) = v { + o.insert(key, Value::Bool(v)); + } + } + (!o.is_empty()).then_some(Value::Object(o)) + } +} + +/// One of the planner's debug events (`PlanDebugEventJSON` in +/// `packages/zero-protocol/src/analyze-query-result.ts`), as JSON: its +/// `type` says which. +#[derive(Clone, Debug, PartialEq)] +pub struct PlanDebugEvent(pub Value); + +/// Rows by query (or table). +pub type RowsByQuery = OrderedMap>; +/// Row counts by source, then by query. +pub type RowCountsBySource = OrderedMap>; +/// Rows by source, then by query. +pub type RowsBySource = OrderedMap; + +/// The server's analysis of a query (`AnalyzeQueryResult` in +/// `packages/zero-protocol/src/analyze-query-result.ts`). +#[derive(Clone, Debug, Default, PartialEq)] +pub struct AnalyzeQueryResult { + /// What the server warns about the query. + pub warnings: Vec, + /// The rows synced, by table, when asked for. + pub synced_rows: Option, + /// How many rows were synced. + pub synced_row_count: f64, + /// When the analysis started, in ms. + pub start: f64, + /// When it ended, in ms. + pub end: f64, + /// How long it took, in ms. + pub elapsed: Option, + /// The query after the permissions applied, as ZQL. + pub after_permissions: Option, + /// The rows each source vended, counted. + pub vended_row_counts: Option, + /// The rows each source vended, when asked for. + pub vended_rows: Option, + /// SQLite's query plans, by query. + pub sqlite_plans: Option>>, + /// The rows read, by source and query. + pub read_rows: Option, + /// The rows read, counted by source and query. + pub read_row_counts_by_query: Option, + /// How many rows were read. + pub read_row_count: Option, + /// The database scans, counted by source and query. + pub db_scans_by_query: Option, + /// The planner's debug events, when asked for. + pub join_plans: Option>, +} + +fn record(v: Option<&Value>, f: impl Fn(&Value) -> T) -> Option> { + let o = v?.as_object()?; + Some(o.iter().map(|(k, v)| (k.clone(), f(v))).collect()) +} + +fn rows(v: &Value) -> Vec { + v.as_array() + .map(|a| a.iter().filter_map(|r| r.as_object().cloned()).collect()) + .unwrap_or_default() +} + +fn number(v: &Value) -> f64 { + v.as_f64().unwrap_or(f64::NAN) +} + +fn record_json(r: &OrderedMap, f: impl Fn(&T) -> Value) -> Value { + Value::Object(r.iter().map(|(k, v)| (k.clone(), f(v))).collect()) +} + +fn rows_json(rows: &[Object]) -> Value { + Value::Array(rows.iter().cloned().map(Value::Object).collect()) +} + +impl AnalyzeQueryResult { + /// The result of the JSON the server sent, already checked against + /// `analyzeQueryResultSchema`. + pub fn from_json(v: &Value) -> Self { + let get = |k: &str| v.get(k); + let counts = |k: &str| record(get(k), |v| record(Some(v), number).unwrap_or_default()); + let by_source = |k: &str| record(get(k), |v| record(Some(v), rows).unwrap_or_default()); + AnalyzeQueryResult { + warnings: get("warnings") + .and_then(Value::as_array) + .map(|a| { + a.iter() + .filter_map(|w| w.as_str().map(str::to_owned)) + .collect() + }) + .unwrap_or_default(), + synced_rows: record(get("syncedRows"), rows), + synced_row_count: get("syncedRowCount").map_or(f64::NAN, number), + start: get("start").map_or(f64::NAN, number), + end: get("end").map_or(f64::NAN, number), + elapsed: get("elapsed").and_then(Value::as_f64), + after_permissions: get("afterPermissions") + .and_then(Value::as_str) + .map(str::to_owned), + vended_row_counts: counts("vendedRowCounts"), + vended_rows: by_source("vendedRows"), + sqlite_plans: record(get("sqlitePlans"), |v| { + v.as_array() + .map(|a| { + a.iter() + .filter_map(|s| s.as_str().map(str::to_owned)) + .collect() + }) + .unwrap_or_default() + }), + read_rows: by_source("readRows"), + read_row_counts_by_query: counts("readRowCountsByQuery"), + read_row_count: get("readRowCount").and_then(Value::as_f64), + db_scans_by_query: counts("dbScansByQuery"), + join_plans: get("joinPlans") + .and_then(Value::as_array) + .map(|a| a.iter().cloned().map(PlanDebugEvent).collect()), + } + } + + /// The result as JSON, as the server sent it. + pub fn to_json(&self) -> Value { + let counts = + |c: &RowCountsBySource| record_json(c, |q| record_json(q, |n| Value::Number(*n))); + let by_source = |r: &RowsBySource| record_json(r, |q| record_json(q, |r| rows_json(r))); + let mut o = Object::new(); + o.insert( + "warnings", + Value::Array(self.warnings.iter().cloned().map(Value::String).collect()), + ); + if let Some(r) = &self.synced_rows { + o.insert("syncedRows", record_json(r, |r| rows_json(r))); + } + o.insert("syncedRowCount", Value::Number(self.synced_row_count)); + o.insert("start", Value::Number(self.start)); + o.insert("end", Value::Number(self.end)); + if let Some(e) = self.elapsed { + o.insert("elapsed", Value::Number(e)); + } + if let Some(a) = &self.after_permissions { + o.insert("afterPermissions", Value::String(a.clone())); + } + if let Some(c) = &self.vended_row_counts { + o.insert("vendedRowCounts", counts(c)); + } + if let Some(r) = &self.vended_rows { + o.insert("vendedRows", by_source(r)); + } + if let Some(p) = &self.sqlite_plans { + o.insert( + "sqlitePlans", + record_json(p, |p| { + Value::Array(p.iter().cloned().map(Value::String).collect()) + }), + ); + } + if let Some(r) = &self.read_rows { + o.insert("readRows", by_source(r)); + } + if let Some(c) = &self.read_row_counts_by_query { + o.insert("readRowCountsByQuery", counts(c)); + } + if let Some(n) = self.read_row_count { + o.insert("readRowCount", Value::Number(n)); + } + if let Some(c) = &self.db_scans_by_query { + o.insert("dbScansByQuery", counts(c)); + } + if let Some(p) = &self.join_plans { + o.insert( + "joinPlans", + Value::Array(p.iter().map(|e| e.0.clone()).collect()), + ); + } + Value::Object(o) + } +} + +/// A query as the server and the client know it (`Query` in +/// `inspector/query.ts`): one row of the server's `queries` answer, with +/// the client's metrics merged in. +#[derive(Clone, Debug, PartialEq)] +pub struct InspectorQuery { + /// The named query's name; `None` for an unnamed one. + pub name: Option, + /// The named query's arguments; `None` for an unnamed one. + pub args: Option>, + /// Whether the server has synced the query's rows. + pub got: bool, + /// The query's TTL, normalized. + pub ttl: Ttl, + /// When the query became inactive, in ms since 1970; `None` while + /// active. + pub inactivated_at: Option, + /// How many rows the query synced. + pub row_count: f64, + /// Whether the server deleted the query. + pub deleted: bool, + /// The query's ID, its hash. + pub id: String, + /// The client that wants it. + pub client_id: String, + /// The client's and the server's metrics of it. + pub metrics: Metrics, + /// The query as this client built it, as ZQL; `None` when this client + /// doesn't know it. + pub client_zql: Option, + /// The query the server runs, as ZQL. + pub server_zql: Option, + /// How long the client took to hydrate it, in ms. + pub hydrate_client: Option, + /// How long the server took to hydrate it, in ms. + pub hydrate_server: Option, + /// How long it took from materializing to the server's rows, in ms. + pub hydrate_total: Option, + /// The median client update, in ms. + pub update_client_p50: Option, + /// The 95th percentile client update, in ms. + pub update_client_p95: Option, + /// The median server update, in ms. + pub update_server_p50: Option, + /// The 95th percentile server update, in ms. + pub update_server_p95: Option, +} + +/// `TimeClip` of `new Date(ms)`: the integer part, NaN past ±8.64e15. +fn time_clip(ms: f64) -> f64 { + if !ms.is_finite() || ms.abs() > 8.64e15 { + return f64::NAN; + } + ms.trunc() + 0.0 +} + +fn percentile(d: &TDigest, q: f64) -> Option { + let n = d.quantile(q); + (!n.is_nan()).then_some(n) +} + +fn zql(ast: &Ast) -> String { + format!("{}{}", ast.table, ast_to_zql(ast, false)) +} + +impl InspectorQuery { + /// The query of a row of the server's `queries` answer. + fn new(row: &Value, engine: &Engine) -> Self { + let get = |k: &str| row.get(k); + let str_of = |k: &str| { + get(k) + .and_then(Value::as_str) + .unwrap_or_default() + .to_owned() + }; + let id = str_of("queryID"); + let server_ast = get("ast").and_then(|a| Ast::from_json(a).ok()); + let client_metrics = engine.query_manager.query_metrics(&id); + let server = get("metrics").filter(|m| !m.is_null()); + let hydrate_server = server + .and_then(|m| m.get("query-hydration-server-ms")) + .and_then(Value::as_f64); + let cm = client_metrics.clone().unwrap_or_default(); + let mut metrics = Metrics { + query_update_client: cm.query_update_client.clone(), + ..Metrics::default() + }; + if let Some(v) = cm.query_materialization_client { + metrics.query_materialization_client.add(v, 1.0); + } + if let Some(v) = cm.query_materialization_end_to_end { + metrics.query_materialization_end_to_end.add(v, 1.0); + } + if let Some(server) = server { + if let Some(ms) = hydrate_server { + metrics.query_materialization_server.add(ms, 1.0); + } + if let Some(d) = server + .get("query-update-server") + .and_then(|d| TDigest::from_json_value(d).ok()) + { + metrics.query_update_server = d; + } + } + InspectorQuery { + name: get("name").and_then(Value::as_str).map(str::to_owned), + args: get("args").and_then(Value::as_array).cloned(), + got: get("got").and_then(Value::as_bool).unwrap_or_default(), + ttl: Ttl::Milliseconds(get("ttl").and_then(Value::as_f64).unwrap_or_default()) + .normalized(), + inactivated_at: get("inactivatedAt").and_then(Value::as_f64).map(time_clip), + row_count: get("rowCount").and_then(Value::as_f64).unwrap_or_default(), + deleted: get("deleted").and_then(Value::as_bool).unwrap_or_default(), + client_id: str_of("clientID"), + client_zql: engine.query_manager.query_ast(&id).as_ref().map(zql), + server_zql: server_ast.as_ref().map(zql), + hydrate_client: client_metrics + .as_ref() + .and_then(|m| m.query_materialization_client), + hydrate_server, + hydrate_total: client_metrics + .as_ref() + .and_then(|m| m.query_materialization_end_to_end), + update_client_p50: percentile(&metrics.query_update_client, 0.5), + update_client_p95: percentile(&metrics.query_update_client, 0.95), + update_server_p50: percentile(&metrics.query_update_server, 0.5), + update_server_p95: percentile(&metrics.query_update_server, 0.95), + metrics, + id, + } + } +} + +/// What the inspector's handles share: the client, and the admin password +/// zero-cache last accepted (`adminPassword`), which is presented again +/// when a new connection isn't authenticated yet. +pub(crate) struct InspectorHost { + pub(crate) engine: Box Option>>, + pub(crate) schema: Arc, + pub(crate) admin_password: RefCell>, +} + +/// The error of an RPC the server refused for want of authentication. +/// JS prompts for the password there. +fn authentication_required() -> Error { + Error::Message( + "Authentication failed: zero-cache requires the inspector to authenticate. \ + Call `authenticate(password)` with its admin password first." + .into(), + ) +} + +fn closed() -> Error { + ConnectionError::client( + ClientErrorKind::ClientClosed, + "Zero instance closed by user", + ) + .into() +} + +enum Answer { + Done(Result), + Unauthenticated, +} + +/// What an answer means for an RPC expecting `expect` (`rpcNoAuthTry`). +fn classify(answer: &Result, expect: &str) -> Answer { + let body = match answer { + Ok(b) => b, + Err(e) => return Answer::Done(Err(e.clone())), + }; + let op = body.get("op").and_then(Value::as_str).unwrap_or_default(); + let value = body.get("value").cloned().unwrap_or_default(); + if op == "error" { + let message = value.as_str().unwrap_or_default().to_owned(); + return Answer::Done(Err(Error::Message(message))); + } + if op == expect { + return Answer::Done(Ok(value)); + } + if op == "authenticated" && value == Value::Bool(false) { + return Answer::Unauthenticated; + } + Answer::Done(Err(Error::Message(format!( + "Expected an inspector \"{expect}\" answer, got \"{op}\"" + )))) +} + +fn op(name: &str) -> Object { + let mut o = Object::new(); + o.insert("op", Value::from(name)); + o +} + +impl InspectorHost { + fn engine(&self) -> Option> { + let e = (self.engine)()?; + e.query_manager.keep_evicted(); + Some(e) + } + + /// Sends `body` with a new ID; settles with the server's answer. + fn send(&self, body: Object) -> Deferred { + let out = Deferred::new(); + match self.engine() { + None => out.reject(closed()), + Some(e) => { + let o = out.clone(); + e.event_loop + .call(|| e.inspect(body, Box::new(move |r| o.settle(r)))); + } + } + out + } + + /// `authenticateSocket`. + fn authenticate_once(&self, password: &str) -> Deferred { + let mut body = op("authenticate"); + body.insert("value", Value::from(password)); + let out = Deferred::new(); + let o = out.clone(); + self.send(body) + .on_settle(move |r| match classify(r, "authenticated") { + Answer::Done(r) => o.settle(r.map(|v| v == Value::Bool(true))), + Answer::Unauthenticated => o.resolve(false), + }); + out + } + + /// `rpc`: sends `body`, and when the connection isn't authenticated, + /// presents the password accepted last and tries again. + fn rpc(self: &Rc, body: Object, expect: &'static str) -> Deferred { + let out = Deferred::new(); + let (host, o) = (self.clone(), out.clone()); + self.send(body.clone()) + .on_settle(move |r| match classify(r, expect) { + Answer::Done(r) => o.settle(r), + Answer::Unauthenticated => host.authenticate_and_retry(body, expect, o), + }); + out + } + + fn authenticate_and_retry( + self: &Rc, + body: Object, + expect: &'static str, + out: Deferred, + ) { + let Some(password) = self.admin_password.borrow().clone() else { + return out.reject(authentication_required()); + }; + let host = self.clone(); + self.authenticate_once(&password) + .on_settle(move |r| match r { + Err(e) => out.reject(e.clone()), + Ok(false) => { + *host.admin_password.borrow_mut() = None; + out.reject(authentication_required()); + } + Ok(true) => host + .send(body) + .on_settle(move |r| match classify(r, expect) { + Answer::Done(r) => out.settle(r), + Answer::Unauthenticated => out.reject(authentication_required()), + }), + }); + } + + /// The server's `queries` answer, as queries, slowest server hydration + /// first. + fn queries(self: &Rc, client_id: Option<&str>) -> Deferred> { + let mut body = op("queries"); + if let Some(id) = client_id { + body.insert("clientID", Value::from(id)); + } + let out = Deferred::new(); + let (host, o) = (self.clone(), out.clone()); + self.rpc(body, "queries").on_settle(move |r| { + let rows = match r { + Ok(v) => v.as_array().cloned().unwrap_or_default(), + Err(e) => return o.reject(e.clone()), + }; + let Some(engine) = host.engine() else { + return o.reject(closed()); + }; + let mut queries: Vec = rows + .iter() + .map(|r| InspectorQuery::new(r, &engine)) + .collect(); + queries.sort_by(|a, b| { + let (a, b) = ( + a.hydrate_server.unwrap_or(0.0), + b.hydrate_server.unwrap_or(0.0), + ); + b.partial_cmp(&a).unwrap_or(std::cmp::Ordering::Equal) + }); + o.resolve(queries); + }); + out + } + + /// The clients in the local store whose group `group` (any for + /// `None`) is. + fn clients(self: &Rc, group: Option<&str>) -> Deferred> { + let out = Deferred::new(); + match self.engine() { + None => out.reject(closed()), + Some(e) => out.resolve( + e.database + .clients() + .into_iter() + .filter(|c| group.is_none_or(|g| c.client_group_id == g)) + .map(|c| InspectorClient { + host: self.clone(), + id: c.id, + client_group_id: c.client_group_id, + }) + .collect(), + ), + } + out + } + + /// The clients of `clients` the server has queries of, in the order + /// it answers (`clientsWithQueries`). + fn clients_with_queries( + self: &Rc, + clients: Deferred>, + ) -> Deferred> { + let out = Deferred::new(); + let o = out.clone(); + clients.on_settle(move |r| { + let clients = match r { + Ok(c) => c.clone(), + Err(e) => return o.reject(e.clone()), + }; + if clients.is_empty() { + return o.resolve(Vec::new()); + } + let found: Rc>> = Rc::default(); + let left = Rc::new(Cell::new(clients.len())); + for client in clients { + let (o, found, left) = (o.clone(), found.clone(), left.clone()); + let queries = client.queries(); + queries.on_settle(move |r| match r { + Err(e) => o.reject(e.clone()), + Ok(q) => { + if !q.is_empty() { + found.borrow_mut().push(client); + } + left.set(left.get() - 1); + if left.get() == 0 { + o.resolve(found.borrow().clone()); + } + } + }); + } + }); + out + } + + /// The entries of the store of `client_id`'s group with keys starting + /// with `prefix`, in key order. + fn entries(&self, client_id: &str, prefix: &str) -> Result, Error> { + let e = self.engine().ok_or_else(closed)?; + let client = e + .database + .clients() + .into_iter() + .find(|c| c.id == client_id) + .ok_or_else(|| Error::Message(format!("Client not found: {client_id}")))?; + let collect = |m: &super::replica_store::KvMap| { + m.scan(prefix) + .map(|(k, v)| (k.clone(), v.clone())) + .collect::>() + }; + // The client's own group is what the store holds now, as JS + // persists it before reading. + if client.client_group_id == e.client_group_id { + return Ok(collect(&e.store.borrow().main)); + } + let group = e + .database + .group_entries(&client.client_group_id) + .ok_or_else(|| { + Error::Message(format!( + "Client group not found: {}", + client.client_group_id + )) + })?; + Ok(collect(&group)) + } +} + +fn settled(r: Result) -> Deferred { + let d = Deferred::new(); + d.settle(r); + d +} + +/// The inspector of a client (`Inspector` in `inspector/inspector.ts`), +/// from [`Zero::inspector`](super::Zero::inspector). +/// +/// zero-cache may require its admin password first: an RPC it refuses +/// fails with an error saying so (JS prompts for the password instead). +/// Once [`authenticate`](Self::authenticate) succeeds, the password is +/// presented again when a new connection isn't authenticated yet. +/// +/// An RPC waits for the connection. It fails when the connection drops +/// before the answer, and when the client closes. +pub struct Inspector { + pub(crate) host: Rc, + pub(crate) context: Rc, + pub(crate) client_id: String, + pub(crate) client_group_id: String, +} + +impl Clone for Inspector { + fn clone(&self) -> Self { + Inspector { + host: self.host.clone(), + context: self.context.clone(), + client_id: self.client_id.clone(), + client_group_id: self.client_group_id.clone(), + } + } +} + +impl Inspector { + /// This client. + pub fn client(&self) -> InspectorClient { + InspectorClient { + host: self.host.clone(), + id: self.client_id.clone(), + client_group_id: self.client_group_id.clone(), + } + } + + /// This client's group. + pub fn client_group(&self) -> InspectorClientGroup { + self.client().client_group() + } + + /// The client's query metrics merged with the server's + /// (`inspectorMetrics`). + pub fn metrics(&self) -> Deferred { + let out = Deferred::new(); + let (host, o) = (self.host.clone(), out.clone()); + self.host.rpc(op("metrics"), "metrics").on_settle(move |r| { + let server = match r { + Ok(v) => v.clone(), + Err(e) => return o.reject(e.clone()), + }; + let Some(engine) = host.engine() else { + return o.reject(closed()); + }; + let digest = |k: &str| { + server + .get(k) + .and_then(|d| TDigest::from_json_value(d).ok()) + .unwrap_or_default() + }; + let mut metrics = engine.query_manager.metrics(); + metrics.query_materialization_server = digest("query-materialization-server"); + metrics.query_update_server = digest("query-update-server"); + o.resolve(metrics); + }); + out + } + + /// Every client in the local store. + pub fn clients(&self) -> Deferred> { + self.host.clients(None) + } + + /// The clients in the local store the server has queries of: asks the + /// server for each client's queries. + pub fn clients_with_queries(&self) -> Deferred> { + self.host.clients_with_queries(self.host.clients(None)) + } + + /// zero-cache's version. + pub fn server_version(&self) -> Deferred { + let out = Deferred::new(); + let o = out.clone(); + self.host.rpc(op("version"), "version").on_settle(move |r| { + o.settle(r.clone().map(|v| v.as_str().unwrap_or_default().to_owned())) + }); + out + } + + fn analyze( + &self, + mut body: Object, + options: &AnalyzeQueryOptions, + ) -> Deferred { + if let Some(o) = options.to_json() { + body.insert("options", o); + } + let out = Deferred::new(); + let o = out.clone(); + self.host.rpc(body, "analyze-query").on_settle(move |r| { + o.settle( + r.as_ref() + .map(AnalyzeQueryResult::from_json) + .map_err(Clone::clone), + ) + }); + out + } + + /// Asks the server to analyze `query`: by name and arguments for a + /// named query, and by its AST, with the server's names, otherwise. + pub fn analyze_query( + &self, + query: &impl ZeroQuery, + options: AnalyzeQueryOptions, + ) -> Deferred { + let query = query.any_query(&self.context); + let mut body = op("analyze-query"); + match query.custom_query_id() { + Some(id) => { + body.insert("name", Value::from(id.name.as_str())); + body.insert("args", Value::Array(id.args.clone())); + } + None => match NameMapper::client_to_server(&self.host.schema).map(query.ast()) { + Ok(ast) => { + body.insert("ast", ast.to_json()); + } + Err(e) => return settled(Err(Error::Message(e.to_string()))), + }, + } + self.analyze(body, &options) + } + + /// Asks the server to analyze `ast`, which is sent as is: it must + /// have the server's names. + pub fn analyze_server_ast( + &self, + ast: &Ast, + options: AnalyzeQueryOptions, + ) -> Deferred { + let mut body = op("analyze-query"); + body.insert("ast", ast.to_json()); + self.analyze(body, &options) + } + + /// Asks the server to analyze the named query `name` with `args`, + /// which its query handler resolves. + pub fn analyze_named_query( + &self, + name: &str, + args: Vec, + options: AnalyzeQueryOptions, + ) -> Deferred { + let mut body = op("analyze-query"); + body.insert("name", Value::from(name)); + body.insert("args", Value::Array(args)); + self.analyze(body, &options) + } + + /// Authenticates with zero-cache's admin password: true when it + /// accepts it (or runs in a development mode that doesn't check). + /// zero-cache authenticates each connection; an accepted password is + /// presented again on a new one. + pub fn authenticate(&self, password: &str) -> Deferred { + let out = Deferred::new(); + let (host, o, password) = (self.host.clone(), out.clone(), password.to_owned()); + self.host.authenticate_once(&password).on_settle(move |r| { + if matches!(r, Ok(true)) { + *host.admin_password.borrow_mut() = Some(password); + } + o.settle(r.clone()); + }); + out + } + + /// The planner's debug events (`AnalyzeQueryResult::join_plans`) as + /// text: each attempt's costs, then the plan chosen. + pub fn format_planner_events(&self, events: &[PlanDebugEvent]) -> String { + planner_debug::format_planner_events(events) + } +} + +/// A client in the local store (`Client` in `inspector/client.ts`). +#[derive(Clone)] +pub struct InspectorClient { + host: Rc, + id: String, + client_group_id: String, +} + +impl std::fmt::Debug for InspectorClient { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + f.debug_struct("InspectorClient") + .field("id", &self.id) + .field("client_group_id", &self.client_group_id) + .finish() + } +} + +impl InspectorClient { + /// The client's ID. + pub fn id(&self) -> &str { + &self.id + } + + /// The client's group. + pub fn client_group(&self) -> InspectorClientGroup { + InspectorClientGroup { + host: self.host.clone(), + id: self.client_group_id.clone(), + } + } + + /// The server's queries of this client. + pub fn queries(&self) -> Deferred> { + self.host.queries(Some(&self.id)) + } + + /// Every entry of the client's local store, in key order: its rows, + /// desired and got queries, and the rest. + pub fn map(&self) -> Deferred> { + settled( + self.host + .entries(&self.id, "") + .map(|e| e.into_iter().collect()), + ) + } + + /// The rows of table `table` in the client's local store, in key + /// order. + pub fn rows(&self, table: &str) -> Deferred> { + let prefix = format!("{ENTITIES_PREFIX}{table}/"); + settled(self.host.entries(&self.id, &prefix).map(|e| { + e.into_iter() + .filter_map(|(_, v)| match v { + Value::Object(o) => Some(o), + _ => None, + }) + .collect() + })) + } +} + +/// A client group in the local store (`ClientGroup` in +/// `inspector/client-group.ts`). +#[derive(Clone)] +pub struct InspectorClientGroup { + host: Rc, + id: String, +} + +impl std::fmt::Debug for InspectorClientGroup { + fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { + f.debug_struct("InspectorClientGroup") + .field("id", &self.id) + .finish() + } +} + +impl InspectorClientGroup { + /// The group's ID. + pub fn id(&self) -> &str { + &self.id + } + + /// The group's clients in the local store. + pub fn clients(&self) -> Deferred> { + self.host.clients(Some(&self.id)) + } + + /// The group's clients the server has queries of. + pub fn clients_with_queries(&self) -> Deferred> { + self.host + .clients_with_queries(self.host.clients(Some(&self.id))) + } + + /// The server's queries of the group's clients. + pub fn queries(&self) -> Deferred> { + self.host.queries(None) + } +} diff --git a/rust/zero-client/src/client/measure_push.rs b/rust/zero-client/src/client/measure_push.rs new file mode 100644 index 0000000000..07d962bd30 --- /dev/null +++ b/rust/zero-client/src/client/measure_push.rs @@ -0,0 +1,119 @@ +//! Times the pushes through a query's source connections for the +//! `query-update-client` metric (`MeasurePushOperator` in +//! `packages/zql/src/query/measure-push-operator.ts`). + +use super::query_manager::{ClientMetric, MetricsDelegate, UPDATE_SAMPLE_RATE}; +use crate::ivm::{ + Change, FetchRequest, Input, InputBase, NodeStream, Output, SourceSchema, no_output, +}; +use std::cell::{Cell, RefCell}; +use std::rc::{Rc, Weak}; + +/// Passes a source connection's pushes and reconciles on, timing the first +/// of every `UPDATE_SAMPLE_RATE`; the others go straight to the output. +pub(crate) struct MeasurePush { + me: Weak, + input: Rc, + output: RefCell>, + query_id: Rc, + metrics: Rc, + /// Pushes and reconciles so far, sampled or not. + count: Cell, +} + +/// Records the time since `start` when dropped, so a push that fails is +/// still accounted to its query. +struct Timing<'a> { + op: &'a MeasurePush, + start: f64, +} + +impl Drop for Timing<'_> { + fn drop(&mut self) { + let elapsed = self.op.metrics.monotonic_now() - self.start; + self.op + .metrics + .add_metric(ClientMetric::UpdateClient, elapsed, &self.op.query_id, None); + } +} + +impl MeasurePush { + pub(crate) fn new( + input: Rc, + query_id: &str, + metrics: Rc, + ) -> Rc { + let op = Rc::new_cyclic(|me| MeasurePush { + me: me.clone(), + input, + output: RefCell::new(no_output()), + query_id: query_id.into(), + metrics, + count: Cell::new(0), + }); + let me: Weak = op.me.clone(); + op.input.set_output(me); + op + } + + fn sample(&self) -> bool { + let n = self.count.get(); + self.count.set(n.wrapping_add(1)); + n.is_multiple_of(UPDATE_SAMPLE_RATE) + } + + fn timing(&self) -> Timing<'_> { + Timing { + op: self, + start: self.metrics.monotonic_now(), + } + } +} + +impl InputBase for MeasurePush { + fn get_schema(&self) -> Rc { + self.input.get_schema() + } + + fn destroy(&self) { + self.input.destroy(); + } +} + +impl Input for MeasurePush { + fn set_output(&self, output: Weak) { + *self.output.borrow_mut() = output; + } + + fn fetch(&self, req: &FetchRequest) -> NodeStream { + self.input.fetch(req) + } +} + +impl Output for MeasurePush { + fn push(&self, change: Change, _pusher: &dyn InputBase) { + let Some(output) = self.output.borrow().upgrade() else { + return; + }; + if !self.sample() { + return output.push(change, self); + } + let _timing = self.timing(); + output.push(change, self); + } + + fn reconcile(&self, _pusher: &dyn InputBase) { + let Some(output) = self.output.borrow().upgrade() else { + return; + }; + // An output without a reconcile phase isn't counted, as in JS. + if !output.has_reconcile() { + return; + } + if !self.sample() { + return output.reconcile(self); + } + let _timing = self.timing(); + output.reconcile(self); + } +} diff --git a/rust/zero-client/src/client/mod.rs b/rust/zero-client/src/client/mod.rs index 4b9c855dd0..00e207a486 100644 --- a/rust/zero-client/src/client/mod.rs +++ b/rust/zero-client/src/client/mod.rs @@ -10,9 +10,12 @@ mod database; mod engine; mod error; mod event_loop; +mod inspector; mod ivm_branch; mod log; +mod measure_push; mod mutation_tracker; +mod planner_debug; mod poke_handler; mod query_context; mod query_manager; @@ -31,6 +34,10 @@ pub use engine::{ UpdateNeededReason, ZeroOptions, }; pub use error::*; +pub use inspector::{ + AnalyzeQueryOptions, AnalyzeQueryResult, Inspector, InspectorClient, InspectorClientGroup, + InspectorQuery, Metrics, PlanDebugEvent, RowCountsBySource, RowsByQuery, RowsBySource, +}; pub use log::{LogLevel, LogSink, StderrLogSink}; pub use query_context::{MaterializedView, Preload, RunType, ViewListener}; pub use scheduler::*; diff --git a/rust/zero-client/src/client/planner_debug.rs b/rust/zero-client/src/client/planner_debug.rs new file mode 100644 index 0000000000..cbe6b0cdc6 --- /dev/null +++ b/rust/zero-client/src/client/planner_debug.rs @@ -0,0 +1,348 @@ +//! The planner's debug events as text (`formatPlannerEvents` in +//! `packages/zql/src/planner/planner-debug.ts`), for +//! [`Inspector::format_planner_events`](super::Inspector::format_planner_events). + +use super::inspector::PlanDebugEvent; +use crate::ast::{Condition, ValuePosition, format_json_path}; +use crate::decode::JsonCodable; +use crate::json::{self, Value, number}; + +/// `formatPlannerEvents`: each planning attempt's connections and joins +/// with their costs, then the plan chosen. +pub(crate) fn format_planner_events(events: &[PlanDebugEvent]) -> String { + let mut lines: Vec = Vec::new(); + // By attempt, in order of first appearance (a JS `Map`). + let mut by_attempt: Vec<(f64, Vec<&Value>)> = Vec::new(); + let mut best: Option<&Value> = None; + for event in events { + let e = &event.0; + if let Some(attempt) = e.get("attemptNumber") { + if let Some(n) = attempt.as_f64() { + // `SameValueZero`. + let slot = by_attempt + .iter_mut() + .find(|(a, _)| *a == n || (a.is_nan() && n.is_nan())); + match slot { + Some((_, v)) => v.push(e), + None => by_attempt.push((n, vec![e])), + } + } + } else if ty(e) == "best-plan-selected" { + best = Some(e); + } + } + for (attempt, events) in &by_attempt { + lines.extend(attempt_summary(*attempt, events)); + lines.push(String::new()); + } + if let Some(b) = best { + let rule = "─".repeat(60); + lines.push(rule.clone()); + lines.push(format!( + "✓ Best plan: Attempt {} (cost={})", + number::format(num(b, "bestAttemptNumber") + 1.0), + to_fixed(num(b, "totalCost"), 2) + )); + let states = b + .get("joinStates") + .and_then(Value::as_array) + .cloned() + .unwrap_or_default(); + if !states.is_empty() { + lines.push(" Join types:".into()); + for j in &states { + lines.push(format!(" {}: {}", text(j, "join"), text(j, "type"))); + } + } + lines.push(rule); + } + lines.join("\n") +} + +fn ty(e: &Value) -> &str { + e.get("type").and_then(Value::as_str).unwrap_or("") +} + +fn num(e: &Value, key: &str) -> f64 { + e.get(key).and_then(Value::as_f64).unwrap_or(f64::NAN) +} + +fn text<'a>(e: &'a Value, key: &str) -> &'a str { + e.get(key).and_then(Value::as_str).unwrap_or("undefined") +} + +fn attempt_summary(attempt: f64, events: &[&Value]) -> Vec { + let mut lines = Vec::new(); + let total = events + .iter() + .find(|e| ty(e) == "attempt-start") + .and_then(|e| e.get("totalAttempts").and_then(Value::as_f64)); + let bits = match total { + // `Math.ceil(Math.log2(totalAttempts)) || 1`. + Some(t) => { + let b = t.log2().ceil(); + if b == 0.0 || b.is_nan() { 1.0 } else { b } + } + None => 1.0, + }; + let pattern = binary(attempt); + let width = if bits.is_finite() && bits > 0.0 { + bits as usize + } else { + 0 + }; + let pad = width.saturating_sub(pattern.encode_utf16().count()); + lines.push(format!( + "[Attempt {}/{}] Pattern {} ({}{pattern})", + number::format(attempt + 1.0), + total.map_or("?".to_owned(), number::format), + number::format(attempt), + "0".repeat(pad), + )); + + let node_events = |event: &str, node_type: &str| -> Vec<&Value> { + events + .iter() + .copied() + .filter(|e| { + ty(e) == event && e.get("nodeType").and_then(Value::as_str) == Some(node_type) + }) + .collect() + }; + let connection_costs = node_events("node-cost", "connection"); + let connection_constraints = node_events("node-constraint", "connection"); + if !connection_costs.is_empty() { + lines.push(" Connections:".into()); + for cost in connection_costs { + let pattern = branch_pattern(cost); + let constraint = connection_constraints + .iter() + .find(|c| c.get("node") == cost.get("node") && branch_pattern(c) == pattern) + .and_then(|c| c.get("constraint")); + let estimate = cost.get("costEstimate").cloned().unwrap_or_default(); + lines.push(format!(" {}:", text(cost, "node"))); + lines.extend(cost_lines(&estimate, cost)); + lines.push(format!( + " constraints={}", + format_constraint(constraint) + )); + let filters = cost + .get("filters") + .and_then(|f| Condition::from_json(f).ok()); + lines.push(format!( + " filters={}", + filters.as_ref().map_or("none".into(), format_filter) + )); + lines.push(format!( + " ordering={}", + format_ordering(cost.get("ordering")) + )); + } + } + let joins = node_events("node-cost", "join"); + if !joins.is_empty() { + lines.push(" Joins:".into()); + for cost in joins { + let join_type = cost + .get("joinType") + .and_then(Value::as_str) + .filter(|t| !t.is_empty()) + .map_or(String::new(), |t| format!(" ({t})")); + let estimate = cost.get("costEstimate").cloned().unwrap_or_default(); + lines.push(format!(" {}{join_type}:", text(cost, "node"))); + lines.extend(cost_lines(&estimate, cost)); + } + } + let complete = events.iter().find(|e| ty(e) == "plan-complete"); + let failed = events.iter().find(|e| ty(e) == "plan-failed"); + if let Some(c) = complete { + lines.push(format!( + " ✓ Plan complete: total cost = {}", + to_fixed(num(c, "totalCost"), 2) + )); + } else if let Some(f) = failed { + lines.push(format!(" ✗ Plan failed: {}", text(f, "reason"))); + } + lines +} + +fn cost_lines(estimate: &Value, cost: &Value) -> [String; 3] { + let limit = match estimate.get("limit").and_then(Value::as_f64) { + Some(l) => number::format(l), + None => "none".into(), + }; + [ + format!( + " cost={}, startup={}, scan={}", + to_fixed(num(estimate, "cost"), 2), + to_fixed(num(estimate, "startupCost"), 2), + to_fixed(num(estimate, "scanEst"), 2) + ), + format!( + " rows={}, selectivity={}, limit={limit}", + to_fixed(num(estimate, "returnedRows"), 2), + to_fixed(num(estimate, "selectivity"), 8) + ), + format!( + " downstreamChildSelectivity={}", + to_fixed(num(cost, "downstreamChildSelectivity"), 8) + ), + ] +} + +/// `branchPattern.join(',')`. +fn branch_pattern(e: &Value) -> String { + e.get("branchPattern") + .and_then(Value::as_array) + .map(|a| { + a.iter() + .map(|n| n.as_f64().map_or(String::new(), number::format)) + .collect::>() + .join(",") + }) + .unwrap_or_default() +} + +fn format_constraint(constraint: Option<&Value>) -> String { + match constraint.and_then(Value::as_object) { + Some(o) if !o.is_empty() => { + let keys: Vec<&str> = o.keys().map(String::as_str).collect(); + format!("{{{}}}", keys.join(", ")) + } + _ => "{}".into(), + } +} + +fn format_value_position(v: &ValuePosition) -> String { + match v { + ValuePosition::Column(name) => name.clone(), + ValuePosition::Json { column, path } => format_json_path(column, path), + ValuePosition::Literal(Value::String(s)) => format!("'{s}'"), + ValuePosition::Literal(l) => json::stringify(l), + ValuePosition::Static { anchor, field } => { + let field = match field { + crate::ast::StaticField::Single(f) => f.clone(), + crate::ast::StaticField::Path(p) => p.join("."), + }; + format!("@{}.{field}", anchor.as_str()) + } + } +} + +fn format_filter(c: &Condition) -> String { + match c { + Condition::Simple { op, left, right } => format!( + "{} {} {}", + format_value_position(left), + op.as_str(), + format_value_position(right) + ), + Condition::And(cs) => format!( + "({})", + cs.iter() + .map(format_filter) + .collect::>() + .join(" AND ") + ), + Condition::Or(cs) => format!( + "({})", + cs.iter() + .map(format_filter) + .collect::>() + .join(" OR ") + ), + Condition::CorrelatedSubquery { related, .. } => { + format!("EXISTS({})", related.subquery.table) + } + } +} + +fn format_ordering(ordering: Option<&Value>) -> String { + let parts: Vec = ordering + .and_then(Value::as_array) + .map(|a| { + a.iter() + .map(|p| { + let field = p.at(0).and_then(Value::as_str).unwrap_or_default(); + let dir = p.at(1).and_then(Value::as_str).unwrap_or_default(); + format!("{field} {dir}") + }) + .collect() + }) + .unwrap_or_default(); + if parts.is_empty() { + return "none".into(); + } + parts.join(", ") +} + +/// `Number.prototype.toString(2)` of an integer; other numbers as +/// `toString()`, which the planner never numbers attempts with. +fn binary(n: f64) -> String { + if n.is_finite() && n == n.trunc() && n.abs() < 9_007_199_254_740_992.0 { + let s = format!("{:b}", n.abs() as u64); + return if n < 0.0 { format!("-{s}") } else { s }; + } + number::format(n) +} + +/// `Number.prototype.toFixed(digits)`: the exact value rounded half up. +pub(crate) fn to_fixed(x: f64, digits: usize) -> String { + if x.is_nan() { + return "NaN".into(); + } + if x.abs() >= 1e21 { + return number::format(x); + } + if x < 0.0 { + let s = to_fixed(-x, digits); + return format!("-{s}"); + } + // -0 is not below 0, and prints as 0. + let x = if x == 0.0 { 0.0 } else { x }; + // A double's exact expansion has at most 1074 fraction digits. + let exact = format!("{:.1075}", x); + let (int, frac) = exact.split_once('.').expect("a fraction"); + let mut kept: Vec = int.bytes().chain(frac.bytes().take(digits)).collect(); + if frac.as_bytes()[digits] >= b'5' { + let mut i = kept.len(); + loop { + if i == 0 { + kept.insert(0, b'1'); + break; + } + i -= 1; + if kept[i] == b'9' { + kept[i] = b'0'; + } else { + kept[i] += 1; + break; + } + } + } + let split = kept.len() - digits; + let (int, frac) = kept.split_at(split); + let int = std::str::from_utf8(int).expect("digits"); + if digits == 0 { + return int.to_owned(); + } + format!("{int}.{}", std::str::from_utf8(frac).expect("digits")) +} + +#[cfg(test)] +mod tests { + use super::to_fixed; + + #[test] + fn to_fixed_rounds_the_exact_value_half_up() { + assert_eq!(to_fixed(0.125, 2), "0.13"); + assert_eq!(to_fixed(1.005, 2), "1.00"); + assert_eq!(to_fixed(9.995, 2), "9.99"); + assert_eq!(to_fixed(99.996, 2), "100.00"); + assert_eq!(to_fixed(-0.001, 2), "-0.00"); + assert_eq!(to_fixed(-0.0, 2), "0.00"); + assert_eq!(to_fixed(0.5, 0), "1"); + assert_eq!(to_fixed(1e21, 2), "1e+21"); + assert_eq!(to_fixed(0.3, 8), "0.30000000"); + } +} diff --git a/rust/zero-client/src/client/query_context.rs b/rust/zero-client/src/client/query_context.rs index 7b823fb507..5293a11941 100644 --- a/rust/zero-client/src/client/query_context.rs +++ b/rust/zero-client/src/client/query_context.rs @@ -7,13 +7,16 @@ use super::engine::BatchViewUpdates; use super::ivm_branch::IvmBranch; use super::log::Log; -use super::query_manager::{Got, GotCallback, closed_error}; +use super::measure_push::MeasurePush; +use super::query_manager::{ClientMetric, Got, GotCallback, MetricsDelegate, closed_error}; use super::replica_store::KvDiff; use super::{ConnectionError, Deferred, Error, QueryError}; +use crate::ast::Ast; use crate::builder::{BuilderDelegate, OptimisticAggregate, build_pipeline, group_view_input}; use crate::hash::query::{hash_of_ast, hash_of_name_and_args}; use crate::ivm::{ - ArrayView, DeferredInput, Input, PipelineError, ResultType, Row, Source, ViewValue, capture, + ArrayView, DeferredInput, Input, PipelineError, ResultType, Row, Source, SourceInput, + ViewValue, capture, }; use crate::map::OrderedMap; use crate::protocol::ErroredQuery; @@ -30,6 +33,8 @@ struct BranchDelegate { /// The synced client reads aggregates from the rows the server streams; /// a mutator's query the server hasn't answered computes them. aggregates_from_source: bool, + /// Times the pushes of each source connection, for the inspector. + metrics: Option>, } impl BuilderDelegate for BranchDelegate { @@ -57,10 +62,18 @@ impl BuilderDelegate for BranchDelegate { fn aggregate_key_columns(&self, table: &str, columns: &[String]) -> Vec { self.branch.server_column_names(table, columns) } + + fn decorate_source_input(&self, input: Rc, query_id: &str) -> Rc { + match &self.metrics { + Some(m) => MeasurePush::new(input, query_id, m.clone()), + None => input, + } + } } /// Registers a named query with the server; returns its unregister. -pub(crate) type AddCustomQuery = Box Box>; +pub(crate) type AddCustomQuery = + Box Box>; pub(crate) type UpdateCustomQuery = Rc; pub(crate) type Microtask = Rc)>; /// Builds a deferred pipeline; returns the release to call once every @@ -101,6 +114,8 @@ pub(crate) struct QueryContext { /// Why pushing into the branch failed, once it has (`#advanceError` in /// `ivm-branch.ts`): the branch is unusable from then on. branch_failure: RefCell>, + /// Where materializations are timed: none for a mutator's queries. + metrics: Option>, } /// The settled state of a view's query: still waiting, confirmed by the @@ -121,6 +136,16 @@ struct Track { on_resolved: Option>, view: Weak, destroyed: bool, + /// For the end-to-end materialization metric. + timing: Option>, +} + +/// When and what a view started materializing, for its metrics. +struct ViewTiming { + metrics: Rc, + t0: f64, + query_id: String, + ast: Ast, } type TrackRef = Rc>; @@ -140,15 +165,23 @@ fn settle(track: &TrackRef, r: Completion) { } fn maybe_resolve_complete(track: &TrackRef) { - let resolve = { + let (resolve, timing) = { let mut t = track.borrow_mut(); let ok = t.attached && t.got == Got::Yes && matches!(t.query_complete, Completion::Pending); if ok { t.query_complete = Completion::Complete; } - ok + (ok, t.timing.clone()) }; if resolve { + if let Some(t) = timing { + t.metrics.add_metric( + ClientMetric::MaterializationEndToEnd, + t.metrics.monotonic_now() - t.t0, + &t.query_id, + Some(&t.ast), + ); + } settle(track, Completion::Complete); } } @@ -230,12 +263,14 @@ impl QueryContext { closed_reason: Box Option>, aggregates_from_source: bool, batch_view_updates: Option, + metrics: Option>, ) -> Rc { Rc::new_cyclic(|me| QueryContext { me: me.clone(), delegate: Rc::new(BranchDelegate { branch: branch.clone(), aggregates_from_source, + metrics: metrics.clone(), }), branch, add_custom_query, @@ -251,6 +286,7 @@ impl QueryContext { notifications: Rc::default(), branch_failure: RefCell::new(None), batch_view_updates, + metrics, }) } @@ -259,13 +295,14 @@ impl QueryContext { pub(crate) fn local(branch: Rc, aggregates_from_source: bool) -> Rc { let context = QueryContext::new( branch, - Box::new(|_, _, _| Box::new(|| {})), + Box::new(|_, _, _, _| Box::new(|| {})), Rc::new(|_, _| {}), Rc::new(|f| f()), None, Box::new(|| None), aggregates_from_source, None, + None, ); context.mark_pipelines_ready(); context @@ -452,6 +489,14 @@ impl QueryContext { on_resolved: None, view: Weak::new(), destroyed: false, + timing: self.metrics.as_ref().map(|m| { + Rc::new(ViewTiming { + metrics: m.clone(), + t0: m.monotonic_now(), + query_id: query_id.clone(), + ast: ast.clone(), + }) + }), })); let got_callback: GotCallback = { let track = track.clone(); @@ -480,7 +525,7 @@ impl QueryContext { }) }; let remove_added_query: Rc = match &custom_query_id { - Some(id) => Rc::from((self.add_custom_query)(id, ttl, got_callback)), + Some(id) => Rc::from((self.add_custom_query)(id, &ast, ttl, got_callback)), None => Rc::new(|| {}), }; let built = (|| -> Result { @@ -539,6 +584,17 @@ impl QueryContext { return Err(e.into()); } }; + let timing = track.borrow().timing.clone(); + if deferred.is_none() + && let Some(t) = &timing + { + t.metrics.add_metric( + ClientMetric::MaterializationClient, + t.metrics.monotonic_now() - t.t0, + &query_id, + None, + ); + } if matches!(complete, Completion::Pending) { let weak = Rc::downgrade(&created); let microtask = microtask.clone(); @@ -611,6 +667,7 @@ impl QueryContext { if deferred.destroyed() { return Ok(Box::new(|| {})); } + let t1 = timing.as_ref().map(|t| t.metrics.monotonic_now()); if let Some(v) = weak.upgrade() { v.hold_data(); } @@ -625,6 +682,10 @@ impl QueryContext { settle(&track, Completion::Failed(e)); return Err(error); } + let hydrate_ms = timing + .as_ref() + .zip(t1) + .map(|(t, t1)| (t.clone(), t.metrics.monotonic_now() - t1)); Ok(Box::new(move || { if track.borrow().destroyed { return; @@ -633,6 +694,14 @@ impl QueryContext { if let Some(v) = weak.upgrade() { v.release_data(); } + if let Some((t, ms)) = hydrate_ms { + t.metrics.add_metric( + ClientMetric::MaterializationClient, + ms, + &t.query_id, + None, + ); + } maybe_resolve_complete(&track); maybe_mark_cached(&track); })) @@ -761,6 +830,7 @@ impl QueryContext { let (c, p) = (cached.clone(), complete.clone()); let cleanup = (self.add_custom_query)( id, + query.ast(), ttl, Rc::new(move |got, error| { if let Some(error) = error { diff --git a/rust/zero-client/src/client/query_manager.rs b/rust/zero-client/src/client/query_manager.rs index 13a5473fa8..9254449b84 100644 --- a/rust/zero-client/src/client/query_manager.rs +++ b/rust/zero-client/src/client/query_manager.rs @@ -2,10 +2,14 @@ //! about changes in batches, and reports which ones the server has sent //! (`packages/zero-client/src/client/query-manager.ts`). +use super::inspector::{Metrics, QueryClientMetrics}; +use super::log::Log; use super::replica_store::{KvDiff, KvDiffOp, KvMap}; use super::{ConnectionError, Scheduler, Timer}; +use crate::ast::Ast; +use crate::decode::JsonCodable; use crate::hash::query::hash_of_name_and_args; -use crate::json::{Object, Value}; +use crate::json::{self, Object, Value, number}; use crate::keys::{DESIRED_QUERIES_PREFIX, GOT_QUERIES_PREFIX}; use crate::map::OrderedMap; use crate::protocol::{ @@ -13,9 +17,35 @@ use crate::protocol::{ }; use crate::ttl::Ttl; use std::cell::{Cell, RefCell}; -use std::collections::HashSet; +use std::collections::{HashMap, HashSet}; use std::rc::{Rc, Weak}; +/// Client query updates are timed for only the first of every +/// `UPDATE_SAMPLE_RATE` pushes to each source connection (see +/// `MeasurePush`), so each `query-update-client` time is recorded with this +/// weight (`UPDATE_SAMPLE_RATE` in `query-manager.ts`). +pub(crate) const UPDATE_SAMPLE_RATE: u64 = 32; + +/// The metrics the client records (`ClientMetricMap` in +/// `packages/zql/src/query/metrics-delegate.ts`). +#[derive(Clone, Copy, Debug, PartialEq, Eq)] +pub(crate) enum ClientMetric { + /// `query-materialization-client`: building and hydrating a view. + MaterializationClient, + /// `query-materialization-end-to-end`: from materializing a query + /// until the server has sent its rows. + MaterializationEndToEnd, + /// `query-update-client`: a push through a query's pipeline. + UpdateClient, +} + +/// Where a query context reports its metrics, and the clock it times them +/// on (`MetricsDelegate`). +pub(crate) trait MetricsDelegate { + fn monotonic_now(&self) -> f64; + fn add_metric(&self, metric: ClientMetric, value: f64, query_id: &str, ast: Option<&Ast>); +} + /// What a query's got callback hears: whether the server has confirmed the /// query's rows on this connection (`Yes`), on an earlier one (`Cached`), /// or not (`No`). @@ -29,6 +59,8 @@ pub(crate) enum Got { pub(crate) type GotCallback = Rc)>; struct Entry { + /// The query's AST, for the inspector. + ast: Ast, name: String, args: Vec, count: usize, @@ -63,6 +95,25 @@ pub(crate) struct QueryManager { recent_queries_max_size: usize, state: RefCell, next_callback_id: Cell, + log: Log, + slow_materialize_threshold_ms: f64, + /// Every query's metrics together. + metrics: RefCell, + query_metrics: RefCell>, + /// The ASTs and metrics of the queries evicted since the inspector was + /// first asked for: `None` until then (the inspector's + /// `setQueryEvictedCallback`). + evicted: RefCell>>, +} + +impl MetricsDelegate for QueryManager { + fn monotonic_now(&self) -> f64 { + self.scheduler.monotonic_now() + } + + fn add_metric(&self, metric: ClientMetric, value: f64, query_id: &str, ast: Option<&Ast>) { + QueryManager::add_metric(self, metric, value, query_id, ast) + } } impl QueryManager { @@ -72,6 +123,8 @@ impl QueryManager { query_change_throttle_ms: f64, send: Box, pending_mutations: Box usize>, + log: Log, + slow_materialize_threshold_ms: f64, ) -> Rc { Rc::new_cyclic(|me| QueryManager { me: me.clone(), @@ -86,9 +139,98 @@ impl QueryManager { ..State::default() }), next_callback_id: Cell::new(0), + log, + slow_materialize_threshold_ms, + metrics: RefCell::default(), + query_metrics: RefCell::default(), + evicted: RefCell::new(None), }) } + /// Every query's client metrics together (`metrics`). + pub(crate) fn metrics(&self) -> Metrics { + self.metrics.borrow().clone() + } + + /// The client metrics of query `id`, if it has any, evicted or not + /// (`getQueryMetrics`). + pub(crate) fn query_metrics(&self, id: &str) -> Option { + if let Some(m) = self.query_metrics.borrow().get(id) { + return Some(m.clone()); + } + let evicted = self.evicted.borrow(); + evicted.as_ref()?.get(id).map(|(_, m)| m.clone()) + } + + /// The AST of query `id`, evicted or not (`getAST`). + pub(crate) fn query_ast(&self, id: &str) -> Option { + if let Some(e) = self.state.borrow().queries.get(id) { + return Some(e.borrow().ast.clone()); + } + let evicted = self.evicted.borrow(); + evicted.as_ref()?.get(id).map(|(a, _)| a.clone()) + } + + /// Keeps the ASTs and metrics of the queries evicted from now on, as + /// JS does once its inspector exists. + pub(crate) fn keep_evicted(&self) { + self.evicted.borrow_mut().get_or_insert_with(HashMap::new); + } + + /// `addMetric`: records a metric of query `query_id`, client-wide and + /// for the query, and logs each end-to-end materialization, as a + /// warning past `slow_materialize_threshold_ms`. + pub(crate) fn add_metric( + &self, + metric: ClientMetric, + value: f64, + query_id: &str, + ast: Option<&Ast>, + ) { + let weight = if metric == ClientMetric::UpdateClient { + UPDATE_SAMPLE_RATE as f64 + } else { + 1.0 + }; + { + let mut m = self.metrics.borrow_mut(); + let digest = match metric { + ClientMetric::MaterializationClient => &mut m.query_materialization_client, + ClientMetric::MaterializationEndToEnd => &mut m.query_materialization_end_to_end, + ClientMetric::UpdateClient => &mut m.query_update_client, + }; + digest.add(value, weight); + } + if metric == ClientMetric::MaterializationEndToEnd { + let message = |m: &str| { + let ast = ast.map_or("undefined".to_owned(), |a| json::stringify(&a.to_json())); + format!("{m} {query_id} {ast} {}", number::format(value)) + }; + if value > self.slow_materialize_threshold_ms { + self.log + .warn(|| message("Slow query materialization (including server/network)")); + } else { + self.log + .debug(|| message("Materialized query (including server/network)")); + } + } + let mut per_query = self.query_metrics.borrow_mut(); + let existing = match per_query.get_mut(query_id) { + Some(e) => e, + None => per_query.entry(query_id.to_owned()).or_default(), + }; + match metric { + ClientMetric::UpdateClient => existing.query_update_client.add(value, weight), + // Recorded once per query: the last value wins. + ClientMetric::MaterializationClient => { + existing.query_materialization_client = Some(value) + } + ClientMetric::MaterializationEndToEnd => { + existing.query_materialization_end_to_end = Some(value) + } + } + } + /// Every mutation the server had to confirm is confirmed: the removals /// held back meanwhile happen now. pub(crate) fn on_all_mutations_applied(&self) { @@ -259,6 +401,7 @@ impl QueryManager { /// Registers a named query. Returns the function that unregisters it. pub(crate) fn add_custom( &self, + ast: &Ast, name: &str, args: &[Value], ttl: &Ttl, @@ -288,6 +431,7 @@ impl QueryManager { } None => { let entry = Rc::new(RefCell::new(Entry { + ast: ast.clone(), name: name.to_owned(), args: args.to_vec(), count: 1, @@ -415,8 +559,15 @@ impl QueryManager { if s.recent_queries.len() > self.recent_queries_max_size { let lru = s.recent_queries.get_index(0).map(|(k, _)| k.clone()); if let Some(lru) = &lru { - s.queries.remove(lru); + let evicted = s.queries.remove(lru); s.recent_queries.remove(lru); + let metrics = self.query_metrics.borrow_mut().remove(lru); + if let (Some(kept), Some(e)) = (self.evicted.borrow_mut().as_mut(), evicted) { + kept.insert( + lru.clone(), + (e.borrow().ast.clone(), metrics.unwrap_or_default()), + ); + } } lru } else { diff --git a/rust/zero-client/src/client/zero.rs b/rust/zero-client/src/client/zero.rs index b120c918a3..149d8ceff7 100644 --- a/rust/zero-client/src/client/zero.rs +++ b/rust/zero-client/src/client/zero.rs @@ -4,6 +4,7 @@ use super::connection_manager::ConnectionState; use super::database::{ReplicaDatabase, replicache_name}; use super::engine::{Engine, MutatorFn, MutatorResult, UpdateNeededReason, ZeroOptions}; +use super::inspector::{Inspector, InspectorHost}; use super::query_context::{MaterializedView, Preload, RunType, WeakView}; use super::storage::DroppedDatabases; use super::transaction::Transaction; @@ -104,6 +105,8 @@ struct Core { connection: Connection, views: RefCell>, preloads: RefCell>>, + /// What the client's inspectors share, once there is one. + inspector: RefCell>>, } /// A preload, which a replacement starts again on the new engine until @@ -171,6 +174,7 @@ impl Zero { connection, views: RefCell::default(), preloads: RefCell::default(), + inspector: RefCell::default(), }); Core::attach(&core, &engine); Ok(Zero { core, context }) @@ -276,6 +280,32 @@ impl Zero { } } + /// The inspector (`zero.inspector`): the client's queries and metrics + /// and what zero-cache knows of them, for debugging and tooling. + pub fn inspector(&self) -> Inspector { + let host = self + .core + .inspector + .borrow_mut() + .get_or_insert_with(|| { + let core = Rc::downgrade(&self.core); + Rc::new(InspectorHost { + engine: Box::new(move || core.upgrade().map(|c| c.engine())), + schema: self.core.schema.clone(), + admin_password: RefCell::new(None), + }) + }) + .clone(); + // Evicted queries are kept for it from now on. + self.engine().query_manager.keep_evicted(); + Inspector { + host, + context: self.context.clone(), + client_id: self.client_id(), + client_group_id: self.client_group_id(), + } + } + /// Runs a mutator on the client now and sends it to the server. A /// mutator not registered with this client doesn't run: both outcomes /// are a `ZeroError` saying so. JS throws that error instead. diff --git a/rust/zero-client/src/ivm/operator.rs b/rust/zero-client/src/ivm/operator.rs index ecfeac4e25..108b51876e 100644 --- a/rust/zero-client/src/ivm/operator.rs +++ b/rust/zero-client/src/ivm/operator.rs @@ -112,6 +112,12 @@ pub trait Output { fn push(&self, change: Change, pusher: &dyn InputBase); /// Phase two. Sinks can ignore it; operators must forward it. fn reconcile(&self, _pusher: &dyn InputBase) {} + /// Whether the output has a phase two: false for a sink whose JS + /// counterpart has no `reconcile`, such as a view, which pushes timed + /// for the inspector skip (`MeasurePushOperator`). + fn has_reconcile(&self) -> bool { + true + } } /// An operator in a pipeline: an input to the next and an output of the diff --git a/rust/zero-client/src/ivm/view.rs b/rust/zero-client/src/ivm/view.rs index ccd5540f79..d27650d0c3 100644 --- a/rust/zero-client/src/ivm/view.rs +++ b/rust/zero-client/src/ivm/view.rs @@ -710,4 +710,8 @@ impl Output for ArrayView { s.dirty = true; } } + + fn has_reconcile(&self) -> bool { + false + } } diff --git a/rust/zero-client/src/lib.rs b/rust/zero-client/src/lib.rs index a0d0196501..20f4c3ea1c 100644 --- a/rust/zero-client/src/lib.rs +++ b/rust/zero-client/src/lib.rs @@ -112,6 +112,8 @@ pub mod schema; pub mod sort; pub mod strings; #[warn(missing_docs)] +pub mod tdigest; +#[warn(missing_docs)] pub mod testing; #[cfg(feature = "tokio-transport")] #[warn(missing_docs)] diff --git a/rust/zero-client/src/tdigest.rs b/rust/zero-client/src/tdigest.rs new file mode 100644 index 0000000000..a8eb454b7a --- /dev/null +++ b/rust/zero-client/src/tdigest.rs @@ -0,0 +1,492 @@ +//! A t-digest, for the inspector's percentiles (`TDigest` in +//! `packages/shared/src/tdigest.ts`, itself a port of +//! , Apache License 2.0). +//! +//! The port does the same arithmetic in the same order as JS, so a digest +//! fed the same values gives JS's quantiles exactly, and reads and writes +//! the same JSON: `[compression, mean, weight, mean, weight, ...]`, which is +//! how zero-cache sends its metrics. + +use crate::json::Value; +use std::cell::RefCell; + +/// Initial capacity of the buffer of unprocessed values. +const INITIAL_CAPACITY: usize = 16; + +/// A digest of a distribution of numbers, for its quantiles: it keeps +/// roughly `compression` centroids, and buffers up to eight times as many +/// values between merges. +/// +/// Reading it (`quantile`, `count`, `to_json`, ...) merges the buffered +/// values first, as in JS, so those take `&self`. +#[derive(Clone, Debug)] +pub struct TDigest { + compression: f64, + max_unprocessed: f64, + state: RefCell, +} + +#[derive(Clone, Debug)] +struct State { + /// Means of the processed centroids, ascending. + means: Vec, + /// Weights of the processed centroids, parallel to `means`. + weights: Vec, + /// The values added since the last `process`, in order. + unprocessed_means: Vec, + unprocessed_weights: Vec, + cumulative: Vec, + processed_weight: f64, + unprocessed_weight: f64, + min: f64, + max: f64, +} + +impl Default for TDigest { + /// A digest of compression 100, JS's default. + fn default() -> Self { + TDigest::new(100.0) + } +} + +impl PartialEq for TDigest { + /// Digests are equal when their JSON forms are. + fn eq(&self, other: &Self) -> bool { + self.to_vec() == other.to_vec() + } +} + +/// `Math.max`: NaN if either is, and +0 over -0. +fn js_max(a: f64, b: f64) -> f64 { + if a.is_nan() || b.is_nan() { + return f64::NAN; + } + if a == b { + return if a.is_sign_negative() { b } else { a }; + } + if a > b { a } else { b } +} + +/// `Math.min`: NaN if either is, and -0 over +0. +fn js_min(a: f64, b: f64) -> f64 { + if a.is_nan() || b.is_nan() { + return f64::NAN; + } + if a == b { + return if a.is_sign_negative() { a } else { b }; + } + if a < b { a } else { b } +} + +/// `binarySearch` in `packages/shared/src/binary-search.ts`. +fn binary_search(mut high: usize, compare: impl Fn(usize) -> f64) -> usize { + let mut low = 0; + while low < high { + let mid = low + ((high - low) >> 1); + let i = compare(mid); + if i == 0.0 { + return mid; + } + if i > 0.0 { + low = mid + 1; + } else { + high = mid; + } + } + low +} + +fn weighted_average(x1: f64, w1: f64, x2: f64, w2: f64) -> f64 { + if x1 <= x2 { + weighted_average_sorted(x1, w1, x2, w2) + } else { + weighted_average_sorted(x2, w2, x1, w1) + } +} + +fn weighted_average_sorted(x1: f64, w1: f64, x2: f64, w2: f64) -> f64 { + let x = (x1 * w1 + x2 * w2) / (w1 + w2); + js_max(x1, js_min(x, x2)) +} + +impl TDigest { + /// An empty digest. JS's default compression, 100, keeps p50, p95 and + /// p99 within about 0.5%. + pub fn new(compression: f64) -> Self { + let max_unprocessed = compression.ceil() * 8.0; + let capacity = if max_unprocessed + 1.0 < INITIAL_CAPACITY as f64 { + (max_unprocessed + 1.0).max(0.0) as usize + } else { + INITIAL_CAPACITY + }; + TDigest { + compression, + max_unprocessed, + state: RefCell::new(State { + means: Vec::new(), + weights: Vec::new(), + unprocessed_means: Vec::with_capacity(capacity), + unprocessed_weights: Vec::with_capacity(capacity), + cumulative: Vec::new(), + processed_weight: 0.0, + unprocessed_weight: 0.0, + min: f64::MAX, + max: -f64::MAX, + }), + } + } + + /// The digest of its JSON form, `[compression, mean, weight, ...]` + /// (`TDigest.fromJSON`). + pub fn from_json(data: &[f64]) -> Result { + let mut digest = TDigest::new(data.first().copied().unwrap_or(100.0)); + if data.len() % 2 != 1 { + return Err("Invalid centroids array".into()); + } + for pair in data[1..].chunks(2) { + digest.add(pair[0], pair[1]); + } + Ok(digest) + } + + /// [`from_json`](Self::from_json) of a JSON value: an array of numbers. + pub fn from_json_value(v: &Value) -> Result { + let Some(a) = v.as_array() else { + return Err("Expected a TDigest array".into()); + }; + let numbers: Option> = a.iter().map(Value::as_f64).collect(); + let numbers = numbers.ok_or("Expected a TDigest array of numbers")?; + TDigest::from_json(&numbers) + } + + /// The compression the digest was made with. + pub fn compression(&self) -> f64 { + self.compression + } + + /// Empties the digest. + pub fn reset(&mut self) { + let s = self.state.get_mut(); + s.means.clear(); + s.weights.clear(); + s.unprocessed_means.clear(); + s.unprocessed_weights.clear(); + s.cumulative.clear(); + s.processed_weight = 0.0; + s.unprocessed_weight = 0.0; + s.min = f64::MAX; + s.max = -f64::MAX; + } + + /// Adds a value with a weight (1 in JS by default). A weight that isn't + /// positive and finite is ignored, as is a NaN mean. + pub fn add(&mut self, mean: f64, weight: f64) { + if mean.is_nan() || weight <= 0.0 || !weight.is_finite() { + return; + } + let process = { + let s = self.state.get_mut(); + s.unprocessed_means.push(mean); + s.unprocessed_weights.push(weight); + s.unprocessed_weight += weight; + s.unprocessed_means.len() as f64 > self.max_unprocessed + }; + if process { + Self::process(self.compression, self.state.get_mut()); + } + } + + /// Adds each of `other`'s centroids (`merge`). + pub fn merge(&mut self, other: &TDigest) { + let (means, weights) = { + let mut s = other.state.borrow_mut(); + Self::process(other.compression, &mut s); + (s.means.clone(), s.weights.clone()) + }; + for (m, w) in means.into_iter().zip(weights) { + self.add(m, w); + } + } + + /// The processed centroids, as `(mean, weight)`, ascending. + pub fn centroids(&self) -> Vec<(f64, f64)> { + let s = self.processed(); + s.means + .iter() + .copied() + .zip(s.weights.iter().copied()) + .collect() + } + + /// The total weight of the values added. + pub fn count(&self) -> f64 { + self.processed().processed_weight + } + + /// The JSON form, `[compression, mean, weight, ...]` (`toJSON`). + pub fn to_vec(&self) -> Vec { + let s = self.processed(); + let mut data = Vec::with_capacity(1 + 2 * s.means.len()); + data.push(self.compression); + for (m, w) in s.means.iter().zip(&s.weights) { + data.push(*m); + data.push(*w); + } + data + } + + /// [`to_vec`](Self::to_vec) as a JSON value. + pub fn to_json(&self) -> Value { + Value::Array(self.to_vec().into_iter().map(Value::Number).collect()) + } + + fn processed(&self) -> std::cell::RefMut<'_, State> { + let mut s = self.state.borrow_mut(); + Self::process(self.compression, &mut s); + s + } + + /// Merges the unprocessed values into the centroids: walks both in + /// order of mean, folding each into the last centroid while that stays + /// within its size limit, and starting a new centroid otherwise. + fn process(compression: f64, s: &mut State) { + if s.unprocessed_means.is_empty() { + return; + } + let (new_means, new_weights) = sorted_unprocessed(s); + s.unprocessed_means.clear(); + s.unprocessed_weights.clear(); + let n = new_means.len(); + let p = s.means.len(); + s.processed_weight += s.unprocessed_weight; + s.unprocessed_weight = 0.0; + let total = s.processed_weight; + + let mut means = Vec::with_capacity(p + 1); + let mut weights = Vec::with_capacity(p + 1); + let mut mean = 0.0; + let mut weight = 0.0; + let mut so_far = 0.0; + let mut limit = 0.0; + let (mut i, mut j) = (0, 0); + while i < n || j < p { + // On a tie the new value goes first. + let (m, w); + if i < n && (j == p || new_means[i] <= s.means[j]) { + m = new_means[i]; + w = new_weights[i]; + i += 1; + } else { + m = s.means[j]; + w = s.weights[j]; + j += 1; + } + if so_far + w <= limit { + weight += w; + mean += (w * (m - mean)) / weight; + } else { + if weight > 0.0 { + means.push(mean); + weights.push(weight); + } + let k = integrated_location(compression, so_far / total); + limit = total * integrated_q(compression, k + 1.0); + mean = m; + weight = w; + } + so_far += w; + } + means.push(mean); + weights.push(weight); + + s.min = js_min(s.min, means[0]); + s.max = js_max(s.max, *means.last().expect("a centroid")); + s.means = means; + s.weights = weights; + } + + fn update_cumulative(s: &mut State) { + // Weight only increases, so an unchanged total means nothing + // changed since the last update. + if s.cumulative.last() == Some(&s.processed_weight) { + return; + } + s.cumulative.resize(s.means.len() + 1, 0.0); + let mut prev = 0.0; + for i in 0..s.means.len() { + let cur = s.weights[i]; + s.cumulative[i] = prev + cur / 2.0; + prev += cur; + } + let n = s.means.len(); + s.cumulative[n] = prev; + } + + /// The (approximate) value at quantile `q`, between 0 and 1. NaN when + /// the digest is empty or `q` is out of range. + pub fn quantile(&self, q: f64) -> f64 { + let mut s = self.processed(); + Self::update_cumulative(&mut s); + if q < 0.0 || q > 1.0 || s.means.is_empty() { + return f64::NAN; + } + if s.means.len() == 1 { + return s.means[0]; + } + if q.is_nan() { + // JS reads past the arrays and gets NaN. + return f64::NAN; + } + let index = q * s.processed_weight; + if index <= s.weights[0] / 2.0 { + return s.min + ((2.0 * index) / s.weights[0]) * (s.means[0] - s.min); + } + let lower = binary_search(s.cumulative.len(), |i| -s.cumulative[i] + index); + if lower >= s.cumulative.len() { + // The sum of the weights rounded below `index`: JS reads past + // the arrays and gets NaN. + return f64::NAN; + } + if lower + 1 != s.cumulative.len() { + let z1 = index - s.cumulative[lower - 1]; + let z2 = s.cumulative[lower] - index; + return weighted_average(s.means[lower - 1], z2, s.means[lower], z1); + } + let z1 = index - s.processed_weight - s.weights[lower - 1] / 2.0; + let z2 = s.weights[lower - 1] / 2.0 - z1; + weighted_average(*s.means.last().expect("a centroid"), z1, s.max, z2) + } + + /// The (approximate) fraction of the values at or below `x`. + pub fn cdf(&self, x: f64) -> f64 { + let mut s = self.processed(); + Self::update_cumulative(&mut s); + match s.means.len() { + 0 => return 0.0, + 1 => { + let width = s.max - s.min; + if x <= s.min { + return 0.0; + } + if x >= s.max { + return 1.0; + } + if x - s.min <= width { + // Too close together to interpolate. + return 0.5; + } + return (x - s.min) / width; + } + _ => {} + } + if x <= s.min { + return 0.0; + } + if x >= s.max { + return 1.0; + } + let m0 = s.means[0]; + if x <= m0 { + if m0 - s.min > 0.0 { + return (((x - s.min) / (m0 - s.min)) * s.weights[0]) / s.processed_weight / 2.0; + } + return 0.0; + } + let mn = *s.means.last().expect("a centroid"); + if x >= mn { + if s.max - mn > 0.0 { + return 1.0 + - (((s.max - x) / (s.max - mn)) * s.weights.last().expect("a centroid")) + / s.processed_weight + / 2.0; + } + return 1.0; + } + // Equal counts as greater, for the upper index. + let upper = binary_search(s.means.len(), |i| { + let d = x - s.means[i]; + if d == 0.0 || d.is_nan() { 1.0 } else { d } + }); + let z1 = x - s.means[upper - 1]; + let z2 = s.means[upper] - x; + weighted_average(s.cumulative[upper - 1], z2, s.cumulative[upper], z1) / s.processed_weight + } +} + +/// The unprocessed means and weights, sorted by mean, as JS sorts them. +fn sorted_unprocessed(s: &State) -> (Vec, Vec) { + let means = &s.unprocessed_means; + let weights = &s.unprocessed_weights; + // `fromJSON` and `merge` add centroids in order of mean. + if means + .windows(2) + .all(|w| w[1].partial_cmp(&w[0]) != Some(std::cmp::Ordering::Less)) + { + return (means.clone(), weights.clone()); + } + // With one weight for every value, a numeric sort of the means alone + // (`Float64Array.prototype.sort`: -0 before +0). + if weights.iter().all(|w| *w == weights[0]) { + let mut sorted = means.clone(); + sorted.sort_by(f64::total_cmp); + return (sorted, weights.clone()); + } + // A stable sort by `means[a] - means[b]`. + let mut order: Vec = (0..means.len()).collect(); + order.sort_by(|&a, &b| { + let d = means[a] - means[b]; + if d < 0.0 { + std::cmp::Ordering::Less + } else if d > 0.0 { + std::cmp::Ordering::Greater + } else { + std::cmp::Ordering::Equal + } + }); + ( + order.iter().map(|&k| means[k]).collect(), + order.iter().map(|&k| weights[k]).collect(), + ) +} + +fn integrated_q(compression: f64, k: f64) -> f64 { + ((js_min(k, compression) * std::f64::consts::PI / compression - std::f64::consts::PI / 2.0) + .sin() + + 1.0) + / 2.0 +} + +fn integrated_location(compression: f64, q: f64) -> f64 { + (compression * ((2.0 * q - 1.0).asin() + std::f64::consts::PI / 2.0)) / std::f64::consts::PI +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn quantiles_of_a_few_values() { + let mut d = TDigest::default(); + assert!(d.quantile(0.5).is_nan()); + for v in [1.0, 2.0, 3.0, 4.0] { + d.add(v, 1.0); + } + assert_eq!(d.count(), 4.0); + assert_eq!(d.quantile(0.0), 1.0); + assert_eq!(d.quantile(1.0), 4.0); + assert_eq!( + d.to_vec(), + vec![100.0, 1.0, 1.0, 2.0, 1.0, 3.0, 1.0, 4.0, 1.0] + ); + let back = TDigest::from_json(&d.to_vec()).unwrap(); + assert_eq!(back, d); + assert!(TDigest::from_json(&[100.0, 1.0]).is_err()); + } + + #[test] + fn js_min_max() { + assert!(js_max(1.0, f64::NAN).is_nan()); + assert!(js_max(-0.0, 0.0).is_sign_positive()); + assert!(js_min(0.0, -0.0).is_sign_negative()); + } +} diff --git a/rust/zero-client/tests/inspector.rs b/rust/zero-client/tests/inspector.rs new file mode 100644 index 0000000000..7c58f5c60d --- /dev/null +++ b/rust/zero-client/tests/inspector.rs @@ -0,0 +1,161 @@ +//! The inspector's RPCs where JS has nothing to compare with (the +//! conformance vectors cover the rest): a request waiting on a connection +//! that drops or a client that closes fails, and a refused request without +//! an accepted password says how to authenticate. + +use std::rc::Rc; +use std::sync::Arc; +use zero_client::client::{Deferred, Zero, ZeroOptions}; +use zero_client::json::{self, Value}; +use zero_client::schema::Schema; +use zero_client::testing::{ManualScheduler, MockSocket, MockSocketFactory, RecordingLogSink}; + +struct Harness { + zero: Zero, + scheduler: Rc, + factory: Rc, +} + +impl Harness { + fn new() -> Self { + let schema = Schema::from_json( + &json::parse( + r#"{"tables": {"issue": {"name": "issue", "primaryKey": ["id"], + "columns": {"id": {"type": "string"}}}}}"#, + ) + .unwrap(), + ) + .unwrap(); + let scheduler = ManualScheduler::new(1_700_000_000_000.0); + let factory = MockSocketFactory::new(); + let options = ZeroOptions { + cache_url: Some("http://zero.test".into()), + user_id: Some("u1".into()), + log_sink: Some(Rc::new(RecordingLogSink::default())), + ..ZeroOptions::default() + }; + let zero = Zero::new( + Arc::new(schema), + (), + vec![], + options, + scheduler.clone(), + Some(factory.clone()), + ) + .unwrap(); + let h = Harness { + zero, + scheduler, + factory, + }; + h.settle(); + h + } + + fn settle(&self) { + self.zero.dispatch(|| {}); + self.scheduler.run_due_timers(); + } + + fn socket(&self) -> Rc { + self.factory.sockets().last().cloned().expect("a socket") + } + + fn connect(&self) { + self.socket().receive_text(r#"["connected",{"wsid":"w1"}]"#); + self.settle(); + } + + /// The last inspector request sent: its `op` and `id`. + fn last_request(&self) -> (String, String) { + let m = self + .socket() + .messages() + .into_iter() + .rev() + .find(|m| m.starts_with(r#"["inspect""#)) + .expect("an inspect request"); + let v = json::parse(&m).unwrap(); + let body = v.at(1).unwrap(); + let s = |k: &str| body.get(k).and_then(Value::as_str).unwrap().to_owned(); + (s("op"), s("id")) + } + + fn answer(&self, id: &str, op: &str, value: &str) { + self.socket().receive_text(&format!( + r#"["inspect",{{"op":"{op}","id":"{id}","value":{value}}}]"# + )); + self.settle(); + } +} + +fn rejection(d: &Deferred) -> String { + match d.result() { + Some(Err(e)) => e.message(), + Some(Ok(_)) => panic!("resolved"), + None => panic!("pending"), + } +} + +#[test] +fn a_sent_request_fails_when_the_connection_drops() { + let h = Harness::new(); + h.connect(); + let version = h.zero.inspector().server_version(); + h.settle(); + assert_eq!(h.last_request().0, "version"); + h.socket().server_close(1006, "", false); + h.settle(); + let message = rejection(&version); + assert!( + message.contains("the connection to zero-cache closed"), + "{message}" + ); +} + +#[test] +fn a_request_waits_for_the_connection_and_fails_when_the_client_closes() { + let h = Harness::new(); + let version = h.zero.inspector().server_version(); + h.settle(); + assert!(!version.is_settled(), "waits for the connection"); + h.zero.close(); + h.settle(); + assert_eq!(rejection(&version), "Zero instance closed by user"); + // And one made once closed fails at once. + let late = h.zero.inspector().metrics(); + h.settle(); + assert_eq!(rejection(&late), "Zero instance closed by user"); +} + +#[test] +fn a_refused_request_says_to_authenticate() { + let h = Harness::new(); + h.connect(); + let version = h.zero.inspector().server_version(); + h.settle(); + let (_, id) = h.last_request(); + h.answer(&id, "authenticated", "false"); + let message = rejection(&version); + assert!(message.starts_with("Authentication failed"), "{message}"); + assert!(message.contains("authenticate(password)"), "{message}"); + + // Once a password is accepted, a refused request presents it again. + let inspector = h.zero.inspector(); + let ok = inspector.authenticate("pw"); + h.settle(); + let (op, id) = h.last_request(); + assert_eq!(op, "authenticate"); + h.answer(&id, "authenticated", "true"); + assert!(matches!(ok.result(), Some(Ok(true)))); + let version = inspector.server_version(); + h.settle(); + h.answer(&h.last_request().1, "authenticated", "false"); + let (op, id) = h.last_request(); + assert_eq!(op, "authenticate"); + h.answer(&id, "authenticated", "true"); + let (op, id) = h.last_request(); + assert_eq!(op, "version"); + h.answer(&id, "version", r#""1.2.3""#); + assert_eq!(version.result().unwrap().unwrap(), "1.2.3"); +} diff --git a/swift/Tests/ConformanceTests/ASTConformanceTests.swift b/swift/Tests/ConformanceTests/ASTConformanceTests.swift index 0eabfe0e49..6254bdc1ab 100644 --- a/swift/Tests/ConformanceTests/ASTConformanceTests.swift +++ b/swift/Tests/ConformanceTests/ASTConformanceTests.swift @@ -62,4 +62,17 @@ struct ASTConformanceTests { #expect(QueryHash.hashOfNameAndArgs(name, args) == c["hash"]!.stringValue!, "\(name) \(args)") } } + /// `astToZQL` (`packages/ast-to-zql/src/ast-to-zql.ts`) of each AST, as + /// the inspector shows a query. Swift has no `redactLiterals`, which only + /// zero-cache uses, so the cases' `redacted` code isn't checked. + @Test func astToZQLCode() throws { + var passed = 0 + for c in try Vectors.cases("ast-to-zql") { + let ast = try AST(json: c["ast"]!) + let code = astToZQL(ast) + #expect(code == c["zql"]?.stringValue, "astToZQL(\(c["ast"]!))") + if code == c["zql"]?.stringValue { passed += 1 } + } + print("[ast-to-zql] \(passed) passed") + } } diff --git a/swift/Tests/ConformanceTests/BugHuntTests.swift b/swift/Tests/ConformanceTests/BugHuntTests.swift index 0791d4c388..cc2b0f8753 100644 --- a/swift/Tests/ConformanceTests/BugHuntTests.swift +++ b/swift/Tests/ConformanceTests/BugHuntTests.swift @@ -13,14 +13,14 @@ import ZeroTesting @MainActor struct BugHuntTests { /// The random client scenarios, all of them: reports the first mismatches. - @Test(.enabled(if: Vectors.generatedAvailable)) func clientFuzzOnMemory() throws { - try Self.runFuzz(storage: .memory) + @Test(.enabled(if: Vectors.generatedAvailable)) func clientFuzzOnMemory() async throws { + try await Self.runFuzz(storage: .memory) } - @Test(.enabled(if: Vectors.generatedAvailable)) func clientFuzzOnSQLite() throws { + @Test(.enabled(if: Vectors.generatedAvailable)) func clientFuzzOnSQLite() async throws { let directory = NSTemporaryDirectory() + "zero-bughunt-" + UUID().uuidString defer { try? FileManager.default.removeItem(atPath: directory) } - try Self.runFuzz(storage: .sqlite(directory: directory)) + try await Self.runFuzz(storage: .sqlite(directory: directory)) } nonisolated static let ivmNames: [String] = @@ -44,37 +44,37 @@ struct BugHuntTests { .compactMap { $0["name"]?.stringValue } /// One targeted client scenario (`vectors/bughunt-client.json`). - @Test(arguments: clientNames) func clientOnMemory(_ name: String) throws { - try Self.runClient(name, storage: .memory) + @Test(arguments: clientNames) func clientOnMemory(_ name: String) async throws { + try await Self.runClient(name, storage: .memory) } - @Test(arguments: clientNames) func clientOnSQLite(_ name: String) throws { + @Test(arguments: clientNames) func clientOnSQLite(_ name: String) async throws { let directory = NSTemporaryDirectory() + "zero-bughunt-" + UUID().uuidString defer { try? FileManager.default.removeItem(atPath: directory) } - try Self.runClient(name, storage: .sqlite(directory: directory)) + try await Self.runClient(name, storage: .sqlite(directory: directory)) } - static func runClient(_ name: String, storage: ZeroStorage) throws { + static func runClient(_ name: String, storage: ZeroStorage) async throws { let file = try Vectors.file("bughunt-client") let startTime = file["shared"]?["startTime"]?.numberValue ?? 0 let scenario = try #require( file["cases"]?.arrayValue?.first { $0["name"]?.stringValue == name }) let runner = try ScenarioRunner(scenario, startTime: startTime, storage: storage) if let mismatch = ClientConformanceTests.firstMismatch( - scenario, scenario["expect"]?.arrayValue ?? [], runner.run()) + scenario, scenario["expect"]?.arrayValue ?? [], await runner.run()) { Issue.record(Comment(rawValue: "\(name)\n\(mismatch)")) } } - static func runFuzz(storage: ZeroStorage) throws { + static func runFuzz(storage: ZeroStorage) async throws { let file = try Vectors.generatedFile("client-aggregates-fuzz") let startTime = file["shared"]?["startTime"]?.numberValue ?? 0 var failed: [String] = [] for scenario in file["cases"]?.arrayValue ?? [] { let name = scenario["name"]?.stringValue ?? "?" let runner = try ScenarioRunner(scenario, startTime: startTime, storage: storage) - let actual = runner.run() + let actual = await runner.run() if let mismatch = ClientConformanceTests.firstMismatch( scenario, scenario["expect"]?.arrayValue ?? [], actual) { diff --git a/swift/Tests/ConformanceTests/ClientConformanceTests.swift b/swift/Tests/ConformanceTests/ClientConformanceTests.swift index 0c9436b37f..fb438e81be 100644 --- a/swift/Tests/ConformanceTests/ClientConformanceTests.swift +++ b/swift/Tests/ConformanceTests/ClientConformanceTests.swift @@ -34,7 +34,7 @@ struct ClientConformanceTests { if let only, !name.contains(only) { continue } let expected = scenario["expect"]?.arrayValue ?? [] let runner = try ScenarioRunner(scenario, startTime: startTime, storage: storage) - let actual = runner.run() + let actual = await runner.run() if let mismatch = Self.firstMismatch(scenario, expected, actual) { failed += 1 Issue.record(Comment(rawValue: "\(name)\n\(mismatch)")) @@ -117,6 +117,16 @@ final class ScenarioRunner { var restarts = 0 /// The IDs placeholders in downstream messages stand for. var ids: [String: String] = [:] + /// The current client's log, and how much of it was reported. + var log = RecordingLogSink() + var logsSeen = 0 + /// The `inspect` calls, how many are still running, and how many + /// inspector requests were sent. + var inspectCalls: [(String, Settled)] = [] + var inspectRunning = 0 + var inspectCount = 0 + /// The IDs the runner gives inspector requests, so that runs repeat. + var inspectIDs = 0 init(_ scenario: JSONValue, startTime: Double, storage: ZeroStorage) throws { self.scenario = scenario @@ -131,7 +141,15 @@ final class ScenarioRunner { func makeZero(_ o: JSONValue, mutators registered: JSONValue? = nil) throws -> Zero { var options = ZeroOptions() - options.logSink = RecordingLogSink() + log = RecordingLogSink() + options.logSink = log + options.logLevel = + switch o["logLevel"]?.stringValue { + case "debug": .debug + case "info": .info + case "error": .error + default: .warn + } switch o["cacheURL"] { case .null?: options.cacheURL = nil case .string(let s)?: options.cacheURL = s @@ -177,9 +195,14 @@ final class ScenarioRunner { let mutators = registered?.stringValue == "issues" ? ClientApp.mutators.filter { $0.name.hasPrefix("issue.") } : ClientApp.mutators - return try Zero( + let zero = try Zero( schema: ClientApp.schema, mutators: mutators, options: options, scheduler: scheduler, socketFactory: factory) + zero.engine.inspectRPCs.makeID = { [unowned self] in + inspectIDs += 1 + return "inspect-request-\(inspectIDs)" + } + return zero } /// Closes the client and starts a new one on the same storage @@ -206,6 +229,8 @@ final class ScenarioRunner { mutations = [] runs = [] preloads = [] + inspectCalls = [] + logsSeen = 0 } func normalize(_ v: JSONValue, key: String? = nil) -> JSONValue { @@ -402,11 +427,169 @@ final class ScenarioRunner { case "unlisten": let name = step["listener"]!.stringValue! listeners.first { $0.0 == name }?.1.remove() + case "inspect": + try inspect(step) default: throw ClientApp.Failure("Unknown op \(op)") } } + /// An `inspect` step: calls `zero.inspector` and records how its result + /// settles (`inspect` in `harness.ts`). The calls are async, so each runs + /// in a task that `settle` lets run. + func inspect(_ step: JSONValue) throws { + let call = step["call"]!.stringValue! + let entry = Settled() + if let i = inspectCalls.firstIndex(where: { $0.0 == call }) { + inspectCalls[i].1 = entry + } else { + inspectCalls.append((call, entry)) + } + let inspector = zero.inspector + let options = step["options"].map { o in + AnalyzeQueryOptions( + vendedRows: o["vendedRows"]?.boolValue, syncedRows: o["syncedRows"]?.boolValue, + joinPlans: o["joinPlans"]?.boolValue) + } + func record(_ body: @escaping () async throws -> T, _ convert: @escaping (T) -> JSONValue) { + inspectRunning += 1 + Task { @MainActor [self] in + do { + entry.value = ["resolved": convert(try await body())] + } catch { + entry.value = ["rejected": .string(Self.inspectError(error))] + } + inspectRunning -= 1 + } + } + let clients = { [self] (clients: [InspectorClient]) -> JSONValue in + let out = clients.map { c -> (String, JSONValue) in + let id = placeholders[c.id] ?? c.id + return (id, ["id": .string(id), "clientGroupID": normalize(.string(c.clientGroup.id))]) + } + return .array(out.sorted { StringCompare.utf16($0.0, $1.0) < 0 }.map(\.1)) + } + let queries = { (queries: [InspectorQuery]) -> JSONValue in .array(queries.map(Self.queryJSON)) + } + switch step["method"]?.stringValue { + case "metrics": record({ try await inspector.metrics() }, Self.metricsJSON) + case "serverVersion": record({ try await inspector.serverVersion() }) { .string($0) } + case "clients": record({ try await inspector.clients() }, clients) + case "clientsWithQueries": record({ try await inspector.clientsWithQueries() }, clients) + case "clientQueries": record({ try await inspector.client.queries() }, queries) + case "clientMap": + // Swift's map is a dictionary; JS's iterates in the store's key order. + record({ try await inspector.client.map() }) { [self] map in + .array( + map.sorted { StringCompare.utf8($0.key, $1.key) < 0 }.map { k, v in + var k = k + for (id, placeholder) in placeholders { + k = k.replacingOccurrences(of: id, with: placeholder) + } + return [.string(k), v] + }) + } + case "clientRows": + let table = step["table"]?.stringValue ?? "" + record({ try await inspector.client.rows(table) }) { .array($0.map { .object($0.object) }) } + case "clientGroupClients": record({ try await inspector.clientGroup.clients() }, clients) + case "clientGroupClientsWithQueries": + record({ try await inspector.clientGroup.clientsWithQueries() }, clients) + case "clientGroupQueries": record({ try await inspector.clientGroup.queries() }, queries) + case "analyzeQuery": + let query = try ClientApp.request(step["query"]?.stringValue ?? "", step["args"]) + record({ try await inspector.analyzeQuery(query, options: options) }, \.json) + case "analyzeServerAST": + let ast = try AST(json: step["ast"] ?? .null) + record({ try await inspector.analyzeServerAST(ast, options: options) }, \.json) + case "analyzeNamedQuery": + let name = step["name"]?.stringValue ?? "" + let args = step["queryArgs"]?.arrayValue ?? [] + record( + { try await inspector.analyzeNamedQuery(name: name, args: args, options: options) }, \.json) + case "authenticate": + let password = step["password"]?.stringValue ?? "" + record({ try await inspector.authenticate(password: password) }) { .bool($0) } + case "formatPlannerEvents": + entry.value = [ + "resolved": .string(inspector.formatPlannerEvents(step["events"]?.arrayValue ?? [])) + ] + case let method: + throw ClientApp.Failure("Unknown inspector method \(method ?? "")") + } + } + + /// JS's message for an inspector error (`errorMessage` in `harness.ts`). + /// Where zero-cache refuses an unauthenticated request, JS prompts for + /// the password, and without one fails with `Authentication failed`; + /// Swift fails with `InspectorError.authenticationRequired`, whose + /// message says to call `authenticate(password:)`. + static func inspectError(_ error: any Error) -> String { + switch error { + case InspectorError.authenticationRequired: "Authentication failed" + case InspectorError.server(let message): message + case let e as InspectorError: e.description + default: errorMessage(error) + } + } + + /// Digests as their JSON, by their JS names (`metricsJSON`). + static func metricsJSON(_ metrics: Metrics) -> JSONValue { + var o: JSONObject = [:] + for name in Metrics.names { + o[name] = .array((metrics[name]?.toJSON() ?? []).map(JSONValue.number)) + } + return .object(o) + } + + /// A query's fields (`queriesJSON`). + static func queryJSON(_ q: InspectorQuery) -> JSONValue { + // `JSON.stringify` writes NaN and the infinities as null. + func number(_ n: Double?) -> JSONValue { + n.flatMap { $0.isFinite ? .number($0) : nil } ?? .null + } + func string(_ s: String?) -> JSONValue { s.map(JSONValue.string) ?? .null } + return [ + "name": string(q.name), "args": q.args.map(JSONValue.array) ?? .null, "got": .bool(q.got), + "ttl": q.ttl.json, "inactivatedAt": number(q.inactivatedAt), + "rowCount": .number(q.rowCount), "deleted": .bool(q.deleted), "id": .string(q.id), + "clientID": .string(q.clientID), "metrics": metricsJSON(q.metrics), + "clientZQL": string(q.clientZQL), "serverZQL": string(q.serverZQL), + "hydrateClient": number(q.hydrateClient), "hydrateServer": number(q.hydrateServer), + "hydrateTotal": number(q.hydrateTotal), "updateClientP50": number(q.updateClientP50), + "updateClientP95": number(q.updateClientP95), "updateServerP50": number(q.updateServerP50), + "updateServerP95": number(q.updateServerP95), + ] + } + + /// The materialization messages logged since the last step, as JS logs + /// them: the level, and the message, query ID, AST, and ms. Swift logs + /// one line, ` `. + func materializationLogs() -> [JSONValue] { + let entries = log.entries + defer { logsSeen = entries.count } + return entries[min(logsSeen, entries.count)...].compactMap { e -> JSONValue? in + guard + let message = Self.materializationMessages.first(where: { e.message.hasPrefix($0 + " ") }) + else { return nil } + let rest = e.message.dropFirst(message.count + 1) + guard let space = rest.firstIndex(of: " "), let last = rest.lastIndex(of: " "), space < last, + let ast = try? JSONParser.parse(Array(rest[rest.index(after: space)..(_ r: Result) -> JSONValue { switch r { case .success: "resolved" @@ -421,7 +604,18 @@ final class ScenarioRunner { scheduler.runDueTimers() } - func run() -> [JSONValue] { + /// `settle`, and while inspector calls are running, lets their tasks run + /// and settles the work they queue, as `settle` in `harness.ts` lets + /// promises settle. + func settleWithInspector() async { + settle() + for _ in 0..<20 where inspectRunning > 0 { + await Task.yield() + settle() + } + } + + func run() async -> [JSONValue] { var results: [JSONValue] = [] for step in scenario["steps"]?.arrayValue ?? [] { let sockets = factory.sockets @@ -433,7 +627,7 @@ final class ScenarioRunner { } catch { result["threw"] = .string(errorMessage(error)) } - settle() + await settleWithInspector() let now = factory.sockets let opened = now[sockets.count...].map { s -> JSONValue in @@ -447,7 +641,15 @@ final class ScenarioRunner { for (i, s) in now.enumerated() { let from = i < sentCounts.count ? sentCounts[i] : 0 for m in s.messages[from...] { - sent.append(normalize((try? JSONParser.parse(Array(m.utf8))) ?? .string(m))) + let message = (try? JSONParser.parse(Array(m.utf8))) ?? .string(m) + if message[0] == "inspect", let id = message[1]?["id"]?.stringValue, + placeholders[id] == nil + { + placeholders[id] = "$inspect.\(inspectCount)" + ids["$inspect.\(inspectCount)"] = id + inspectCount += 1 + } + sent.append(normalize(message)) } } if !sent.isEmpty { result["sent"] = .array(sent) } @@ -488,6 +690,13 @@ final class ScenarioRunner { result["events"] = .array(events) events = [] } + if !inspectCalls.isEmpty { + var o: JSONObject = [:] + for (name, c) in inspectCalls { o[name] = c.value } + result["inspector"] = normalize(.object(o)) + } + let logs = materializationLogs() + if !logs.isEmpty { result["logs"] = .array(logs) } if !listeners.isEmpty { var o: JSONObject = [:] for (name, l) in listeners { diff --git a/swift/Tests/ConformanceTests/HardenMutationTests.swift b/swift/Tests/ConformanceTests/HardenMutationTests.swift index e6320b60b5..8c80cb4710 100644 --- a/swift/Tests/ConformanceTests/HardenMutationTests.swift +++ b/swift/Tests/ConformanceTests/HardenMutationTests.swift @@ -15,23 +15,23 @@ struct HardenMutationConformanceTests { ((try? Vectors.file("client-harden-mutations"))?["cases"]?.arrayValue ?? []) .compactMap { $0["name"]?.stringValue } - @Test(arguments: names) func onMemory(_ name: String) throws { - try Self.run(name, storage: .memory) + @Test(arguments: names) func onMemory(_ name: String) async throws { + try await Self.run(name, storage: .memory) } - @Test(arguments: names) func onSQLite(_ name: String) throws { + @Test(arguments: names) func onSQLite(_ name: String) async throws { let directory = NSTemporaryDirectory() + "zero-harden-mutations-" + UUID().uuidString defer { try? FileManager.default.removeItem(atPath: directory) } - try Self.run(name, storage: .sqlite(directory: directory)) + try await Self.run(name, storage: .sqlite(directory: directory)) } - static func run(_ name: String, storage: ZeroStorage) throws { + static func run(_ name: String, storage: ZeroStorage) async throws { let file = try Vectors.file("client-harden-mutations") let startTime = file["shared"]?["startTime"]?.numberValue ?? 0 let scenario = try #require( file["cases"]?.arrayValue?.first { $0["name"]?.stringValue == name }) let runner = try ScenarioRunner(scenario, startTime: startTime, storage: storage) - let actual = runner.run() + let actual = await runner.run() if let mismatch = ClientConformanceTests.firstMismatch( scenario, scenario["expect"]?.arrayValue ?? [], actual) { diff --git a/swift/Tests/ConformanceTests/InspectorConformanceTests.swift b/swift/Tests/ConformanceTests/InspectorConformanceTests.swift new file mode 100644 index 0000000000..9a7cae5430 --- /dev/null +++ b/swift/Tests/ConformanceTests/InspectorConformanceTests.swift @@ -0,0 +1,28 @@ +import Foundation +import Testing + +@testable import Zero + +/// Replays the inspector scenarios +/// (`packages/zero-conformance/src/client/scenarios/inspector.ts`): the RPCs +/// over the socket and how their answers resolve, the local store as the +/// inspector reads it, and the query metrics and materialization logs. +/// Where zero-cache refuses an unauthenticated request, JS prompts for the +/// password and fails with `Authentication failed` without one; Swift throws +/// `InspectorError.authenticationRequired`, which the runner reports as JS's +/// message (`ScenarioRunner.inspectError`). +/// Set `ZERO_CLIENT_SCENARIO` to run the scenarios whose name contains it. +@Suite(.enabled(if: Vectors.available)) +@MainActor +struct InspectorConformanceTests { + @Test func scenariosOnMemory() async throws { + try await ClientConformanceTests.run(storage: .memory, vectors: "client-inspector") + } + + @Test func scenariosOnSQLite() async throws { + let directory = NSTemporaryDirectory() + "zero-inspector-scenarios-" + UUID().uuidString + defer { try? FileManager.default.removeItem(atPath: directory) } + try await ClientConformanceTests.run( + storage: .sqlite(directory: directory), vectors: "client-inspector") + } +} diff --git a/swift/Tests/ConformanceTests/PrimitiveConformanceTests.swift b/swift/Tests/ConformanceTests/PrimitiveConformanceTests.swift index de1fbb5975..dc871ec624 100644 --- a/swift/Tests/ConformanceTests/PrimitiveConformanceTests.swift +++ b/swift/Tests/ConformanceTests/PrimitiveConformanceTests.swift @@ -116,4 +116,76 @@ struct PrimitiveConformanceTests { } } } + /// A vector number: NaN and the infinities are strings. + static func number(_ v: JSONValue) -> Double { + switch v { + case .string("NaN"): .nan + case .string("Infinity"): .infinity + case .string("-Infinity"): -.infinity + default: v.numberValue ?? .nan + } + } + + static func encode(_ n: Double) -> JSONValue { + n.isNaN ? "NaN" : n.isInfinite ? (n > 0 ? "Infinity" : "-Infinity") : .number(n) + } + + /// `shared/src/tdigest.ts`: each case runs its ops on its digests, and + /// each op's result must be JS's, number for number (JSON drops the sign + /// of zero, so only that may differ). + @Test func tdigest() throws { + var passed = 0 + for c in try Vectors.cases("tdigest") { + let name = c["name"]?.stringValue ?? "?" + var digests = (c["compressions"]?.arrayValue ?? []).map { + TDigest(compression: $0.numberValue ?? 100) + } + let expect = c["expect"]?.arrayValue ?? [] + var ok = true + for (i, op) in (c["ops"]?.arrayValue ?? []).enumerated() { + let d = Int(op["d"]?.numberValue ?? 0) + let got: JSONValue + switch op["op"]?.stringValue { + case "add": + for pair in op["values"]?.arrayValue ?? [] { + digests[d].add(Self.number(pair[0] ?? .null), weight: Self.number(pair[1] ?? .null)) + } + got = .null + case "merge": + digests[d].merge(digests[Int(op["from"]?.numberValue ?? 0)]) + got = .null + case "quantile": + got = .array( + (op["q"]?.arrayValue ?? []).map { Self.encode(digests[d].quantile(Self.number($0))) }) + case "cdf": + got = .array( + (op["x"]?.arrayValue ?? []).map { Self.encode(digests[d].cdf(Self.number($0))) }) + case "count": + got = Self.encode(digests[d].count()) + case "toJSON": + got = .array(digests[d].toJSON().map(Self.encode)) + case "fromJSON": + do { + digests[d] = try TDigest(json: (op["json"]?.arrayValue ?? []).map(Self.number)) + got = "ok" + } catch { + got = ["threw": .string(error.description)] + } + case "reset": + digests[d].reset() + got = .null + case let other: + throw ClientApp.Failure("Unknown op \(other ?? "")") + } + let want = i < expect.count ? expect[i] : .null + if got != want { + Issue.record("\(name) op \(i) (\(op["op"] ?? .null)): Swift \(got), JS \(want)") + ok = false + break + } + } + if ok { passed += 1 } + } + print("[tdigest] \(passed) passed") + } }