Skip to content

pkgs-lib.formats: fixups for mkStructuredType#448871

Merged
Stunkymonkey merged 2 commits intoNixOS:stagingfrom
h7x4:pkgs-lib-mkstructuredvalue-fixup
Oct 5, 2025
Merged

pkgs-lib.formats: fixups for mkStructuredType#448871
Stunkymonkey merged 2 commits intoNixOS:stagingfrom
h7x4:pkgs-lib-mkstructuredvalue-fixup

Conversation

@h7x4
Copy link
Member

@h7x4 h7x4 commented Oct 5, 2025

Quick fixup for #372501, makes the function unreachable except for in formats.nix for the time being (there are plans to restructure pkgs-lib later, we might re-expose it in a more sane place than pkgs.formats then), adds missing parameter comment.

Ensured that it still evals with nix repl:

nix-repl> (legacyPackages.x86_64-linux.formats.json { }).type
{
  _type = "option-type";
  check = «lambda check @ /nix/store/vdmlkirf3asf5j8lkhhf08x66s33hh30-source/lib/types.nix:1042:19»;
  deprecationMessage = null;
  description = "JSON value";
  descriptionClass = "conjunction";
  emptyValue = { ... };
  functor = { ... };
  getSubModules = null;
  getSubOptions = «lambda @ /nix/store/vdmlkirf3asf5j8lkhhf08x66s33hh30-source/lib/types.nix:221:25»;
  merge = «lambda merge @ /nix/store/vdmlkirf3asf5j8lkhhf08x66s33hh30-source/lib/types.nix:1044:13»;
  name = "nullOr";
  nestedTypes = { ... };
  substSubModules = «lambda substSubModules @ /nix/store/vdmlkirf3asf5j8lkhhf08x66s33hh30-source/lib/types.nix:1059:29»;
  typeMerge = «lambda defaultTypeMerge @ /nix/store/vdmlkirf3asf5j8lkhhf08x66s33hh30-source/lib/types.nix:122:10»;
}

Things done

  • Built on platform:
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • Tested, as applicable:
  • Ran nixpkgs-review on this PR. See nixpkgs-review usage.
  • Tested basic functionality of all binary files, usually in ./result/bin/.
  • Nixpkgs Release Notes
    • Package update: when the change is major or breaking.
  • NixOS Release Notes
    • Module addition: when adding a new NixOS module.
    • Module update: when the change is significant.
  • Fits CONTRIBUTING.md, pkgs/README.md, maintainers/README.md and other READMEs.

Add a 👍 reaction to pull requests you find important.

@h7x4 h7x4 mentioned this pull request Oct 5, 2025
13 tasks
@nixpkgs-ci nixpkgs-ci bot added 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. labels Oct 5, 2025
@nixpkgs-ci nixpkgs-ci bot added the 12.approvals: 1 This PR was reviewed and approved by one person. label Oct 5, 2025
@nixpkgs-ci nixpkgs-ci bot added 12.approvals: 2 This PR was reviewed and approved by two persons. and removed 12.approvals: 1 This PR was reviewed and approved by one person. labels Oct 5, 2025
@Stunkymonkey Stunkymonkey merged commit 4bc5f6b into NixOS:staging Oct 5, 2025
33 of 35 checks passed
@h7x4 h7x4 deleted the pkgs-lib-mkstructuredvalue-fixup branch October 31, 2025 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

10.rebuild-darwin: 0 This PR does not cause any packages to rebuild on Darwin. 10.rebuild-linux: 1-10 This PR causes between 1 and 10 packages to rebuild on Linux. 12.approvals: 2 This PR was reviewed and approved by two persons.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants