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

Implement standard utility to read container config #238

Closed
mih opened this issue Oct 9, 2023 · 0 comments · Fixed by #242
Closed

Implement standard utility to read container config #238

mih opened this issue Oct 9, 2023 · 0 comments · Fixed by #242

Comments

@mih
Copy link
Member

mih commented Oct 9, 2023

This is implemented individually in many places. This makes it needlessly hard to fix #224, where we decided to normalize on write and convert to platform specs on read. Given that all commands at least read the config, and standard helper will simplify things

@mih mih changed the title Implement standard utility to read write container config Implement standard utility to read container config Oct 10, 2023
mih added a commit to mih/datalad-container that referenced this issue Oct 10, 2023
This is a plain code move from `containers_list` into a standalone function.
Added value is

- reusability
- documentation, incl. type annotation

Also adds rendering of the utility module's documentation.

This is a first step towards resolving datalad#238
mih added a commit to mih/datalad-container that referenced this issue Oct 10, 2023
This is a common use case in commands other than `containers_list`.
Albeit not strictly necessary (all configuration could be read
and processed first, and sub-selection could happen in user code),
it is a low-complexity change. Moreover, we envision more configuration
post-processing to happen in the future
(see datalad#238). This
would change the cost assessment of loading everything upfront.
mih added a commit to mih/datalad-container that referenced this issue Oct 10, 2023
This is the last change for establishing `get_container_configuration()`
as the single code piece for reading container documentation.

This opens the door for implementing on-read normalization of
configuration items, such as the image path.

Closes datalad#238
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

Successfully merging a pull request may close this issue.

1 participant