[Bug 366831] api does not keep order of <path> entries