# Flat overrides and live creation probes Prerequisite: [addressing](../beginner/addresses.md) and [lifetimes](../beginner/lifetimes.md). A flat `override` supplies constructor inputs for the object being resolved. A factory can instead capture configuration at its registration site. The saved mailer lesson demonstrates both with concrete values. ## Choose where configuration belongs The factory returns a mailer configured for its fixed environment. The separately registered `many` class accepts `host` and `port` through `meld(override={...})`. Its assertions compare both resulting configurations. An override is not a new binding or a global configuration edit. Pair the choice with the intended instance lifetime; repeated reuse and fresh construction are different operations. Follow the complete script's lifetime choices first. ## Inspect before constructing `has_live_creation(...)` asks whether an addressed object already exists. The live-probe lesson checks `False` before its first meld and `True` afterward, then uses `describe_live_creation_status(...)` for detail. A diagnostic path can use these reads without using a meld merely to discover whether something is alive. Given a spell_id as `spell=`, both probes answer for exactly that version, also one a notch has parked or a copy borrowed from a linked conduit, while `meld` builds only the selected version. Continue to [deep overrides](../advanced/overrides.md) when the target is inside a dependency graph rather than a parameter of the object you are resolving. For a registered `resolvable=False` definition, supply its consumer's value through the same override API. The supplied object remains your reference; this does not transfer lifecycle ownership. Missing ordinary required arguments use Python's normal constructor error, including in cached execution. Existing whole-child overrides still eagerly construct registered children before replacement; they do not prune the child's constructor inputs. Plan for that existing behavior when replacing a branch. ## The workflow in code These are the core steps from the saved example. Use its complete linked script for all class definitions and setup. ```{literalinclude} ../downloads/02_intermediate/08_spell_override_construction.py :language: python :pyobject: main :linenos: ``` ## Runnable examples - [Spell override construction](../examples/intermediate/08-spell-override-construction.md) — Intermediate 08 - [Live creation probe](../examples/intermediate/18-live-creation-probe.md) — Intermediate 18 [All intermediate examples](../examples/intermediate/index.md) · [Level contents](index.md) · [Full contents](../contents.md) [Canonical page source](https://github.com/Synaptic724/melder/blob/1211e838099a342c9dde48f064b1e772b6060e13/docs/intermediate/overrides.md)