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

Allow passing common_props in Dataset.add_component/add_table #180

Open
xrotwang opened this issue Sep 24, 2024 · 0 comments
Open

Allow passing common_props in Dataset.add_component/add_table #180

xrotwang opened this issue Sep 24, 2024 · 0 comments

Comments

@xrotwang
Copy link
Contributor

We often use code like

t = cldf.add_component(...)
t.common_props['dc:description'] = ...

This could be written more concisely with an API that allowed passing data to be used in common_props. While this could be done in a generic way, just funneling **kwargs to common_props, arguably the most often used property is dc:description, which cannot be used as keyword argument name in Python. Thus, just adding one keyword argument description to Dataset.add_component|add_table might hit the sweet spot here.

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

No branches or pull requests

1 participant