entropyxyz / programs

Source, toolchain, and examples for using programs on Entropy
https://docs.entropy.xyz/concepts/programs/
GNU Affero General Public License v3.0
19 stars 3 forks source link

Fix examples #78

Closed JesseAbram closed 3 months ago

JesseAbram commented 3 months ago

I fixed the examples to better fit the templated flow

JesseAbram commented 3 months ago

🥇 I can confirm all of these pass tests and build to cargo components my end, except for the risczero one but that is probably that i haven't set up the risc0 stuff.

ya tnh considering removing it, but also maybe fine just as an example idk The device key proxy example has a dead code warning you might wanna fix:

  Compiling device-key-proxy v0.1.0 (/home/turnip/radish/src/entropy/programs/examples/device-key-proxy)
warning: method `to_base64` is never used
  --> examples/device-key-proxy/src/lib.rs:70:8
   |
60 | trait DeviceKey {
   |       --------- method in this trait
...
70 |     fn to_base64(&self) -> (String, String);
   |        ^^^^^^^^^
   |
   = note: `#[warn(dead_code)]` on by default

warning: `device-key-proxy` (lib) generated 1 warning

These examples are pretty fiddly to maintina, really it would be nice to have them tested in CI. I was just about to say this, we need to beef up the CI to check these and to check the basic template