Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ECDH library isn't a library. #25

Closed
TomAFrench opened this issue Jan 27, 2025 · 3 comments · Fixed by #29
Closed

ECDH library isn't a library. #25

TomAFrench opened this issue Jan 27, 2025 · 3 comments · Fixed by #29
Assignees
Labels
bug 🐛 Something isn't working

Comments

@TomAFrench
Copy link

The ECDH library is currently marked as a binary crate and so it cannot be imported as a dependency from another crate.

@TomAFrench TomAFrench added the bug 🐛 Something isn't working label Jan 27, 2025
@ericDeCourcy
Copy link

I tried running nargo check and nargo compile (in ecdh/ directory) without making this change. Both failed with the following error:

error: Non-comptime variable `x` referenced in comptime code
    ┌─ /home/user/nargo/github.com/noir-lang/ec/v0.1.2/src/tecurve.nr:104:22
    │
104 │             self.a * x * x + y * y == 1 + self.d * x * x * y * y
    │                      - Non-comptime variables can't be used in comptime code
    │

after changing the type to "lib" the error is gone for ONLY nargo compile. The error persists for nargo check.

@TomAFrench
Copy link
Author

after changing the type to "lib" the error is gone for ONLY nargo compile

This is as nargo compile skips any library crates as there isn't an entrypoint function to compile into a circuit.

@cedoor
Copy link
Member

cedoor commented Feb 4, 2025

@signorecello

@cedoor cedoor added this to ZK-Kit Feb 4, 2025
@github-project-automation github-project-automation bot moved this to 📋 Backlog in ZK-Kit Feb 4, 2025
@cedoor cedoor moved this from 📋 Backlog to 👀 In Review in ZK-Kit Feb 20, 2025
@github-project-automation github-project-automation bot moved this from 👀 In Review to ✔️ Done in ZK-Kit Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something isn't working
Projects
Status: ✔️ Done
4 participants