f3d: [nixpkgs] Trying to set the "watch" option in the configuration file seems to be ignored

Describe the bug I am most of the time using f3d with the watch option so I wanted to enable it through the configuration file.

To Reproduce Here is the configuration file I am using:

{
        ".*": {
                "ambient-occlusion": true,
                "axis": true,
                "camera-direction": "1,1,-1",
                "grid": true,
                "grid-absolute": true,
                "up": "+Z",
                "watch": true
        }
}

All options seem to be taken into account but the watch option.

Expected behavior The documentation about the configuration file states:

The following options cannot be set via config file: help, version, readers-list, config, dry-run and input.

So I expected watch to be set via config file.

System Information:

  • OS: Linux 6.6.62 NixOS SMP PREEMPT_DYNAMIC Sun Nov 17 14:08:59 UTC 2024 x86_64 GNU/Linux
  • GPU and GPU driver: I have no idea, providing a command to retrieve this information would be helpful.

F3D Information Paste the content of f3d --version:

F3D 2.5.0

F3D - A fast and minimalist 3D viewer
Version: 2.5.0.
Build date: 1980-01-01 00:00:00.
Build system: Linux 64-bits.
Compiler: GNU 13.3.0.
External rendering module: ON.
Raytracing module: OFF.
VTK version: 9.2.6.
Copyright (C) 2019-2021 Kitware SAS.
Copyright (C) 2021-2024 Michael Migliore, Mathieu Westphal.
License BSD-3-Clause.
By Michael Migliore, Mathieu Westphal and Joachim Pouderoux.

Additional context Add any other context about the problem here.

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Comments: 21 (13 by maintainers)

Most upvoted comments

Hello,

Thank you all for debunking the issue and providing the right explanation 👍 So I will be using the “global” part for now instead of .*. Have a nice day!

It works in XDG_CONFIG_HOME when using "global", but not when using ".*"

More progress!

Well Im glad to say this issue is already fixed, and I should have caught it on the first post.

Indeed, this option MUST be set in the “global” part. However we removed that limitation in the development version of F3D, but our documentation (https://f3d.app) is about the developement version of F3D, not our last release, this is why this limitation is not mentionned there (anymore).

related issue: https://github.com/f3d-app/f3d/issues/845

TLDR: Set watch option in global config for 2.5.0 version of F3D, or use the development version (nightly) of F3D that does not have this limitation (or a global config block at all).

share/f3d/configs/config.d/10_global.json works as if i had added --watch, the issue must be with the one in $XDG_CONFIG_HOME/f3d/config.json

I had no idea!

I’ll assume this is a nixpks specific issue then, please let us know how it goes and if F3D can do anything to help!