Skip to content

fix(nix): use stdenv.hostPlatform.isLinux instead of the deprecated alias - #397

Merged
eval-exec merged 1 commit into
mainfrom
fix/nix-stdenv-host-platform
Sep 18, 2026
Merged

eval-exec merged 1 commit into
mainfrom
fix/nix-stdenv-host-platform

Conversation

@eval-exec

Copy link
Copy Markdown
Owner

Nixpkgs now throws a deprecation warning on every access of stdenv.isLinux / stdenv.isDarwin. nix develop printed five of them because the overlay, package, and dev shell all evaluated those aliases:

evaluation warning: stdenv.isLinux is deprecated, use stdenv.hostPlatform.isLinux instead

Replace every remaining use with stdenv.hostPlatform.isLinux / stdenv.hostPlatform.isDarwin. Platform selection is unchanged.

Files:

  • nix/modules/overlays.nix
  • nix/modules/dev-shells.nix
  • nix/dev-shell.nix
  • nix/dependencies.nix
  • nix/package.nix
  • nix/production-capabilities.nix
  • nix/checks/default.nix

Verification:

  • nix develop --command true no longer prints the stdenv.isLinux evaluation warnings.

…lias

Nixpkgs now throws a deprecation warning on every access of
stdenv.isLinux / stdenv.isDarwin. nix develop printed five of them
because the overlay, package, and dev shell all evaluated those
aliases.

Replace every remaining use with stdenv.hostPlatform.isLinux /
stdenv.hostPlatform.isDarwin. Platform selection is unchanged.

Verified: nix develop --command true no longer prints the
stdenv.isLinux evaluation warnings.
@eval-exec
eval-exec marked this pull request as ready for review September 18, 2026 13:23
Copilot AI balanced review requested due to automatic review settings September 18, 2026 13:23
@eval-exec
eval-exec merged commit d5b6a0d into main Sep 18, 2026
80 of 103 checks passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The change is a mechanical, semantics-preserving alias replacement, and a repo-wide search confirms no deprecated stdenv.isLinux/stdenv.isDarwin uses remain.

Pull request overview

This PR replaces the deprecated Nixpkgs aliases stdenv.isLinux / stdenv.isDarwin with their canonical forms stdenv.hostPlatform.isLinux / stdenv.hostPlatform.isDarwin across the repository's Nix expressions. Recent Nixpkgs emits an evaluation deprecation warning on every access of the old aliases, which caused nix develop to print several warnings. The aliases are functionally identical to the hostPlatform accessors, so platform selection logic is unchanged.

Changes:

  • Swap all remaining stdenv.isLinux / stdenv.isDarwin uses for stdenv.hostPlatform.isLinux / stdenv.hostPlatform.isDarwin.
  • No semantic changes: the aliases resolve to the same hostPlatform predicates.
  • A repo-wide search confirms no deprecated aliases remain in any .nix file.
File summaries
File Description
nix/production-capabilities.nix Uses hostPlatform predicates for the platform-selection branch.
nix/package.nix Updates Darwin/Linux optionals and the Linux desktop-asset install step.
nix/modules/overlays.nix Updates the WPE-WebKit Linux gating in the overlay.
nix/modules/dev-shells.nix Updates the wpeWebkit Linux gate for the default dev shell.
nix/dev-shell.nix Updates the local isLinux / isDarwin bindings.
nix/dependencies.nix Updates Linux-only build-input optionals.
nix/checks/default.nix Updates Linux assertions and check-phase conditionals.
Review details
  • Files reviewed: 7/7 changed files
  • Comments generated: 0
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

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