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

build.rs fails to compile -> ethers-rs has made ethers::solc a feature rather than default #3

Closed
plotchy opened this issue Jul 7, 2022 · 1 comment · Fixed by #4

Comments

@plotchy
Copy link

plotchy commented Jul 7, 2022

This pr for ethers-rs has made ethers-solc an optional feature:
gakonst/ethers-rs#1463

build.rs depends on ethers::solc

[build-dependencies]
ethers = { git = "https://github.com/gakonst/ethers-rs" , features = ["ethers-solc"]}

After making the change, build.rs still fails to compile. I'm not familiar with the logic in that file, otherwise I would've made the fix a PR. Hope this helps.

error[E0061]: this function takes 2 arguments but 1 argument was supplied
   --> /home/plotchy/.cargo/git/checkouts/erigon-db-d1f243f9aeca17a7/d88f5bf/build.rs:29:31
    |
29  |         let contract = output.find(name).ok_or_else(|| {
    |                               ^^^^------ an argument is missing
    |
note: associated function defined here
   --> /home/plotchy/.cargo/git/checkouts/ethers-rs-c3a7c0a0ae0fe6be/8db1899/ethers-solc/src/compile/output/mod.rs:246:12
    |
246 |     pub fn find(&self, path: impl AsRef<str>, contract: impl AsRef<str>) -> Option<&T::Artifact> {
    |            ^^^^
help: provide the argument
    |
29  |         let contract = output.find(name, {_}).ok_or_else(|| {
    |                               ~~~~~~~~~~~~~~~
@gio256
Copy link
Owner

gio256 commented Jul 8, 2022

Sorry, this repo could use some love. It's stuck in between experimental and usable.

#4 should solve your problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants