Skip to content
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

file extension of data input yaml #89

Open
udeved opened this issue Feb 16, 2017 · 4 comments
Open

file extension of data input yaml #89

udeved opened this issue Feb 16, 2017 · 4 comments

Comments

@udeved
Copy link

udeved commented Feb 16, 2017

Hi,

as opposed to ruby version of kwalify, pykwalify unfortunately does not take for example a data.conf in yaml format.

I can validate a data.conf against a data.schema.yaml in ruby, but in python version, I would need to change file extension to make it work.
Could this be enhanced to accept other than strict *.yaml extension?

@Grokzen
Copy link
Owner

Grokzen commented Feb 16, 2017

@udeved Is it throign hard error when not using .yaml extension or is it becuase it do not understands the data inside the file? If indeed this feature works in kwalify then it is a candidate for implementing even tho if i do not like the idea that much. But if this version should be a superset of kwalify then i guess in it will go.

Is .conf the only other supported file extension or is there no validation on the input file type in the ruby version?

@udeved
Copy link
Author

udeved commented Feb 16, 2017

The data yaml is valid, the schema yaml exists for the data yaml.
To explain, I use currently ruby version to validate calamares data.conf against its data.schema.yaml.
The calamares installer uses yaml with *.conf file extension.

https://github.com/calamares/calamares-tools

@udeved
Copy link
Author

udeved commented Feb 19, 2017

Is .conf the only other supported file extension or is there no validation on the input file type in the ruby version?

There doesn't seem to be validation on file extension.

I tested by renaming data.conf to data.ini

$ kwalify -lf schemas/fstab.schema.yaml -m data/fstab.conf
data/fstab.conf#0: valid.

$ kwalify -lf schemas/fstab.schema.yaml -m data/fstab.ini
data/fstab.ini#0: valid.

@sdruskat
Copy link

A fix has been implemented in #119 and works in the http://github.com/sdruskat/pykwalifire fork 1.7.0.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants