-
Notifications
You must be signed in to change notification settings - Fork 952
Fix Docker build cache issue for deposit contract files #8488
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
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The deposit contract build script downloads files and stores them in common/deposit_contract/contracts/, but these generated files were not persisted when using Docker cache mounts for the target directory. When Docker reused cached build artifacts, the contract files were missing, causing build failures with include_bytes!() errors. This fix adds a cache mount for the contracts directory, ensuring the generated files persist across builds alongside other build artifacts. When the TAG constant in build.rs changes, the Docker COPY layer invalidates and the cache rebuilds correctly.
Member
|
I think the correct fix is for the build script to put the files in |
Member
Author
|
will go with #8518 instead which implements what @michaelsproul suggested above, it's a much better approach. |
mergify bot
pushed a commit
that referenced
this pull request
Dec 3, 2025
Alternative to: - #8488 Refactors deposit_contract crate to comply with Rust build conventions by placing generated artifacts in the build output directory. Co-Authored-By: Michael Sproul <[email protected]>
kevaundray
added a commit
to eth-act/lighthouse
that referenced
this pull request
Dec 13, 2025
* Update local testnet scripts for the fulu fork (sigp#8489) * Remove `fulu-devnet-3` testing on CI * Delete `scripts/local_testnet/network_params_das.yaml` and consolidate it into the main `network_params.yaml` file we use on CI * Delete enclave before building image, so it doesn't cause slow image building. Co-Authored-By: Jimmy Chen <[email protected]> * Fix data columns sorting when reconstructing blobs (sigp#8510) Closes sigp#8509 Co-Authored-By: Antoine James <[email protected]> * Instrument attestation signing. (sigp#8508) We noticed attestation signing taking 2+ seconds on some of our hoodi nodes and the current traces doesn't provide enough details. This PR adds a few more spans to the `attestation_duty_cycle` code path in the VC. Before: <img width="842" height="154" alt="image" src="https://github.com/user-attachments/assets/cfc5c8c0-e6f2-4f56-a8e4-65001af4a005" /> After: <img width="496" height="217" alt="image" src="https://github.com/user-attachments/assets/c91cfa88-af1b-456e-8c64-625809eb6881" /> Co-Authored-By: Jimmy Chen <[email protected]> * Always use committee index 0 when getting attestation data (sigp#8171) * sigp#8046 Split the function `publish_attestations_and_aggregates` into `publish_attestations` and `handle_aggregates`, so that for attestations, only 1 task is spawned. Co-Authored-By: Tan Chee Keong <[email protected]> Co-Authored-By: chonghe <[email protected]> Co-Authored-By: Michael Sproul <[email protected]> Co-Authored-By: Michael Sproul <[email protected]> * Move deposit contract artifacts to /target (sigp#8518) Alternative to: - sigp#8488 Refactors deposit_contract crate to comply with Rust build conventions by placing generated artifacts in the build output directory. Co-Authored-By: Michael Sproul <[email protected]> * Move beacon state endpoints to a separate module. (sigp#8529) Part of the http api refactor to move endpoint handlers to separate modules. This should improve code maintainability, incremental compilation time and rust analyzer performance. Co-Authored-By: Jimmy Chen <[email protected]> * Refactor `consensus/types` (sigp#7827) Organize and categorize `consensus/types` into modules based on their relation to key consensus structures/concepts. This is a precursor to a sensible public interface. While this refactor is very opinionated, I am open to suggestions on module names, or type groupings if my current ones are inappropriate. Co-Authored-By: Mac L <[email protected]> * Move validator http endpoints to a separate module (sigp#8536) Continuation of: * sigp#8529 Moving `/validator` endpoints out of `http_api` to a separation module. This should improve code maintainability, incremental compilation time and rust analyzer performance. This is a tedious but straight forward change, so we're going with a pair & insta-merge approach to avoid painful & slow async review. @michaelsproul and I paired on the first commit - I believe we are almost done, will pair with @pawanjay176 tomorrow to wrap it up and merge tomorrow. (cc @macladson ) Co-Authored-By: Jimmy Chen <[email protected]> * Move beacon pool http api to its own separate module (sigp#8543) Continuation of: * sigp#8536 Moving `/beacon/pool` endpoints out of `http_api` to a separation module. This should improve code maintainability, incremental compilation time and rust analyzer performance. This is a tedious but straight forward change, so we're going with a pair & insta-merge approach to avoid painful & slow async review Co-Authored-By: Jimmy Chen <[email protected]> * Reduce `eth2` dependency space (sigp#8524) Remove certain dependencies from `eth2`, and feature-gate others which are only used by certain endpoints. | Removed | Optional | Dev only | | -------- | -------- | -------- | | `either` `enr` `libp2p-identity` `multiaddr` | `protoarray` `eth2_keystore` `eip_3076` `zeroize` `reqwest-eventsource` `futures` `futures-util` | `rand` `test_random_derive` | This is done by adding an `events` feature which enables the events endpoint and its associated dependencies. The `lighthouse` feature also enables its associated dependencies making them optional. The networking-adjacent dependencies were removed by just having certain fields use a `String` instead of an explicit network type. This means the user should handle conversion at the call site instead. This is a bit spicy, but I believe `PeerId`, `Enr` and `Multiaddr` are easily converted to and from `String`s so I think it's fine and reduces our dependency space by a lot. The alternative is to feature gate these types behind a `network` feature instead. Co-Authored-By: Mac L <[email protected]> * Clarify `alloy` dependencies (sigp#8550) Previously, we had a pinned version of `alloy` to fix some crate compatibility issues we encountered during the migration away from `ethers`. Now that the migration is complete we should remove the pin. This also updates alloy crates to their latest versions. Co-Authored-By: Mac L <[email protected]> * Remove `consensus/types` re-exports (sigp#8540) There are certain crates which we re-export within `types` which creates a fragmented DevEx, where there are various ways to import the same crates. ```rust // consensus/types/src/lib.rs pub use bls::{ AggregatePublicKey, AggregateSignature, Error as BlsError, Keypair, PUBLIC_KEY_BYTES_LEN, PublicKey, PublicKeyBytes, SIGNATURE_BYTES_LEN, SecretKey, Signature, SignatureBytes, get_withdrawal_credentials, }; pub use context_deserialize::{ContextDeserialize, context_deserialize}; pub use fixed_bytes::FixedBytesExtended; pub use milhouse::{self, List, Vector}; pub use ssz_types::{BitList, BitVector, FixedVector, VariableList, typenum, typenum::Unsigned}; pub use superstruct::superstruct; ``` This PR removes these re-exports and makes it explicit that these types are imported from a non-`consensus/types` crate. Co-Authored-By: Mac L <[email protected]> * Fix testnet script (sigp#8557) Fix an issue where a kurtosis testnet script was failing because no supernodes were provided ``` There was an error interpreting Starlark code Evaluation error: fail: Fulu fork is enabled (epoch: 0) but no supernodes are configured, no nodes have 128 or more validators, and perfect_peerdas_enabled is not enabled. Either configure a supernode, ensure at least one node has 128+ validators, or enable perfect_peerdas_enabled in network_params with 16 participants. at [github.com/ethpandaops/ethereum-package/main.star:83:57]: run at [github.com/ethpandaops/ethereum-package/src/package_io/input_parser.star:377:17]: input_parser at [0:0]: fail ``` Co-Authored-By: Eitan Seri-Levi <[email protected]> Co-Authored-By: Pawan Dhananjay <[email protected]> * Do not request attestation data when attestation duty is empty (sigp#8559) Co-Authored-By: Tan Chee Keong <[email protected]> * Rust 1.92 lints (sigp#8567) Co-Authored-By: Eitan Seri-Levi <[email protected]> --------- Co-authored-by: Jimmy Chen <[email protected]> Co-authored-by: Jimmy Chen <[email protected]> Co-authored-by: 0xMushow <[email protected]> Co-authored-by: Antoine James <[email protected]> Co-authored-by: chonghe <[email protected]> Co-authored-by: Michael Sproul <[email protected]> Co-authored-by: Michael Sproul <[email protected]> Co-authored-by: Mac L <[email protected]> Co-authored-by: Eitan Seri-Levi <[email protected]> Co-authored-by: Pawan Dhananjay <[email protected]> Co-authored-by: Tan Chee Keong <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Fixes Docker build failures when using cache mounts. The build was failing with errors like:
The deposit contract crate uses a build script (
build.rs) to download contract ABI and bytecode files from GitHub, storing them incommon/deposit_contract/contracts/. These files are then included at compile time viainclude_bytes!().The Docker cache mount for
/lighthouse/targetcaused Cargo to skip re-running the build script on subsequent builds, but the generated contract files weren't persisted in the cache. This resulted in compilation failures becauseinclude_bytes!()couldn't find the required files.Workaround right now is to run
docker builder prune -a -fThe fix adds a cache mount for the contracts directory, ensuring generated files persist across builds.