New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

assign/condition does not create key #2104

markus2330 opened this Issue Jun 20, 2018 · 3 comments


None yet
2 participants

markus2330 commented Jun 20, 2018

Steps to Reproduce the Problem

Given the specification (ni format):

assign/condition = (../points < '50') ? ('0') : ('1')

and the configuration (ini format):

points = 100

then run kdb global-mount conditionals
and then run kdb get /tests/test1/positiv

Expected Result

"1" because points is >= 50.

Actual Result

Did not find key

Workaround: create an empty key, then it works as expected.

System Information

  • Elektra Version: master
  • Operating System or Docker Container?
  • Versions of other relevant software?

Related Issues

Might be related to #1499?


This comment has been minimized.


tom-wa commented Jun 21, 2018

the spec plugin checks if tests/test?/positive matches any key, and if not, creates a key named tests/test?/positive (literally "test?") in this case.
so assign/conditional doesn't currently work with whitespaces.
it could be implemented, but i'm not sure how multiple not-existing levels below a wildcard key should be handled. e.g. tests/test?/sub/positive - should the spec plugin stop trying if tests/test?/sub is not found, or remove the basename until a matching key is found ?


This comment has been minimized.


markus2330 commented Jun 21, 2018

I see. Yes, I think we can assume the basename to be present for now and fill out the wildcards as they are for the basenames. It would at least fix the problems I have.


This comment has been minimized.


markus2330 commented Aug 6, 2018

Seems like the creation of default keys is also effected by this bug.

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