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

Fix dapp---use and solc---use for flakes #977

Draft
wants to merge 76 commits into
base: master
Choose a base branch
from
Draft

Fix dapp---use and solc---use for flakes #977

wants to merge 76 commits into from

Conversation

asymmetric
Copy link
Contributor

@asymmetric asymmetric commented Feb 24, 2023

Description

The main goal of this PR is to allow dapp --use and seth --use for flake users. This requires a series of internal changes:

  • bumping the nix version (as the previously pinned one was pre-flakes), which in turn required
  • bumping the nixpkgs version, which in turn required
  • switching to ethereum/hevm (as there was no hope of getting the in-tree hevm to compile with a newer nixpkgs).

So to summarize:

  • Fixes usage of dapptools with flakes
  • Switches to ethereum/hevm (incorporating work from Use ethereum hevm #968)
  • Fixes a bug in seth---use where seth would be run twice
  • Adds a devShell to flake
  • Adds a CI job that runs nix build (in the future, it should supplant the existing one, and run nix flake check)
  • And a few other minor tweaks

Checklist

  • tested locally
  • added automated tests
  • updated the docs
  • updated the changelog

closes #968

asymmetric and others added 30 commits February 24, 2023 15:42
The cache config is in the flake itself.
Allows running:

nix profile install .#solc-static-versions.solc_0_8_16
We need a recent nix command to have flakes, so we might as well update
to the latest stable release.

This introduces some build errors, which are fixed in the following
commits.
Ours doesn't build with 22.11 anymore, and is unmaintained anyway.
Not actually supported by our solc-versions infra
The hexadecimal `x` is tripping shellcheck into thinking we're comparing
against a string.
These are a new, incompatible type of profile that is queried with the
experimental `nix profile` subcommand.
nix profile install .#solc-versions.solc_0_5_15
@asymmetric
Copy link
Contributor Author

looks like ci is still failing because of: ethereum/hevm#198? this should be fixed in main

For the record, there's still a failing test, pending a fix on hevm.

According to the new CLI docs, by using --expr we're saying that the
installable (in our case `out`) is an attribute in the attribute set
that the expression evaluates to.

So it should always be there, and therefore callers don't need to add
it.
@asymmetric asymmetric marked this pull request as draft March 30, 2023 11:53
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 this pull request may close these issues.

2 participants