Need to uninstall dev-python/jsonschema before being able to install. Building while one version of dev-python/jsonschema-{2.6.0,3.0.1} is installed leads to: FAILED: data/CMakeFiles/validate_noiseprofiles_json cd /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data && /usr/bin/jsonschema -i /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/noiseprofiles.json /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/noiseprofiles.schema usage: jsonschema [-h] [-i INSTANCES] [-F ERROR_FORMAT] [-V VALIDATOR] schema jsonschema: error: argument -i/--instance: invalid _json_file value: '/var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/noiseprofiles.json' Reproducible: Always Steps to Reproduce: 1/ emerge jsonschema 2/ emerge darktable
(In reply to Samuel Bauer from comment #0) > FAILED: data/CMakeFiles/validate_noiseprofiles_json > cd /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data && > /usr/bin/jsonschema -i > /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/ > noiseprofiles.json > /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/ > noiseprofiles.schema > usage: jsonschema [-h] [-i INSTANCES] [-F ERROR_FORMAT] [-V VALIDATOR] schema > jsonschema: error: argument -i/--instance: invalid _json_file value: > '/var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/ > noiseprofiles.json' I cannot reproduce this particular error, but I had another problem during world upgrade and switching from python 3.6 to 3.7 at the same time: FAILED: data/CMakeFiles/validate_noiseprofiles_json cd /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data && /usr/bin/jsonschema -i /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/noiseprofiles.json /var/tmp/portage/media-gfx/darktable-2.6.2/work/darktable-2.6.2/data/noiseprofiles.schema Traceback (most recent call last): File "/usr/lib/python-exec/python3.6/jsonschema", line 6, in <module> from pkg_resources import load_entry_point ModuleNotFoundError: No module named 'pkg_resources'
Cannot reproduce this using jsonschema-3.2.0 so I assume the problem has gone away, that said it IS an issue that the behaviour of 'emerge media-gfx/darktable' changes depending on whether a tool that is not on the list of dependencies is present or not. I think I may simply just remove the relevant CMake statements, the noise-profile file is bundled in the release tarballs so there is no benefits to end users - either it is good or it is bad.
(In reply to Marek Szuba from comment #2) > I think I may simply just remove the relevant CMake statements, the noise- > profile file is bundled in the release > tarballs so there is no benefits to > end users - either it is good or it is bad. Yeah, would be nice. Since there is no dependency on dev-python/jsonschema, there is no guarantee that the jsonschema tool will be in usable state (all runtime dependencies satisfied) at the build time of media-gfx/darktable.
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3752f6bbf46def9d267f353e8ee56b8a885c29b9 commit 3752f6bbf46def9d267f353e8ee56b8a885c29b9 Author: Marek Szuba <marecki@gentoo.org> AuthorDate: 2020-06-18 15:42:08 +0000 Commit: Marek Szuba <marecki@gentoo.org> CommitDate: 2020-06-18 16:29:14 +0000 media-gfx/darktable-9999: add dev-python/jsonschema to BDEPEND In case of VCS snapshots it may make sense to have the noise-profile file validated, even though this really should be done in the test phase. Require 3.2.0+ because there may or may not have been problems with older versions currently in the tree (see the referenced bug), and no PYTHON_USEDEP and so on because we use this as an executable. Closes: https://bugs.gentoo.org/696996 Signed-off-by: Marek Szuba <marecki@gentoo.org> media-gfx/darktable/darktable-9999.ebuild | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Additionally, it has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d3af6414bfb05efb9ffdd53c71db287b00bed984 commit d3af6414bfb05efb9ffdd53c71db287b00bed984 Author: Marek Szuba <marecki@gentoo.org> AuthorDate: 2020-06-18 15:33:19 +0000 Commit: Marek Szuba <marecki@gentoo.org> CommitDate: 2020-06-18 16:29:10 +0000 media-gfx/darktable-3.0.2*: remove automagic dependency on jsonschema Darktable build scripts look for the jsonschema executable and if it is found, call it during installation to validate the noise-profile file - with no option available to control this behaviour. dev-python/jsonschema is not a dependency of media-gfx/darktable in my opinion adding it to release ebuilds doesn't make much sense - the noise-profile file is part of the release tarball, if it is bad there is nothing end users can do about it. Bug: https://bugs.gentoo.org/696996 Signed-off-by: Marek Szuba <marecki@gentoo.org> media-gfx/darktable/darktable-3.0.2-r1.ebuild | 1 + media-gfx/darktable/darktable-3.0.2.ebuild | 1 + .../files/darktable-3.0.2_jsonschema-automagic.patch | 19 +++++++++++++++++++ 3 files changed, 21 insertions(+)