Skip to content

Make Photos PhotoKit-first#107

Open
jmcte wants to merge 3 commits into
mainfrom
codex/issue-94-photokit-photos
Open

Make Photos PhotoKit-first#107
jmcte wants to merge 3 commits into
mainfrom
codex/issue-94-photokit-photos

Conversation

@jmcte

@jmcte jmcte commented Jul 12, 2026

Copy link
Copy Markdown
Contributor

Summary

  • use bounded PhotoKit reads as the primary Photos logical-asset source
  • return identifiers, media facts, dimensions, favorite/hidden state, album membership, and explicit provenance
  • avoid pixels, thumbnails, network requests, and implicit iCloud downloads
  • retain the existing package walk only as --degraded-filesystem

Governing Issue

Closes #94

Validation

  • Relevant local checks passed

  • Required PR checks are expected to satisfy CI Gate

  • Skipped checks are explained below

  • swift test --disable-sandbox (117 tests passed)

  • bash scripts/ci/run-fast-checks.sh (passed)

  • ./.build/debug/icloud-cli photos authorization --format json (exit 0, denied state, no access request)

No checks skipped.

Bootstrap Governance

  • Changes are scoped to the linked issue
  • Contributor or PR guidance changes are reflected in CONTRIBUTING.md, .github/PULL_REQUEST_TEMPLATE.md, and docs/bootstrap/onboarding.md when applicable
  • PR author enabled auto-merge where GitHub allows it, or GitHub plan-limit evidence/unavailable reason is recorded and the fallback merge-readiness policy applies
  • No real secrets, runtime auth, or machine-local env files are committed

No contributor guidance changed. Auto-merge will be enabled after stacked dependencies merge.

Flow Contract

  • Owner lane: Hermes native provider
  • Repair owner: jmcte
  • Autonomy class: bounded implementation
  • Risk class: high-sensitivity metadata; read-only

Flow Merge Readiness

  • Every blocker has a next actor and next action
  • No active blocking requested changes remain
  • Non-author approval is present when required
  • PR author enabled auto-merge where GitHub allows it, or recorded why it is unavailable/unsafe

Next actor: independent reviewer after #101 and #102 merge.

Merge Automation

  • PR author enabled auto-merge with gh pr merge --auto --squash, or the reason it is unavailable/unsafe is noted below

This draft is stacked on the #89 provider manifest and #90 SQLite snapshot foundation. It can be rebased and enabled for auto-merge after those land.

Notes

  • PhotoKit does not expose reliable local/cloud availability without attempting a media request, so that fact is explicitly unknown.
  • Derived observations are separate from source facts and remain empty; no OCR or classification occurs.

Expose a deterministic metadata-only provider registry through JSON and text output, covering every current Apple-data command family with maturity, source, permission, sensitivity, capability, and polling declarations. Document the v1 compatibility policy.\n\nCloses #89.
Add a private read-only SQLite snapshot engine with WAL and SHM companions, query-only enforcement, busy and process timeouts, structured failures, and deterministic cleanup. Migrate Messages and Safari history and document remaining providers.\n\nCloses #90.
Return evidence-backed logical asset facts through bounded PhotoKit reads without media requests or downloads. Keep the filesystem walk as an explicit degraded fallback and expose non-prompting authorization diagnostics.
@jmcte
jmcte marked this pull request as ready for review July 13, 2026 07:29
@jmcte
jmcte requested a review from a team as a code owner July 13, 2026 07:29
@jmcte
jmcte enabled auto-merge (squash) July 13, 2026 07:30

@Hermes-omt Hermes-omt left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The exact head passes swift test (117 tests), but this PR must be rebased onto current main before approval. Live main is d7f88dc01bd283b53c55fa59ed63f43f212a50a5; GitHub reports this PR unmergeable/dirty, and a local merge-tree reproduces conflicts in CommandLine.swift, CommandRunner.swift, ProviderManifest.swift, and provider-manifest tests. Resolve the rebase while preserving main's providers external-manifest support and combining this PR's PhotoKit/provider capability changes, then rerun CI on the rebased head.

@Hermes-omt Hermes-omt added the state:needs-repair PR needs repair before review can proceed. label Jul 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

state:needs-repair PR needs repair before review can proceed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

v2: Make Photos a PhotoKit-first evidence-backed provider

2 participants