Skip to content

Installer doesn't update nixpkgs flake input correctly #204292

@roberth

Description

@roberth

Describe the bug

Weird input resolution behavior that's uncharacteristic for a distro that emphasizes being reproducible and boring.

Steps To Reproduce

Steps to reproduce the behavior:

  1. install nixos 22.11 with the minimal installer
  2. nix flake init in /etc/nixos
  3. add nixosConfigurations."nixos" = nixpkgs.lib.nixosSystem { modules = [ ./configuration.nix ]; }
  4. boot into installation
  5. nixos-rebuild switch
  6. we're now running nixos 23.05 (unstable). Ok?
  7. be unhappy about the partition layout and learn that a graphics driver fix landed in the release
  8. boot into installer to perform an offline fs shrinking and partition table configuration update
  9. nix flake lock --update-input nixpkgs to update the graphics driver
  10. boot into installation
  11. graphics driver is still the old version
  12. install Pop! OS

Expected behavior

At (6), do not upgrade to nixos-unstable.

At (9), do not downgrade to the installer nixpkgs

Suggested solution

Remove the flake registry from NixOS to solve (9)

Remove the flake registry from Nix, so that the user must specify the channel, solving (6) and (9).

Screenshots

Additional context

Notify maintainers

Metadata

NixOS 22.11 minimal ISO
Nix 2.11.0
Nix 2.11.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: bugSomething is broken2.status: stalehttps://github.com/NixOS/nixpkgs/blob/master/.github/STALE-BOT.md6.topic: flakesThe experimental Nix feature6.topic: nixosIssues or PRs affecting NixOS modules, or package usability issues specific to NixOS6.topic: user experienceNixOS / Nixpkgs end user experience
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions