Official Codebase of 3DCodeVerse
Python
languages: the merge shadowed three names, and one of them mattered
gaoypengc8504c05ed12
diff --git a/harness/codeverse/languages/glsl_shader/__init__.py b/harness/codeverse/languages/glsl_shader/__init__.pyindex e3c27b55..3816bdd2 100644--- a/harness/codeverse/languages/glsl_shader/__init__.py+++ b/harness/codeverse/languages/glsl_shader/__init__.py@@ -59,7 +59,6 @@ _BLOCK_COMMENT = re.compile(r"/\*.*?\*/", re.S)_LINE_COMMENT = re.compile(r"//[^\n]*")_MAIN_IMAGE = re.compile(r"\bvoid\s+mainImage\s*\(")_PLAIN_MAIN = re.compile(r"\bvoid\s+main\s*\(\s*(void)?\s*\)")-_OUT_DECL = re.compile(r"\bout\s+vec4\s+\w+\s*;")@dataclassdiff --git a/harness/codeverse/languages/urdf/__init__.py b/harness/codeverse/languages/urdf/__init__.pyindex 913213c8..e7a0f02c 100644--- a/harness/codeverse/languages/urdf/__init__.py+++ b/harness/codeverse/languages/urdf/__init__.py@@ -49,16 +49,10 @@ from codeverse.workspace import ArtifactStage, Workspace# ===================================================================== consistency# (merged from codeverse/languages/urdf/consistency.py, 2026-08-28)-GATE = "fk_consistency"---def _fmt(v: float) -> str:- s = f"{v:.6f}".rstrip("0").rstrip(".")- return "0" if s in ("", "-0") else s---def _vec(v) -> str:- return " ".join(_fmt(float(x)) for x in v)+#: this gate's own name — a bare ``GATE`` here was shadowed by the lint section's+#: ``GATE = "lint:urdf"`` 59 lines below when the package became one module (2026-08-28),+#: so every FK finding went out mislabelled until 2026-08-28.+FK_GATE = "fk_consistency"def check_fk_consistency(robot: Robot, census_links: dict[str, dict[str, Any]], *, tol_m: float = 0.001) -> list[GateFinding]:@@ -73,7 +67,7 @@ def check_fk_consistency(robot: Robot, census_links: dict[str, dict[str, Any]],continuerow = census_links.get(name)if row is None:- out.append(GateFinding(gate=GATE, severity=Severity.ERROR, target=name,+ out.append(GateFinding(gate=FK_GATE, severity=Severity.ERROR, target=name,message=f"link '{name}' has no authored mesh in census (wrapper exported nothing for it)",fix_hint=f"Create a mesh object named exactly '{name}' in model.py."))continue@@ -90,7 +84,7 @@ def check_fk_consistency(robot: Robot, census_links: dict[str, dict[str, Any]],cur_rpy = matrix_to_rpy(link.visual_origin[:3, :3])frame_xyz = T[name][:3, 3]out.append(GateFinding(- gate=GATE, severity=Severity.ERROR, target=name,+ gate=FK_GATE, severity=Severity.ERROR, target=name,message=(f"link '{name}': FK at q=0 puts the mesh at bbox [{_vec(fk_min)}]..[{_vec(fk_max)}] but model.py authored it at "f"[{_vec(au_min)}]..[{_vec(au_max)}] (max error {err*1000:.1f} mm). Its link frame is at world "f"[{_vec(frame_xyz)}] so the visual origin must be the inverse: xyz=\"{_vec(xyz_fix)}\" "