nushell: SRS interface contracts for G05_0b8531e + DAG CSV semantics note
Browse files- srs/milestone_G05_0b8531e: Interface Contracts appendix. IC1 makes the
SplitRead relocation additive in nu-protocol (the split_read module in
byte_stream.rs remains present with SplitRead name-resolvable inside;
a nu-utils re-export suffices; no duplicated implementation). IC2 pins
the strings module files (strings/shared.rs, strings/unique.rs) and
requires sformat!/uformat! to be invocable unqualified there.
Adjudicated G1/G2/G3-established (blinded probes: 3/3 REMOVE without
IC1, 3/3 KEEP with it); repairs the anchor loss that zeroed five
base-vintage cells for layout-faithful agents and the macro-scope
compile failure that zeroed the origin cell's N2P set.
- additional_dependencies.csv: comment row documenting that column
semantics match dependencies.csv (target depends on source; the loaded
direction is authoritative — several rationale texts read inverted).
The harness loader now skips '#' rows.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01N7uLXLRP9d4Lp1WdDRHoRm
|
@@ -1,4 +1,5 @@
|
|
| 1 |
source_id,target_id,type,strength,rationale,confidence_score
|
|
|
|
| 2 |
milestone_core_development.3,milestone_core_development.1,NFR,Strong,cd.1 upgrades ureq v2->v3 and rusqlite and reedline - cd.3 code uses v3 APIs,0.95
|
| 3 |
milestone_G02_da9615f,milestone_core_development.1,NFR,Strong,cd.1 upgrades ureq v2->v3 - crate Cargo.toml uses v3 feature syntax,0.95
|
| 4 |
milestone_G04_1ddae02,milestone_core_development.1,NFR,Strong,cd.1 upgrades ureq v2->v3 - crate Cargo.toml uses v3 feature syntax,0.95
|
|
|
|
| 1 |
source_id,target_id,type,strength,rationale,confidence_score
|
| 2 |
+
"# NOTE: column semantics match dependencies.csv — a row (source_id; target_id) means target DEPENDS ON source (source is scheduled first). The loaded direction is authoritative; several rationale texts below describe the dependency in the opposite (source-depends-on-target) voice — read them against this note. Lines starting with # are ignored by the harness loader."
|
| 3 |
milestone_core_development.3,milestone_core_development.1,NFR,Strong,cd.1 upgrades ureq v2->v3 and rusqlite and reedline - cd.3 code uses v3 APIs,0.95
|
| 4 |
milestone_G02_da9615f,milestone_core_development.1,NFR,Strong,cd.1 upgrades ureq v2->v3 - crate Cargo.toml uses v3 feature syntax,0.95
|
| 5 |
milestone_G04_1ddae02,milestone_core_development.1,NFR,Strong,cd.1 upgrades ureq v2->v3 - crate Cargo.toml uses v3 feature syntax,0.95
|
|
@@ -132,3 +132,18 @@ The following dependencies must be added or modified in `crates/nu-utils/Cargo.t
|
|
| 132 |
| `lean_string` | Add | `lean_string.workspace = true` | Provides `lean_string::LeanString` as the underlying implementation for `SharedString` |
|
| 133 |
| `memchr` | Add | `memchr = { workspace = true }` | Provides `memchr::memmem::Finder` for efficient byte pattern searching in `SplitRead` |
|
| 134 |
| `serde` | Modify | `serde = { workspace = true, features = ["derive"] }` | Add `derive` feature to enable `#[derive(Serialize, Deserialize)]` macros |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 132 |
| `lean_string` | Add | `lean_string.workspace = true` | Provides `lean_string::LeanString` as the underlying implementation for `SharedString` |
|
| 133 |
| `memchr` | Add | `memchr = { workspace = true }` | Provides `memchr::memmem::Finder` for efficient byte pattern searching in `SplitRead` |
|
| 134 |
| `serde` | Modify | `serde = { workspace = true, features = ["derive"] }` | Add `derive` feature to enable `#[derive(Serialize, Deserialize)]` macros |
|
| 135 |
+
|
| 136 |
+
---
|
| 137 |
+
|
| 138 |
+
# Interface Contracts (Appendix)
|
| 139 |
+
|
| 140 |
+
Additional binding requirements for this milestone.
|
| 141 |
+
|
| 142 |
+
## IC1 — SplitRead relocation is additive in `nu-protocol` (extends FR2)
|
| 143 |
+
|
| 144 |
+
- The existing `split_read` module inside `crates/nu-protocol/src/pipeline/byte_stream.rs` must remain present, and the generic `SplitRead` iterator must remain name-resolvable inside that module. Re-exporting the `nu-utils` type there (e.g. `pub use nu_utils::SplitRead;`) is sufficient; the module's other contents may delegate to the new implementation, and the implementation must not be duplicated there.
|
| 145 |
+
|
| 146 |
+
## IC2 — String-type module files and formatting macros (extends FR1)
|
| 147 |
+
|
| 148 |
+
- Within the `strings` directory module, the `SharedString` implementation must reside in `crates/nu-utils/src/strings/shared.rs` and the `UniqueString` implementation in `crates/nu-utils/src/strings/unique.rs`.
|
| 149 |
+
- `sformat!` must be invocable unqualified within `strings/shared.rs`, and `uformat!` within `strings/unique.rs` — define the macro in that file, or import it at the top of the file (e.g. `use crate::sformat;`).
|