openPMD-standard
openPMD-standard copied to clipboard
Paths: End on /
First seen in https://github.com/openPMD/openPMD-validator/issues/43
Should we define that all paths end on /
in the standard?
I think imposing the final
/
makes implementations easier (good!) while cluttering the standard with details a little. A path join operation is in principle the logical way to implement it (available in Python and modern C++) which then would be agnostic. Nevertheless some very rudimentary languages might not have such high-level functionality.The example currently shows a trailing
/
and I think it might make things indeed easier for implementations which I favor for the community.
OK with me.
Implementation convenience aside, this adds desirable semantic clarity. Enforcing path-terminators makes paths obvious in all places. Paying one character in return for this expressiveness should be worth it.
Nevertheless some very rudimentary languages might not have such high-level functionality.
We should try to keep this standard agnostic to the standard library support of any language. Should a (sane) code written in those languages implement funtionality involving paths, verification and normalization should be performed, anyway. Whether there is an additional slash or not will not have a significant impact.