-
Notifications
You must be signed in to change notification settings - Fork 34
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
Support LookML generation from Python objects #14
Comments
The serializer should descend recursively through the Python object, outputting strings to a string buffer using the following rules:
A major challenge: I have no way of knowing from the object which values in pairs or sets should be serialized as quoted literals ( |
One potential avenue to explore re: quoted vs. unquoted literals--does Looker expose their parameter documentation via API? The web based documentation seems to contain the necessary information in the If the API solution was available, you could imagine using a scheduled CircleCI workflow to check for new keys and the Github API to create a PR adding the new parameters. This could almost eliminate the maintenance hassle. |
It's an exciting idea, but as far as I can tell, Looker does not expose any kind of documentation resources via their API. I've run tests against my trove of public GitHub LookML and fixed all issues with quoted keys, so I'm confident that |
It would be useful to have a
dump
function similar to other Python packages likejson
andyaml
. This function would accept a Python object and would serialize it into a string of LookML, the exact opposite of theload
function.In my opinion,
lkml
should not be responsible for generating LookML that is always functional in Looker (e.g. valid property names). The only requirement is that the generated LookML can also be parsed successfully withlkml
.The text was updated successfully, but these errors were encountered: