Adds the Kleros Reality Module onto the Zodiac app. Some details:
a middle ground between the old and deceptively simple Old Reality Module, and the newer but restrictive new Reality Module
automatically creates the template for the user. it is opinionated and won't allow custom templates to be created (will be added on demand)
links to docs in case SafeSnap needs manual setup (Safe not controlling, or non-Mainnet)
links to docs in case daorequirements is not setup (mitigates risks)
does not set up any kind of monitoring, users are expected to read the docs and be cautious.
Additional Context
I tried to minimize side effects on other sections of the code that were unrelated to the addition of the new module.
exposed some consts and functions via export, so that I could reuse them in the module
added a getEnsTextRecord function in the services/ens, meant to check daorequirements record to warn the user.
Kleros Reality Module is only visible when there's klerosAvailability
I'm not sure if the descriptions are appropriate, if you want to suggest some editing so match the wording of other descriptions, feel free.
didn't use the setup function since it was too hard to wrap the variables to satisfy it, so I simply exposed what I needed and built the transactions with the transaction factory functions (addSafeSnapToSnapshotSpaceTxs and deployRealityModule)
I did a few tests and I've gone through the code multiple times, but there could be some form errors still.
Additional Request
Note the DETERMINISTIC_DEPLOYMENT_HELPER_ADDRESS is not available in Gnosis or Polygon, so the transaction batch will fail in those chains. I don't know how to deploy this contract to that address in those chains, so I request help there.
Implementation
Adds the Kleros Reality Module onto the Zodiac app. Some details:
daorequirements
is not setup (mitigates risks)Additional Context
I tried to minimize side effects on other sections of the code that were unrelated to the addition of the new module.
getEnsTextRecord
function in the services/ens, meant to check daorequirements record to warn the user.klerosAvailability
setup
function since it was too hard to wrap the variables to satisfy it, so I simply exposed what I needed and built the transactions with the transaction factory functions (addSafeSnapToSnapshotSpaceTxs
anddeployRealityModule
)Additional Request
Note the
DETERMINISTIC_DEPLOYMENT_HELPER_ADDRESS
is not available in Gnosis or Polygon, so the transaction batch will fail in those chains. I don't know how to deploy this contract to that address in those chains, so I request help there.Screenshot for reference.