Documentation
¶
Overview ¶
Package generation is the dependency-neutral generation I/O boundary. It authenticates publisher-validated artifacts by seal; semantic validation stays in export. It never imports graph, query, export, or an SQL driver.
Index ¶
- Constants
- func Adopted(out string) bool
- func Candidate(path string) (bool, error)
- func CanonicalRoot(root string) (string, error)
- func CheckInventory(m *types.Manifest) (stale []string, err error)
- func CheckLegacy(m *types.Manifest) (stale []string, err error)
- func CheckLegacyTargets(out string) error
- func DiscoverChildRoots(root string) ([]string, error)
- func Initialize(out string) error
- func Inventory(root string, req types.ManifestRequest) (*types.Manifest, []string, error)
- func LegacyWrite(out string, write func(string) error) error
- func ReadOnlyURI(path string) (string, error)
- func RefuseRemoval(target string) error
- func RegularFile(path string) ([]byte, error)
- func RequestFingerprint(req types.ManifestRequest) string
- func Sync(path string) error
- func ValidID(id string) bool
- func VerifySources(m *types.Manifest) (stale []string, err error)
- func WithRemoval(ctx context.Context, targets []string, effects func() error) error
- type Closure
- type Lock
- type Seal
- type Selection
Constants ¶
const BoundGoProfile = "captured-go-structural-v1"
const ChildDiscoveryFingerprint = "nested-git-roots-v1-strict"
const DiscoveryFingerprint = "detect-ignore-v1-strict-inventory-v1"
const ExtractorFingerprint = "pipeline-build-v3-closed-go-v1"
const InventoryVersion = 2
Variables ¶
This section is empty.
Functions ¶
func Candidate ¶
Candidate preserves selected unavailable corpora instead of skipping their dangling compatibility path in favor of a different repository/global graph.
func CanonicalRoot ¶
func CheckInventory ¶
CheckInventory does not consult mutable child selections. Aggregate manifests embed everything needed for freshness after child generation reclamation.
func CheckLegacy ¶
Legacy verification may establish a changed/deleted file, never completeness. Permission errors and nonregular paths are uncertainty, not deletion.
func CheckLegacyTargets ¶
Call under the output writer lock. Fixed artifact and temporary names may not redirect writes into another output's selected/sealed generation.
func DiscoverChildRoots ¶
DiscoverChildRoots follows the existing nested-repository discovery shape, but treats inaccessible .git probes as errors rather than missing children.
func Initialize ¶
func Inventory ¶
Inventory uses detect's actual rule matcher and ordering (including its ANY-list semantics). Unlike detect.Walk it never swallows traversal failures. The same function supplies default build discovery and reader verification.
func ReadOnlyURI ¶
func RefuseRemoval ¶
RefuseRemoval inspects canonical targets, their ancestors and nested layouts before callers alter any hooks, registry records, artifacts or lock identity. It never deletes, repairs, or reclaims anything. Inaccessible targets fail shut.
func RegularFile ¶
func RequestFingerprint ¶
func RequestFingerprint(req types.ManifestRequest) string
func VerifySources ¶
VerifySources keeps binding, inventory freshness and extraction coverage separate. Equal live hashes alone cannot attest an opaque extractor's input.
func WithRemoval ¶
WithRemoval coordinates the complete operation, not an inspect-release-delete sequence. Callbacks must NOT reacquire writer/removal locks for guarded roots. Refusal is still the only behavior for adopted layouts/stable lock deletion.
Types ¶
type Closure ¶
type Closure struct {
Bytes map[string][]byte
Dirs []string
Files []types.ManifestFile
DirectoryFingerprint, ConfigFingerprint, DependencyFingerprint string
}
ClosedInputs records the filesystem profile the default Go structural extractor can inspect: all Go files (including ignored candidates), config, and directory existence. Generated/VCS stores cannot be import targets in this profile; pipeline validates imports before running on the private tree.