Conversation
gamma_tip, radius, le_interp, te_interp, area_interp, inertia_tensor and T_cad_body were left at their empty defaults when ObjWing became obj_to_yaml + Wing(yaml), so reading the spanwise geometry off an OBJ wing hit nothing and the wing's inertia fell back to point masses. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KPJmueyiyGSNpN73BATMuH
Four unrefined sections span the kite in 1.1 m steps, which is looser than the centre-of-mass offset the assertion is there to catch. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KPJmueyiyGSNpN73BATMuH
UNCHANGED keeps the sections the geometry file carries, so asking it for 20 panels indexes past the fourth. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KPJmueyiyGSNpN73BATMuH
ObjWing kept spanwise_distribution=UNCHANGED, which keeps whatever sections the geometry file carries, so asking for more panels than it has sections threw a BoundsError out of compute_refined_panel_mapping!. crease_frac reached the polar generation but not the Wing, which flew the 0.75 default instead. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012tnxXN2aT3F7zwCbsXd6Sb
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
7 tasks
makedocs checks every docstring in the modules it is given, so the new one failed the build twice over: missing from any canonical @docs block, and the @ref to it in the Wing(yaml) docstring had nothing to point at. Its own @ref to Wing is qualified because ObjAdapter imports the module, not the type. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TL;DR
ObjWingreturns aWingwithgamma_tip,radius,le_interp,te_interp,area_interp,inertia_tensorandT_cad_bodyleft at their empty defaults, flying the defaultcrease_fracrather than the one its polars were deflected about, and keeping whatever sections the geometry file holds however many panels the caller asked for. All three are v4.0.0 rebuilding it asObjAdapter.obj_to_yaml+Wing(yaml): the YAML loader has no mesh to fill the seven fields from, and two keywords stop at the polar generation.The seven empty fields
v3's
ObjWingfilled all seven itself. Since v4.0.0 a caller reading the spanwise geometry off an OBJ wing —wing.le_interp[i](gamma)is how a bridle is placed on one — hitsnothing, and the wing's inertia silently falls back to point masses.ObjAdapter.seed_mesh_geometry!fills them from the mesh, reusingread_faces,center_to_com!,find_circle_center_and_radius,create_interpolationsandcalculate_inertia_tensorin the order v3 called them. No new geometry code.The frame is the risk worth reading. The interpolations are built on the mesh's own coordinates, not centred on the centre of mass the way v3 built them, because that is the frame
obj_to_yamlcuts its sections in. A wing whose interpolations and sections disagreed by the centre of mass would place a bridle 0.7 m off the panels it loads. The new testset asserts the two agree at the centre.center_to_com!is called on a copy of the vertices: it centres what it is given, and here only the value is wanted.The crease and the panelling
crease_fracreachedobj_to_yaml, so the polars are deflected about it, but not theWing, which flew the 0.75 default — the YAML route (Wing(settings::VSMSettings)) already forwards it. Andspanwise_distributiondefaulted toUNCHANGED, which keeps the sections the geometry file carries: asking for more panels than it holds sections throwsBoundsError: attempt to access 4-element Vector{Section{Float64}} at index [5]out ofcompute_refined_panel_mapping!. It now defaults toLINEAR, which is identical when the counts match and panels the cut when they do not.Surprise
ObjWingaccepted a path without the.objsuffix and onlyobj_to_yamlappended it, so the mesh was read under a different name than the one the caller passed. The suffix is now normalised inObjWingitself.Verification
crease/panelling testset errors on unchanged code with theBoundsErrorabove;wing.le_interpisnothingtest/ram_geometry/test_kite_geometry.jlred before, green after: 34/34, of which 13 are the two new testsets (juliaserver)1fb4224with[:missing_docs, :cross_references]—makedocschecks every docstring in the modules it is given, andseed_mesh_geometry!was in no@docsblock — and green oncbfc328, which puts it on the private-functions page;docs/make.jlalso runs clean locallycbfc328: every check greenread_facesand one circle fit perObjWingcall, against the NeuralFoil sweep that dominates it.LINEARdefault. It changes nothing for a caller whose geometry already hasn_panels + 1sections, which is whatObjWinggenerates unlessn_sectionsis passed.Scope
+101 / −8 across 5 files. The
@test_skipintest/ram_geometry/test_kite_geometry.jlsaid theseObjWinginternals "were dropped when ObjWing was replaced by convert-then-load" and asked for the test to be rebuilt; it is, against the cachedram_air_matrix_dir()geometry, so neither new testset costs a NeuralFoil sweep.Found by upgrading OpenSourceAWE/RamAirKites.jl to SymbolicAWEModels 0.17 (OpenSourceAWE/RamAirKites.jl#43), where
SymbolicAWEModels.calc_pos— the function that places a ram-air kite's bridle along the span — throwsMethodError: no method matching getindex(::Nothing, ::Int64)onwing.le_interp. That upgrade also needs OpenSourceAWE/SymbolicAWEModels.jl branchagent/RamAirKites.jl-43, which is independent of this one and green on the registered 5.1.1.From OpenSourceAWE/RamAirKites.jl#43 · task
RamAirKites.jl-43