chore: adopt remaining local development state

Catch-all for the intermixed residue of the unpushed otko-development
work ported into this tree: combinations/console-dock/quick-guide wiring
across commands, core, services, views and tests; repo-wide ruff-format
normalization; README/CONTRIBUTING updates; and the toolbar default
(both toolbars now open in the top area, quick guide text updated).

Splitting this further would require hunk-level surgery with low
confidence; the preceding commits in this branch isolate the
self-contained features.
This commit is contained in:
smillmorel 2026-09-16 12:03:22 -04:00
commit ba783718d4
152 changed files with 3394 additions and 1651 deletions

View file

@ -9,6 +9,8 @@ pytest.importorskip("openseespy")
from otko.services import load_project # noqa: E402
from otko.services.opensees_runner import OpenSeesRunner # noqa: E402
pytestmark = pytest.mark.slow
def test_moment_curvature_example_round_trips_and_converges(tmp_path) -> None: # type: ignore[no-untyped-def]
"""build_moment_curvature() → save → load → run → expected shape."""
@ -21,11 +23,13 @@ def test_moment_curvature_example_round_trips_and_converges(tmp_path) -> None:
MU,
NUM_INCR,
)
proj = build_moment_curvature()
proj.validate_references()
# Save + reload — catches schema drift.
from otko.services import save_project
path = tmp_path / "mk.osmodel"
save_project(proj, path)
reloaded = load_project(path)
@ -39,15 +43,14 @@ def test_moment_curvature_example_round_trips_and_converges(tmp_path) -> None:
ky = (FY / E_STEEL) / (0.7 * d)
# At least half of the NUM_INCR pushover steps converged.
assert len(result.control_disp) > NUM_INCR * 0.5, (
"Pushover bailed out prematurely — check Concrete01 softening"
)
assert (
len(result.control_disp) > NUM_INCR * 0.5
), "Pushover bailed out prematurely — check Concrete01 softening"
# Reached the mu * Ky target.
assert result.control_disp[-1] == pytest.approx(MU * ky, rel=1e-2)
# Moment at yield curvature is plausible: > 3 kip·in and < 10 kip·in per rebar
# → for 8 bars total, the section moment capacity is roughly O(3000-6000) kip·in.
peak_moment = max(abs(m) for m in result.base_shear)
assert 2000 < peak_moment < 10000, (
f"Peak moment {peak_moment:.1f} kip·in is outside the "
"expected RC section range"
f"Peak moment {peak_moment:.1f} kip·in is outside the " "expected RC section range"
)