Skip to content

Commit 5722e92

Browse files
ioedeveloperAniket-Engg
authored andcommitted
Track json export of witness
1 parent 3b33986 commit 5722e92

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

apps/circuit-compiler/src/app/actions/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ export const computeWitness = async (plugin: CircomPluginClient, appState: AppSt
3131
const writePath = extractParentFromKey(appState.filePath) + `/.bin/${fileName.replace('.circom', '.wtn.json')}`
3232

3333
await plugin.call('fileManager', 'writeFile', writePath, JSON.stringify(wtnsJson, null, 2))
34+
plugin._paq.push(['trackEvent', 'circuit-compiler', 'computeWitness', 'wtns.exportJson', writePath])
3435
}
3536
} else {
3637
console.log('Existing witness computation in progress')

apps/circuit-compiler/src/app/services/circomPluginClient.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,7 @@ export class CircomPluginClient extends PluginClient {
249249
const witness = this.compiler ? await this.compiler.generate_witness(dataRead, input) : await generate_witness(dataRead, input)
250250
// @ts-ignore
251251
await this.call('fileManager', 'writeFile', wasmPath.replace('.wasm', '.wtn'), witness, true)
252-
this._paq.push(['trackEvent', 'circuit-compiler', 'computeWitness', 'Witness computing successful'])
252+
this._paq.push(['trackEvent', 'circuit-compiler', 'computeWitness', 'compiler.generate_witness', wasmPath.replace('.wasm', '.wtn')])
253253
this.internalEvents.emit('circuit_computing_witness_done')
254254
this.emit('statusChanged', { key: 'succeed', title: 'witness computed successfully', type: 'success' })
255255
return witness

0 commit comments

Comments
 (0)