semaphore-protocol / semaphore

A zero-knowledge protocol for anonymous interactions.
https://semaphore.pse.dev
MIT License
887 stars 194 forks source link

Specify artifacts version in `@semaphore-protocol/proof` package #825

Closed cedoor closed 1 month ago

cedoor commented 1 month ago

Description

The version of the ZK artifacts to download when generating a proof needs to be specified, as the latest version will be used by default, and when a new version is released the old version would still point to the latest, which would no longer be the right version.

sripwoud commented 1 month ago

What we want is to pass a hardcoded version parameter to the maybeGetSnarkArtifacts function here, correct? Where version is one of the @zk-kit/semaphore-artifacts version published in npm?

curl https://registry.npmjs.com/@zk-kit/semaphore-artifacts | jq '.versions | keys'

What would be the best way?

cedoor commented 1 month ago

@sripwoud

I tend to prefer the first option. Re the third, are there any use cases where a package needs the latest?

sripwoud commented 1 month ago

Closed by https://github.com/semaphore-protocol/semaphore/pull/826/commits/9f6516c060de803545bcaa7e415cabaafaa81527