Skip to content

refactor(workspace): friendlier eval error for invalid node module version #1080

Closed

Description

@gerchowl

Found during review of release PR #1068.

nodeAttr = "nodejs_${toString version}" — if version is mistakenly passed as a path or derivation, the eval error is Nix's generic "cannot coerce to string" rather than the module-scoped friendly throw used for other invalid inputs. Still fails at eval time; purely a diagnostics/ergonomics improvement.

Suggested: validate version is an int before interpolation and throw a module-scoped message.

File: nix/modules/node.nix:32

Activity

  1. added
    refactor
    priority:low
    area:workspace
    effort:small
    on Jul 14, 2026
  2. c-vigo commented on Jul 14, 2026

    @c-vigo
    Contributor

    Shipped in 1.2.0 via PR #1088.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:workspaceeffort:smallpriority:lowrefactor

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions