Warning: optionsDocBook is deprecated since 23.11 and will be removed in 24.05

I am experimenting with moving my existing NixOS configuration from 23.05 to unstable. I’m using channels, not flakes, so to do this I switched to the unstable nixos channel and also added the unstable home-manager channel (previously I simply used fetchTarball for home-manager). Now, when I nixos-rebuild I see three instances of the following warning:

warning: optionsDocBook is deprecated since 23.11 and will be removed in 24.05

Everything seems to work, so I could simply ignore this warning, but I’d rather know what’s causing it. My best guess is that it involves generating documentation for new options in my config files. I have four instances of lib.mkOption, and I’m curious if maybe the correct usage of that has changed since 23.05.

Example:

options = {
    identity = lib.mkOption {
      type = lib.types.attrsOf lib.types.anything;
      description = ''
      Attribute set for describing the user's identity. The following four
      keys are all required: username, fullname, email, hostname.'';
      example = ''
      {
        username = "john";
        fullname = "John Simonson";
        email = "john@simonson.com";
        hostname = "nixos";
      };'';
    };
  };

Thanks.

4 Likes

It is caused by HM, they haven’t fixed the warnings yet. And I hope they do it in time.

4 Likes

https://github.com/nix-community/home-manager/issues/4273

2 Likes

This is my fault, I’m afraid :slight_smile:

Like I said in the issue I aim to have this resolved by the time of the 23.11 stable release, but it requires some upstream Nixpkgs work that I haven’t yet been able to make the time for.

16 Likes

Thanks everyone. I thought this might be an issue on my end.

1 Like

Many thanks for all your hardwork @emily - do you still think this will make it into 23.11 stable? Thanks again!

thank you for spending time on this issue

i just wanted to make sure: these are just warnings, and they do not impact the functionality, at least not from the user’s perspective, correct?

I’m curious what the some upstream Nixpkgs work is or if there’s an issue somewhere to look at? I ask because perhaps one of us could help out if emily is too busy

edit: nvm. PR open render documentation without deprecated optionsDocBook by considerate · Pull Request #4673 · nix-community/home-manager · GitHub

render documentation without deprecated optionsDocBook by considerate · Pull Request #4673 · nix-community/home-manager · GitHub has been merged!

1 Like