Skip to content

pyflightstream.support (stable)

Generated from the docstrings at build time: every one of the 9 names in the __all__ of pyflightstream.support has an entry below. The names a guide or an example uses come first; the others follow under Advanced.

What "supported" means, per registered FlightStream version.

Pipeline role: cross-cutting reporting layer above the script builder. It answers one question the rest of the package could only answer by implication, and answers it in named values rather than in prose.

A version's presence in commands/_meta.yaml establishes registration, not command coverage or a buildable workflow. Derive its support level from available command evidence and the minimal workflow (FR-49).

The four levels, and every one of them is DERIVED. Nothing here is declared in a file, because a hand-set support level is exactly the kind of claim that outlives the fact behind it:

registered In the ordered list, and no command is available. The identifier exists so that campaigns naming it are refused by name rather than by accident, and so evidence can be backfilled later. documented Commands are available, drafted from the manual with page citations. No command has been measured against a running solver on this version. verified At least one command carries probe evidence this version can reach: a committed report either confirmed it or recorded it broken. Both count, because both are measurements. On a hotfix build the record may be the base release's, inherited: see :meth:~pyflightstream.commands.CommandEntry.evidence_in and the compatibility matrix, which marks every inherited cell. operational Verified, and the minimal end-to-end workflow of :func:minimal_workflow builds for it. This is the level that claims a user can actually get from geometry to a loads file.

The ladder is ordered and total: every registered version sits at exactly one level, and the levels ascend in the order above.

Why operational is not simply "verified plus some commands": the review asked for a level whose claim is checkable end to end, and a version can carry probe evidence for a scattering of commands while lacking one link of the chain that produces a result. So the level is defined by a workflow that builds, and a tier 1 test builds it for every version this module reports operational. The claim and its check are the same object.

Used in the guides

pyflightstream.support.support_level

support_level(
    version: str | FsVersion,
    *,
    registry: CommandRegistry | None = None,
) -> SupportLevel

Return the support level of one registered version.

Shorthand for :func:version_support's level, for the caller who wants the value and not the evidence behind it.

Parameters:

Name Type Description Default
version str or FsVersion

Target version.

required
registry CommandRegistry

Alternative database, used by tests.

None

Returns:

Type Description
SupportLevel

The derived level.

Examples:

>>> support_level("26.124").value
'operational'

pyflightstream.support.support_table

support_table(
    *, registry: CommandRegistry | None = None
) -> tuple[VersionSupport, ...]

Report every registered version, in release order.

Release order comes from commands/_meta.yaml, which is the only ordering authority (CONTRIBUTING.md invariant 4). It is NOT support order. The two agree at this release only because the builds split cleanly by age: the ones whose manuals have been read but whose solvers have not been probed derive documented, and the probed ones derive operational. No tally is written here, because it moves with every build registered. They came apart as recently as the package's own development, when 26.100 sat at verified behind both of its successors for want of database rows rather than for anything about the solver, and nothing prevents them coming apart again the moment a build is registered ahead of its evidence. Read the level off the row, never off the position.

Parameters:

Name Type Description Default
registry CommandRegistry

Alternative database, used by tests.

None

Returns:

Type Description
tuple of VersionSupport

One row per registered version, oldest release first.

Examples:

>>> from pyflightstream.support import support_table
>>> {row.canonical: str(row.level) for row in support_table()}["26.000"]
'documented'

Advanced

pyflightstream.support.MINIMAL_WORKFLOW_COMMANDS module-attribute

MINIMAL_WORKFLOW_COMMANDS: tuple[str, ...] = (
    "NEW_SIMULATION",
    "IMPORT",
    "SET_SIMULATION_LENGTH_UNITS",
    "AUTO_DETECT_TRAILING_EDGES",
    "SET_FREESTREAM",
    "FLUID_PROPERTIES",
    "INITIALIZE_SOLVER",
    "SOLVER_SET_AOA",
    "SOLVER_SET_VELOCITY",
    "SOLVER_SET_REF_VELOCITY",
    "SOLVER_SET_REF_AREA",
    "SOLVER_SET_REF_LENGTH",
    "SOLVER_SET_ITERATIONS",
    "START_SOLVER",
    "SET_LOADS_AND_MOMENTS_UNITS",
    "EXPORT_SOLVER_ANALYSIS_SPREADSHEET",
    "CLOSE_FLIGHTSTREAM",
)

pyflightstream.support.SUPPORT_LADDER module-attribute

SUPPORT_LADDER: tuple[SupportLevel, ...] = (
    SupportLevel.REGISTERED,
    SupportLevel.DOCUMENTED,
    SupportLevel.VERIFIED,
    SupportLevel.OPERATIONAL,
)

pyflightstream.support.SupportLevel

Bases: StrEnum

How far the evidence for one FlightStream version actually goes.

Ascending. See the module docstring for what each level requires; the definitions live there because they are one story rather than four.

pyflightstream.support.VersionSupport

Bases: BaseModel

The support level of one registered version, with its evidence.

Attributes:

Name Type Description
canonical str

Canonical identifier, for example "26.120".

alias str

Vendor release name. Not unique: the vendor ships every hotfix of a minor release under one name, so two rows can share it.

level SupportLevel

The derived level.

commands_available int

Commands the database exposes for this version, counting the ones recorded broken, because a broken command is a measured command.

commands_probed int

Of those, the ones carrying probe evidence (verified or broken) that this version can reach. On a hotfix build the count INCLUDES records inherited from the base release, so some of them were probed on that other build. This aggregate does not separately count direct and inherited measurements. The rendered compatibility matrix identifies inherited evidence per cell.

workflow_missing tuple of str

Commands of :data:MINIMAL_WORKFLOW_COMMANDS this version cannot emit, in workflow order. A build refusal that names no command is identified as minimal_workflow. Empty when the workflow builds.

summary str

One sentence naming the level and the reason for it, for a README table, a docs page or a console.

pyflightstream.support.WORKFLOW_ALTERNATIVES module-attribute

WORKFLOW_ALTERNATIVES: dict[str, str] = {
    "AUTO_DETECT_TRAILING_EDGES": "DETECT_TRAILING_EDGES_BY_SURFACE"
}

pyflightstream.support.minimal_workflow

minimal_workflow(
    version: str | FsVersion,
    *,
    geometry: str = "wing.stl",
    output: str = "loads.txt",
    registry: CommandRegistry | None = None,
) -> Script

Build the smallest complete script that produces a result.

Geometry in, solver initialized, solution run, loads exported. It is the reference answer to "does this version work at all", and the definition of the operational support level: a version is operational when this builds for it.

Every value in it is a placeholder except the fluid state, which is the sea-level standard atmosphere. The script is validated against the version like any other, so a version missing one link refuses here, naming the command.

Parameters:

Name Type Description Default
version str or FsVersion

Target version, canonical identifier or a vendor name that identifies exactly one registered build.

required
geometry str

Mesh file the script imports. Not read: the builder emits a path, it never opens one.

'wing.stl'
output str

Loads spreadsheet the script exports.

'loads.txt'
registry CommandRegistry

Alternative database, used by tests.

None

Returns:

Type Description
Script

The built script, ready to render.

Raises:

Type Description
CommandNotInVersionError

If the version cannot emit one of the workflow's commands. The message names which, and that is the honest answer to whether the version is usable.

Examples:

>>> from pyflightstream.support import minimal_workflow
>>> print(minimal_workflow("26.120").render().splitlines()[0])
NEW_SIMULATION

pyflightstream.support.version_support

version_support(
    version: str | FsVersion,
    *,
    registry: CommandRegistry | None = None,
) -> VersionSupport

Report the support level of one registered version, with its evidence.

Parameters:

Name Type Description Default
version str or FsVersion

Target version, canonical identifier or an unambiguous vendor name.

required
registry CommandRegistry

Alternative database, used by tests.

None

Returns:

Type Description
VersionSupport

The level and the counts it was derived from.

Examples:

>>> from pyflightstream.support import version_support
>>> version_support("26.000").level
<SupportLevel.DOCUMENTED: 'documented'>