fix(s3-followup): enforce V5 rule 4 + mark H3/H4/H5/V5/V6 done
All checks were successful
C++ Tests / test-fast (pull_request) Successful in 8m47s
C++ Tests / quality-gates (pull_request) Has been skipped
C++ Tests / test-cgal (pull_request) Has been skipped

serialization.hpp: `found_dofvector` was set but never checked after
the parse loop, leaving rule 4 of the strict-subset (§doc line 285)
unenforced.  Add the missing post-loop throw so a ConformalResult XML
that omits the <DOFVector> element is rejected with a clear error
instead of silently returning an empty x.  Update the docstring to
remove the misleading "silently returns" note.

finding-orchestration.md: mark H3/H4/H5/V5/V6  and record the S3
session as complete.  Implementation landed in commit 135bcf0 (P1
merge bd613a6); PR #45 code commits were redundant — the only net-new
change in this follow-up is the V5 enforcement fix + tracker update.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Tarik Moussa
2026-06-01 14:27:21 +02:00
committed by Tarik Moussa
parent b67854645c
commit d3fc4ae056
2 changed files with 19 additions and 13 deletions

View File

@@ -283,8 +283,8 @@ inline void save_result_xml(
/// 3. A line containing `<DOFVector` must carry the `>` character (tag
/// open) on the same line.
/// 4. The `<DOFVector` element must be present and must produce a
/// non-empty doubles list (a missing DOFVector silently returns an
/// empty x, which is incorrect for any mesh with at least one DOF).
/// non-empty doubles list (a missing DOFVector element causes a
/// `std::runtime_error` — enforced after the parse loop).
inline std::vector<double> load_result_xml(
const std::string& path,
NewtonResult* res = nullptr,
@@ -386,6 +386,13 @@ inline std::vector<double> load_result_xml(
" Only the format written by save_result_xml is supported.");
}
// V5 rule 4: <DOFVector> must be present in every well-formed ConformalResult.
if (found_root && !found_dofvector)
throw std::runtime_error(
"conformallab: XML strict-subset violation in " + path
+ ": <DOFVector> element not found. Only the format written by"
" save_result_xml is supported.");
return x;
}