Open
Description
Describe the bug
NixOS/nix#11258 affects devenv docker versions with nix >= 2.23.0.
I am encountering the same bug, where fetching gets stuck on specific packages for no apparent reason (e.g. stdenv-linux
and other ones) .
I would be happy to know if there could be any workarounds for this, the only one I can think of is rolling back to devenv < 1.4, and building the docker image manually, but since 1.4 brought a lot of fixes / changes, I'm afraid of the drawbacks.
To reproduce
See NixOS/nix#11258 under "Steps to Reproduce".
In my case, this is are my devenv.nix and devenv.yml files:
{ pkgs, lib, config, inputs, ... }:
{
languages = {
rust = {
enable = true;
channel = "stable";
components = [ "rustc" "cargo" "clippy" "rustfmt" "rust-analyzer" ];
};
};
env = {
LIBCLANG_PATH = "${pkgs.libclang.lib}/lib";
BINDGEN_EXTRA_CLANG_ARGS = ''-I"${pkgs.glibc.dev}/include"'';
LD_LIBRARY_PATH = lib.makeLibraryPath [ pkgs.llvm_18 pkgs.clang_18 pkgs.libclang.lib ];
};
git-hooks.hooks = {
clippy.enable = true;
rustfmt.enable = true;
cargo-check.enable = true;
};
packages = [ pkgs.protobuf_29 pkgs.sqlx-cli pkgs.gcc pkgs.clang pkgs.libclang pkgs.glibc.dev ];
}
inputs:
fenix:
url: github:nix-community/fenix
inputs:
nixpkgs:
follows: nixpkgs
nixpkgs:
url: github:cachix/devenv-nixpkgs/rolling
I am encountering the issue in gitlab CI, so for reference, here is my .gitlab-ci.yml
file:
image: ghcr.io/cachix/devenv/devenv:latest
stages:
- build
- test
- lint
default:
tags:
- docker-devenv-personal
before_script:
- devenv ci --log-format tracing-pretty --verbose
variables:
CARGO_HOME: "$CI_PROJECT_DIR/.cargo"
RUST_BACKTRACE: full
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- target/
- .cargo/
build:
stage: build
script:
- echo "Building release..."
- cargo build --release
test:
stage: test
script:
- echo "Running tests..."
- cargo test
lint:
stage: lint
script:
- echo "Running format and clippy checks..."
- cargo fmt -- --check
- cargo clippy -- -D warnings
Version
Tried with the latest
and v1.5.2
registry tags.