Build Trace Entry
- 1. Property
Build Trace Key - 2. Property
Build Trace Value - 3. Property
id - 4. Property
outPath - 5. Property
dependentRealisations - 6. Property
signatures
Title: Build Trace Entry
| Type | combining |
| Required | No |
| Additional properties | Not allowed |
Description: A record of a successful build outcome for a specific derivation output.
This schema describes the JSON representation of a build trace entry.
Warning
This JSON format is currently experimental and subject to change.
| Property | Type | Pattern | Title/Description |
|---|---|---|---|
| + id | object | No | - |
| + outPath | object | No | - |
| + dependentRealisations | object | No | - |
| + signatures | object | No | - |
| All of(Requirement) |
|---|
| Build Trace Key |
| Build Trace Value |
1. Property Build Trace Key
Title: Build Trace Key
| Type | object |
| Required | No |
| Additional properties | Any type allowed |
| Defined in | #/$defs/key |
Description: A build trace entry is a key-value pair. This is the "key" part, refering to a derivation and output.
| Property | Type | Pattern | Title/Description |
|---|---|---|---|
| + id | string | No | Derivation Output ID |
1.1. Property id
Title: Derivation Output ID
| Type | string |
| Required | Yes |
Description: Unique identifier for the derivation output that was built.
Format: {hash-quotient-drv}!{output-name}
-
hash-quotient-drv: SHA-256 hash of the quotient derivation. Begins with
sha256:. -
output-name: Name of the specific output (e.g., "out", "dev", "doc")
Example: "sha256:ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad!foo"
| Restrictions | |
|---|---|
| Must match regular expression | ^sha256:[0-9a-f]{64}![a-zA-Z_][a-zA-Z0-9_-]*$ Test |
2. Property Build Trace Value
Title: Build Trace Value
| Type | object |
| Required | No |
| Additional properties | Any type allowed |
| Defined in | #/$defs/value |
Description: A build trace entry is a key-value pair. This is the "value" part, describing an output.
| Property | Type | Pattern | Title/Description |
|---|---|---|---|
| + outPath | string | No | Output Store Path |
| + dependentRealisations | object | No | Underlying Base Build Trace |
| + signatures | array of string | No | Build Signatures |
2.1. Property outPath
Title: Output Store Path
| Type | string |
| Required | Yes |
| Defined in | store-path-v1.yaml |
Description: The path to the store object that resulted from building this derivation for the given output name.
| Restrictions | |
|---|---|
| Min length | 34 |
| Must match regular expression | ^[0123456789abcdfghijklmnpqrsvwxyz]{32}-.+$ Test |
2.2. Property dependentRealisations
Title: Underlying Base Build Trace
| Type | object |
| Required | Yes |
| Additional properties | Not allowed |
Description: This is for derived build trace entries to ensure coherence.
Keys are derivation output IDs (same format as the main id field).
Values are the store paths that those dependencies resolved to.
As described in the linked section on derived build trace traces, derived build trace entries must be kept in addition and not instead of the underlying base build entries. This is the set of base build trace entries that this derived build trace is derived from. (The set is also a map since this miniature base build trace must be coherent, mapping each key to a single value.)
| Property | Type | Pattern | Title/Description |
|---|---|---|---|
| - ^sha256:[0-9a-f]{64}![a-zA-Z_][a-zA-Z0-9_-]*$ | string | Yes | Dependent Store Path |
2.2.1. Pattern Property Dependent Store Path
All properties whose name matches the regular expression
^sha256:[0-9a-f]{64}![a-zA-Z_][a-zA-Z0-9_-]*$(Test) must respect the following conditions
Title: Dependent Store Path
| Type | string |
| Required | No |
| Defined in | store-path-v1.yaml |
Description: Store path that this dependency resolved to during the build
| Restrictions | |
|---|---|
| Min length | 34 |
| Must match regular expression | ^[0123456789abcdfghijklmnpqrsvwxyz]{32}-.+$ Test |
2.3. Property signatures
Title: Build Signatures
| Type | array of string |
| Required | Yes |
Description: A set of cryptographic signatures attesting to the authenticity of this build trace entry.
| Array restrictions | |
|---|---|
| Min items | N/A |
| Max items | N/A |
| Items unicity | False |
| Additional items | False |
| Tuple validation | See below |
| Each item of this array must be | Description |
|---|---|
| Signature | A single cryptographic signature |
2.3.1. Signature
Title: Signature
| Type | string |
| Required | No |
Description: A single cryptographic signature
3. Property id
| Type | object |
| Required | Yes |
| Additional properties | Any type allowed |
4. Property outPath
| Type | object |
| Required | Yes |
| Additional properties | Any type allowed |
5. Property dependentRealisations
| Type | object |
| Required | Yes |
| Additional properties | Any type allowed |
6. Property signatures
| Type | object |
| Required | Yes |
| Additional properties | Any type allowed |
Examples
Simple build trace entry
{
"dependentRealisations": {},
"id": "sha256:ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad!foo",
"outPath": "g1w7hy3qg1w7hy3qg1w7hy3qg1w7hy3q-foo.drv",
"signatures": []
}
Build trace entry with dependencies
{
"dependentRealisations": {
"sha256:ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad!foo": "g1w7hy3qg1w7hy3qg1w7hy3qg1w7hy3q-foo.drv"
},
"id": "sha256:ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad!foo",
"outPath": "g1w7hy3qg1w7hy3qg1w7hy3qg1w7hy3q-foo.drv",
"signatures": []
}
Build trace entry with signature
{
"dependentRealisations": {},
"id": "sha256:ba7816bf8f01cfea414140de5dae2223b00361a396177a9cb410ff61f20015ad!foo",
"outPath": "g1w7hy3qg1w7hy3qg1w7hy3qg1w7hy3q-foo.drv",
"signatures": [
"asdfasdfasdf"
]
}