@aztec/aztec 0.87.5 → 0.87.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"version":3,"file":"start_prover_agent.d.ts","sourceRoot":"","sources":["../../../src/cli/cmds/start_prover_agent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;AAE/E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAenD,wBAAsB,gBAAgB,CACpC,OAAO,EAAE,GAAG,EACZ,cAAc,EAAE,CAAC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,EACvC,QAAQ,EAAE,qBAAqB,EAC/B,OAAO,EAAE,KAAK,iBA+Cf"}
1
+ {"version":3,"file":"start_prover_agent.d.ts","sourceRoot":"","sources":["../../../src/cli/cmds/start_prover_agent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAC;AAE/E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAgBnD,wBAAsB,gBAAgB,CACpC,OAAO,EAAE,GAAG,EACZ,cAAc,EAAE,CAAC,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,EACvC,QAAQ,EAAE,qBAAqB,EAC/B,OAAO,EAAE,KAAK,iBA2Df"}
@@ -3,6 +3,7 @@ import { Agent, makeUndiciFetch } from '@aztec/foundation/json-rpc/undici';
3
3
  import { buildServerCircuitProver } from '@aztec/prover-client';
4
4
  import { InlineProofStore, ProvingAgent, createProvingJobBrokerClient, proverAgentConfigMappings } from '@aztec/prover-client/broker';
5
5
  import { getProverNodeAgentConfigFromEnv } from '@aztec/prover-node';
6
+ import { ProverAgentApiSchema } from '@aztec/stdlib/interfaces/server';
6
7
  import { initTelemetryClient, makeTracedFetch, telemetryClientConfigMappings } from '@aztec/telemetry-client';
7
8
  import { extractRelevantOptions, preloadCrsDataForServerSideProving } from '../util.js';
8
9
  import { getVersions } from '../versioning.js';
@@ -16,9 +17,11 @@ export async function startProverAgent(options, signalHandlers, services, userLo
16
17
  ...extractRelevantOptions(options, proverAgentConfigMappings, 'proverAgent')
17
18
  };
18
19
  if (config.realProofs && (!config.bbBinaryPath || !config.acvmBinaryPath)) {
20
+ userLog(`Requested real proving but no path to bb or acvm binaries provided`);
19
21
  process.exit(1);
20
22
  }
21
23
  if (!config.proverBrokerUrl) {
24
+ userLog(`Missing prover broker URL. Pass --proverAgent.proverBrokerUrl <value>`);
22
25
  process.exit(1);
23
26
  }
24
27
  await preloadCrsDataForServerSideProving(config, userLog);
@@ -34,6 +37,22 @@ export async function startProverAgent(options, signalHandlers, services, userLo
34
37
  const prover = await buildServerCircuitProver(config, telemetry);
35
38
  const proofStore = new InlineProofStore();
36
39
  const agents = times(config.proverAgentCount, ()=>new ProvingAgent(broker, proofStore, prover, config.proverAgentProofTypes, config.proverAgentPollIntervalMs, telemetry));
40
+ // expose all agents as individual services
41
+ for(let i = 0; i < agents.length; i++){
42
+ services[`agent${i}`] = [
43
+ agents[i],
44
+ ProverAgentApiSchema,
45
+ ()=>agents[i].getStatus().status !== 'stopped'
46
+ ];
47
+ }
48
+ // shortcut in the most common case of having a single running agent
49
+ if (agents.length === 1) {
50
+ services[`agent`] = [
51
+ agents[0],
52
+ ProverAgentApiSchema,
53
+ ()=>agents[0].getStatus().status !== 'stopped'
54
+ ];
55
+ }
37
56
  await Promise.all(agents.map((agent)=>agent.start()));
38
57
  signalHandlers.push(async ()=>{
39
58
  await Promise.all(agents.map((agent)=>agent.stop()));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aztec/aztec",
3
- "version": "0.87.5",
3
+ "version": "0.87.7",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": "./dest/index.js"
@@ -27,35 +27,35 @@
27
27
  "../package.common.json"
28
28
  ],
29
29
  "dependencies": {
30
- "@aztec/accounts": "0.87.5",
31
- "@aztec/archiver": "0.87.5",
32
- "@aztec/aztec-faucet": "0.87.5",
33
- "@aztec/aztec-node": "0.87.5",
34
- "@aztec/aztec.js": "0.87.5",
35
- "@aztec/bb-prover": "0.87.5",
36
- "@aztec/bb.js": "0.87.5",
37
- "@aztec/blob-sink": "0.87.5",
38
- "@aztec/bot": "0.87.5",
39
- "@aztec/builder": "0.87.5",
40
- "@aztec/cli": "0.87.5",
41
- "@aztec/cli-wallet": "0.87.5",
42
- "@aztec/constants": "0.87.5",
43
- "@aztec/entrypoints": "0.87.5",
44
- "@aztec/ethereum": "0.87.5",
45
- "@aztec/foundation": "0.87.5",
46
- "@aztec/kv-store": "0.87.5",
47
- "@aztec/noir-contracts.js": "0.87.5",
48
- "@aztec/noir-protocol-circuits-types": "0.87.5",
49
- "@aztec/p2p": "0.87.5",
50
- "@aztec/p2p-bootstrap": "0.87.5",
51
- "@aztec/protocol-contracts": "0.87.5",
52
- "@aztec/prover-client": "0.87.5",
53
- "@aztec/prover-node": "0.87.5",
54
- "@aztec/pxe": "0.87.5",
55
- "@aztec/stdlib": "0.87.5",
56
- "@aztec/telemetry-client": "0.87.5",
57
- "@aztec/txe": "0.87.5",
58
- "@aztec/world-state": "0.87.5",
30
+ "@aztec/accounts": "0.87.7",
31
+ "@aztec/archiver": "0.87.7",
32
+ "@aztec/aztec-faucet": "0.87.7",
33
+ "@aztec/aztec-node": "0.87.7",
34
+ "@aztec/aztec.js": "0.87.7",
35
+ "@aztec/bb-prover": "0.87.7",
36
+ "@aztec/bb.js": "0.87.7",
37
+ "@aztec/blob-sink": "0.87.7",
38
+ "@aztec/bot": "0.87.7",
39
+ "@aztec/builder": "0.87.7",
40
+ "@aztec/cli": "0.87.7",
41
+ "@aztec/cli-wallet": "0.87.7",
42
+ "@aztec/constants": "0.87.7",
43
+ "@aztec/entrypoints": "0.87.7",
44
+ "@aztec/ethereum": "0.87.7",
45
+ "@aztec/foundation": "0.87.7",
46
+ "@aztec/kv-store": "0.87.7",
47
+ "@aztec/noir-contracts.js": "0.87.7",
48
+ "@aztec/noir-protocol-circuits-types": "0.87.7",
49
+ "@aztec/p2p": "0.87.7",
50
+ "@aztec/p2p-bootstrap": "0.87.7",
51
+ "@aztec/protocol-contracts": "0.87.7",
52
+ "@aztec/prover-client": "0.87.7",
53
+ "@aztec/prover-node": "0.87.7",
54
+ "@aztec/pxe": "0.87.7",
55
+ "@aztec/stdlib": "0.87.7",
56
+ "@aztec/telemetry-client": "0.87.7",
57
+ "@aztec/txe": "0.87.7",
58
+ "@aztec/world-state": "0.87.7",
59
59
  "@types/chalk": "^2.2.0",
60
60
  "abitype": "^0.8.11",
61
61
  "chalk": "^5.3.0",
@@ -11,6 +11,7 @@ import {
11
11
  proverAgentConfigMappings,
12
12
  } from '@aztec/prover-client/broker';
13
13
  import { getProverNodeAgentConfigFromEnv } from '@aztec/prover-node';
14
+ import { ProverAgentApiSchema } from '@aztec/stdlib/interfaces/server';
14
15
  import { initTelemetryClient, makeTracedFetch, telemetryClientConfigMappings } from '@aztec/telemetry-client';
15
16
 
16
17
  import { extractRelevantOptions, preloadCrsDataForServerSideProving } from '../util.js';
@@ -33,10 +34,12 @@ export async function startProverAgent(
33
34
  };
34
35
 
35
36
  if (config.realProofs && (!config.bbBinaryPath || !config.acvmBinaryPath)) {
37
+ userLog(`Requested real proving but no path to bb or acvm binaries provided`);
36
38
  process.exit(1);
37
39
  }
38
40
 
39
41
  if (!config.proverBrokerUrl) {
42
+ userLog(`Missing prover broker URL. Pass --proverAgent.proverBrokerUrl <value>`);
40
43
  process.exit(1);
41
44
  }
42
45
 
@@ -61,6 +64,16 @@ export async function startProverAgent(
61
64
  ),
62
65
  );
63
66
 
67
+ // expose all agents as individual services
68
+ for (let i = 0; i < agents.length; i++) {
69
+ services[`agent${i}`] = [agents[i], ProverAgentApiSchema, () => agents[i].getStatus().status !== 'stopped'];
70
+ }
71
+
72
+ // shortcut in the most common case of having a single running agent
73
+ if (agents.length === 1) {
74
+ services[`agent`] = [agents[0], ProverAgentApiSchema, () => agents[0].getStatus().status !== 'stopped'];
75
+ }
76
+
64
77
  await Promise.all(agents.map(agent => agent.start()));
65
78
 
66
79
  signalHandlers.push(async () => {