ora-io / cle-cli

CLI for Building Your CLE.
https://docs.ora.io/doc/cle
28 stars 18 forks source link

input too large to mock prove #40

Open LiRiu opened 9 months ago

LiRiu commented 9 months ago

When the input is too large, prove --test cannot simulate the proving process.

Env

Reproduce

  1. git clone https://github.com/LiRiu/zkEthscription.git
  2. cd zkEthscription && npm install
  3. cp zkgraph.config.example.js zkgraph.config.js && vim zkgraph.config.js
  4. npm run prove -- 4940316 00bc614e646174613a696d6167652f6a7065673b6261736536342c2f396a2f34414151536b5a4a5267414241514141415141424141442f327745454541424441454d4151774244414563415177424c41464d415577424c414767416341426b41484141614143614149304167514342414930416d674470414b59417377436d414c4d41706744704157494133414543414e774133414543414e774259674534415873424e4145664154514265774534416a4942755147484159634275514979416f6b43495149454169454369514d534172384376774d534139344472415065425134464467624c4551424441454d4151774244414563415177424c41464d415577424c414767416341426b41484141614143614149304167514342414930416d674470414b59417377436d414c4d41706744704157494133414543414e774133414543414e774259674534415873424e4145664154514265774534416a4942755147484159634275514979416f6b43495149454169454369514d534172384376774d534139344472415065425134464467624c2f384941455167415441424d417745694141495241514d5241662f454143774141414d4241514141414141414141414141414141414141434177454541514542415141414141414141414141414141414141414141514c2f3267414d417745414168414445414141414f414141595575684d594641446373563649374c6b3654584d624c495a754964664c306e5643545339335045796a525452455a62446f353646567a5177463163425642414148514b45775a5141412f2f3851414a424142414149424241494341674d4141414141414141414151414345514d534954455151534169457a42525958482f3267414941514541415438412f625473347a4c61526d4f6e2f444e6a477166414d7a5955715a4a585336566d4531584d72516175586d4e583378784d4c6d574d506d6c556a7061746f4e2b737770626c6a6b7a676c796f55426e396534392b4355666f7831714a4d356638415a587161324a686a564d53353472325266714241446d3833747863645438754f6d4b744730626c7655785a4e336f6c764250554e49745274756a6130577436796732347a784c304b347777357179336b764e307143387543504338356d4a694b48784746676d2b6234326633662f2f454142635241414d4241414141414141414141414141414141414145524d41442f3267414941514942415438416d41736b612f2f454142515241514141414141414141414141414141414141414145442f3267414941514d4241543841542f2f5a00000000000000000000bc614e --test

and the error will seem like below:

image
lightmanM commented 9 months ago

Tracked in the case https://www.notion.so/hyperoracle/Mock-Prove-failed-when-imput-is-too-large-7984cd190f2e4798a392d4c7f94bdbfc

lightmanM commented 9 months ago

We need to confirm if the mock is suppose to take such long string. But in the actually prove task, there is a length limit to the payload. This is limited by the zkwasm configuration.

nom4dv3 commented 9 months ago

yes, here is the max size of mock mem that might be the reason causing this issue: https://github.com/hyperoracle/zkgraph-api/blob/master/src/common/zkwasm_mock.ts#L11

lightmanM commented 9 months ago

zkgraph-api@4121909

lightmanM commented 9 months ago

Need to test if zkwasm prove will fail with that. they may have different pub_str size limit