Skip to content

refactor: remove obsolete Apple client code and test scaffolding - #251

Merged
Quick104 merged 2 commits into
mainfrom
codex/slop-audit-cleanup
Sep 4, 2026
Merged

Quick104 merged 2 commits into
mainfrom
codex/slop-audit-cleanup

Conversation

@Quick104

@Quick104 Quick104 commented Sep 4, 2026 •

Copy link
Copy Markdown
Contributor

Problem

The Apple clients retained code from completed migrations: a string-path router over typed endpoints, orphan views and preference stores, duplicate settings/data transformations, and tests that kept unused production helpers alive or asserted fixture answers without executing behavior. This made it harder to distinguish supported behavior from abandoned scaffolding.

Related issue: N/A — the maintainer requested this repository audit and implementation in Codex.

Approach

This cleanup removes 3,701 net lines across 113 files and closes those unused dependency chains:

  • Replace every remaining path-dispatch call with its existing typed API; remove unused endpoint/model/store chains and preserve transport, query, and response policies.
  • Share settings state, avatar resolution, detail-fact assembly, hosted diagnostics response handling, and download deletion in their existing owners. Delete dormant UI, overlay tooling, player planning, and constant internal capability branches.
  • Remove tests of dead helpers and fixture-only expected outcomes. Exercise the actual auth invalidation and subtitle submission transitions, retain meaningful race/decoder/compatibility tests, and correct overstated coverage names.
  • Finish the ponytail follow-up: remove unused overlay position/preset labels and inline the badge builder into its sole caller (39 further lines removed).
  • Replace the UIKit-only overlay color decomposition, which returned gray on macOS, with native SwiftUI mixing. Preserve the existing iOS RGB weights and alpha; add one output regression test.
  • Run existing shell tests in CI, cover all Apple sources in the regression workflow, make preview recording manual, and remove stale scripts/media/comments and unsigned-test instructions.

The independent Swift settings resolver remains because the canonical server contract still requires four implementations. Its documentation now distinguishes reference conformance from shipped client behavior. Persisted schemas, remote compatibility fields, extension entry points, and useful historical images remain.

The full audit report records all 40 finding groups, original source locations, fixes, and retained contract requirements.

Validation

Validation on the local Mac Studio with Xcode 27 beta:

  • iOS, tvOS, and macOS app builds passed, including embedded extension targets. The tvOS simulator app installed and launched.
  • Full iOS XCTest run passed: 1,221 tests, zero failures, one skipped. The skipped live authenticated-stream test requires SILO_AETHER_LIVE_FIXTURE_PATH; no live-server or physical-device playback claim is made.
  • Follow-up b0b849fa: iOS compilation and -only-testing:SiloTests/OverlayPresetTests passed after the additional 39-line removal. The original full-suite results above are from 323eeaa1.
  • Both release-input shell suites passed: 13 marketing-version cases and 10 platform cases.
  • git diff --check passed. Two independent Astra medium correctness reviews and an Astra low ponytail review found no actionable issues; the required Git hook reviews completed before commit/push.
Commands used
/Users/macdev/.agents/skills/mac-builder/scripts/run-local-simulator.sh ios
/Users/macdev/.agents/skills/mac-builder/scripts/run-local-simulator.sh tvos
xcodebuild build -project iosApp/Silo.xcodeproj -scheme SiloMac \
  -destination 'platform=macOS' -derivedDataPath /tmp/silo-slop-mac-build \
  CODE_SIGNING_ALLOWED=NO
xcodebuild test -project iosApp/Silo.xcodeproj -scheme Silo \
  -destination 'platform=iOS Simulator,id=1EDC379C-E54F-47CB-B32C-443EB049B728' \
  -derivedDataPath /Users/macdev/silo-build-ios/simulator-9e47f463 \
  -parallel-testing-enabled NO -test-timeouts-enabled YES \
  -maximum-test-execution-time-allowance 60 \
  -resultBundlePath /tmp/silo-slop-tests.xcresult \
  CODE_SIGNING_ALLOWED=YES CODE_SIGN_IDENTITY=-
bash scripts/ci/resolve-marketing-version.test.sh
bash scripts/ci/resolve-platform.test.sh

Before/after: native macOS SwiftUI renders using the actual old/new OverlayPresets background-color functions. These isolate the accent-color defect; they are not screenshots of an authenticated app session.

Before After
Before: classic and pill accents fall back to gray on macOS After: classic and pill accents preserve their colors on macOS

Simulator regression check — September 4

Tested b0b849fa against pre-cleanup 9e47f463 on local iPhone 17 Pro / iOS 27 and Apple TV 4K / tvOS 27 simulators. Both baseline and PR products built successfully with matching app identities. No confirmed PR-introduced regression was found in the completed checks.

Check Result
iOS home, detail, avatar and settings layout Passed inspection; subtitle-settings before/after screenshots matched.
Shared subtitle preferences on iOS and tvOS Changed Always → Auto, reopened to verify the selection, then restored Always.
iOS video, English subtitles, HUD, pause and 10-second seek Passed after retrying one transport timeout.
tvOS navigation/focus, settings and detail screens Passed.
tvOS 1080p video, pause, timeline seek, resume and player options Passed. Subtitle picker selection worked; cue rendering for that clip was not established.
4K playback startup Intermittent failure reproduced in both PR and baseline: server-reported transcode_start_failed, “The playback transport did not become ready in time.” Not resolved by this cleanup.
iOS in-play quality switching Inconclusive. A different app executable was installed into the simulator during the test, replacing its data container and returning it to sign-in. Later iOS observations were excluded.

The final tvOS installation was restored to the PR build and playback stopped. The externally replaced iPhone installation was left alone. This check made no source changes. It does not establish physical-device HDR/audio output, offline deletion/playback, autoplay, sustained playback, or subtitle rendering across all formats. Follow-up is a reserved, authenticated iOS quality-switch test and investigation of the existing server transport timeout.

Latest GitHub checks: iOS tests, tvOS/macOS builds, shell tests and CodeRabbit passed; Macroscope skipped. Simulator testing used gpt-6-astra in Codex desktop with XcodeBuildMCP and Computer Use; no subagents were spawned for this check.

Risks

The widest changes are settings observation and typed API call-site migration. Download persistence remains asynchronous, so this does not add a crash-safe registry/asset transaction. tvOS received the bounded simulator checks above; macOS was build-validated. Their platform-specific XCTest branches are not executed by the iOS test bundle.

Checklist

  • The complete diff has been reviewed and its changes can be explained.
  • This pull request addresses the requested cleanup of obsolete code and test scaffolding.

AI Disclosure

  • Harness: Codex desktop agent harness; its configured pre-Git review hook invokes Codex CLI.
  • Tools: Codex multi-agent tools for independent investigation, implementation, and reviews; Codex Computer Use for GitHub evidence upload. No other AI code-generation tool was used.
  • Model: gpt-6-astra. Delegated investigation, implementation, and review agents used low or medium reasoning.
  • Involvement: AI-generated implementation, agent-verified through builds, tests, source inspection, and independent reviews; pending human review.
  • Adversarial review: two independent correctness passes covered API/settings/UI behavior and playback/download/diagnostics/test fidelity. A separate ponytail pass checked complexity and overlay/CI changes. No actionable findings remained. The mandatory configured reviews completed before both Git writes.

Summary by CodeRabbit

  • New Features

    • Unified subtitle and metadata language preferences across iOS, macOS, and tvOS.
    • Aspect-ratio controls are consistently available in player settings.
    • Added validation for overlay color presets and improved refresh-token handling.
  • Bug Fixes

    • Improved collection, favorites, watchlist, search, and playback data loading.
    • Preserved active sessions when stale refresh credentials are rejected.
  • Documentation

    • Updated iOS signing, testing, and release automation guidance.
  • Chores

    • Added automated CI and Apple regression checks.

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 4, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-04T20:37:36.768802Z b0b849f New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Sep 4, 2026 •

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Team

Run ID: 23e12578-0502-40ba-867f-f3c59ab97c01

📥 Commits

Reviewing files that changed from the base of the PR and between 323eeaa and b0b849f.

📒 Files selected for processing (2)
  • iosApp/iosApp/Overlays/CardOverlays.swift
  • iosApp/iosApp/Overlays/OverlayTypes.swift
💤 Files with no reviewable changes (2)
  • iosApp/iosApp/Overlays/CardOverlays.swift
  • iosApp/iosApp/Overlays/OverlayTypes.swift

Included review availability: 1 review is currently available. Your included PR review attempts over the past 7 days set your current allowance at 3 reviews per hour.


📝 Walkthrough

Walkthrough

The pull request adds CI coverage, changes Apple signing validation, consolidates typed API usage, simplifies playback and settings flows, removes unused UI and models, updates overlay rendering, and cleans up diagnostics and platform-specific code.

Changes

Apple client consolidation

Layer / File(s) Summary
CI, signing, tests, and contracts
.github/workflows/*, .vscode/tasks.json, CONTRIBUTING.md, README.md, iosApp/Tests/*
Adds CI script coverage, updates Apple regression triggers, enables ad-hoc simulator signing, and revises focused tests and fixtures.
Typed networking and screen API adoption
iosApp/iosApp/Networking/*, iosApp/iosApp/Downloads/*, iosApp/iosApp/Screens/*
Removes legacy path dispatch and unused models. Callers use dedicated API methods. Download deletion persists registry changes before local asset cleanup.
Playback, subtitles, and shared settings
iosApp/iosApp/Screens/Player/*, iosApp/iosApp/Screens/Settings/*, iosApp/iosApp/tvOS/Screens/Settings/*, iosApp/iosApp/Screens/Profiles/*
Removes legacy playback paths and capability branches. Shared settings use direct preference bindings. Subtitle submission setup is centralized.
Overlays, themes, and UI cleanup
iosApp/iosApp/Overlays/*, iosApp/iosApp/Theme/*, iosApp/iosApp/Extensions/ViewExtensions.swift, iosApp/iosApp/Components/*
Removes preview-only overlay metadata, unused theme helpers, and obsolete UI components. Updates overlay color blending.
Diagnostics and platform cleanup
iosApp/iosApp/Shared/Diagnostics/*, iosApp/iosApp/Screens/Player/NowPlayingController.swift, iosApp/project.yml, iosApp/iosApp/tvOS/*
Uses native string validation, narrows platform-specific compilation, shares detail fact assembly, and restores splash-resource inclusion.

Estimated code review effort: 5 (Critical) | ~120 minutes

Merge Risk: ⚪ Minimal · up to b0b84

This change removes obsolete Apple client code and updates overlay color rendering so configured macOS accents display correctly. No concrete merge-blocking risk is currently identified.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 23.42% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 111 functions across 50 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly summarizes the primary refactoring: removing obsolete Apple client code, unused dependencies, and test scaffolding.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/slop-audit-cleanup

Comment @coderabbitai help to get the list of available commands.

@Quick104
Quick104 merged commit 3c32225 into main Sep 4, 2026
6 checks passed
@Quick104
Quick104 deleted the codex/slop-audit-cleanup branch September 4, 2026 21:43
Quick104 added a commit that referenced this pull request Sep 5, 2026
PR #251 renamed the continuum* theme tokens to silo*. The update-required
pill added on this branch still referenced continuumOnSurface and
continuumCaption, which broke the build after the apiv2 merge.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Quick104 added a commit that referenced this pull request Sep 5, 2026
PR #251 renamed ContinuumAPI to SiloAPI. The no-v1-replay test on this
branch still constructed ContinuumAPI, which failed to compile once the
apiv2 branch was merged in.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
blurbery added a commit to blurbery/silo-apple that referenced this pull request Sep 5, 2026
Backport only the platform-independent classic/pill color recipes and their regression test from Silo-Server#251. Preserve the existing preset schema and the rest of the excluded cleanup. This avoids the UIKit-only color helper falling back to gray on macOS while retaining the existing iOS/tvOS straight-alpha sRGB recipes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant