Skip to content

release: prepare v1.3.0#77

Merged
gaelic-ghost merged 11 commits into
mainfrom
docs/feature-permission-plan
May 9, 2026
Merged

release: prepare v1.3.0#77
gaelic-ghost merged 11 commits into
mainfrom
docs/feature-permission-plan

Conversation

@gaelic-ghost
Copy link
Copy Markdown
Owner

@gaelic-ghost gaelic-ghost commented May 9, 2026

Release

  • prepares v1.3.0 from branch docs/feature-permission-plan
  • keeps protected main updates behind pull request review and CI
  • release tag v1.3.0 was created locally before this PR so the reviewed release candidate is preserved exactly

Review Loop

Before merge, scripts/repo-maintenance/release.sh watches CI and stops on review comments unless the maintainer has already addressed or resolved them and reruns with --review-comments-addressed.

Summary by CodeRabbit

  • New Features

    • Command execution with captured stdout/stderr, timeouts, and process controls
    • Git observability for worktree status, remotes, ahead/behind and dirty/untracked counts
    • App-wide feature permission policy and human-readable feature-operation event stream
    • Extension marketplace upgrade capability and marketplace maintenance workflow
  • Documentation

    • README, ROADMAP and docs updated for v1.3.0 (new tagline, promo audio, SPM quick start, plugin/marketplace guidance)

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 9, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: c982b573-9f91-4ff3-8449-0edd34d10b54

📥 Commits

Reviewing files that changed from the base of the PR and between 6347f91 and 86fd0cd.

📒 Files selected for processing (8)
  • README.md
  • Sources/SwiftASB/Public/CodexAppServer.swift
  • Sources/SwiftASB/Public/CodexWorkspace.swift
  • Sources/SwiftASB/SwiftASB.docc/CodexAppServer.md
  • Sources/SwiftASB/SwiftASB.docc/FeaturePermissionPolicy.md
  • Tests/SwiftASBTests/Protocol/CodexAppServerProtocolTests.swift
  • Tests/SwiftASBTests/Public/CodexAppServerFileSystemTests.swift
  • Tests/SwiftASBTests/Public/CodexWorkspaceTests.swift
✅ Files skipped from review due to trivial changes (2)
  • Sources/SwiftASB/SwiftASB.docc/FeaturePermissionPolicy.md
  • README.md
🚧 Files skipped from review as they are similar to previous changes (5)
  • Sources/SwiftASB/SwiftASB.docc/CodexAppServer.md
  • Tests/SwiftASBTests/Public/CodexAppServerFileSystemTests.swift
  • Tests/SwiftASBTests/Protocol/CodexAppServerProtocolTests.swift
  • Tests/SwiftASBTests/Public/CodexWorkspaceTests.swift
  • Sources/SwiftASB/Public/CodexWorkspace.swift

📝 Walkthrough

Walkthrough

This PR adds a feature-permission policy with built-in categories and host-access declarations, a typed command/exec JSON-RPC surface, sandboxed command execution models, app-wide feature-operation event streaming, Git observability with parsers and selected-worktree snapshots, a marketplace-upgrade maintenance workflow, library wiring for Git refreshes, tests, doc updates, and README/ROADMAP/version-bump script edits targeting v1.3.0.

Feature Permission Policy & Git Observability System

Layer / File(s) Summary
Data Models
Sources/SwiftASB/Public/SwiftASBFeaturePolicy.swift, Sources/SwiftASB/Public/SwiftASBFeatureOperationEvent.swift, Sources/SwiftASB/Public/CodexWorkspace.swift
Adds SwiftASBFeaturePolicy, SwiftASBFeatureCategory/ID, SwiftASBHostAccess, SwiftASBFeatureOperationEvent (with nested Status/Command/Rollback), and Git observability types (GitStatusSnapshot, GitStatusSummary, GitRemoteInfo, GitFactSource).
Protocol Command Execution
Sources/SwiftASB/Protocol/CodexAppServerProtocol+Types.swift, Sources/SwiftASB/Protocol/CodexAppServerProtocol.swift
Adds CodexProtocolCommandExecParams and CodexProtocolCommandExecResponse; new JSON-RPC method command/exec; makeCommandExecRequest and decodeCommandExecResponse; maps command/exec/outputDelta notification to .commandExecOutputDelta.
Command Execution Models
Sources/SwiftASB/Public/CodexAppServer+CommandExecution.swift
Adds CodexAppServer.CommandExecRequest and CodexAppServer.CommandExecResult value types used by the server and extensions.
App Server Core
Sources/SwiftASB/Public/CodexAppServer.swift
Stores featurePolicy from configuration; exposes featureOperationEvents() async stream with bounded buffering and replay; implements publish/remove/finish helpers; adds internal command/exec helpers and requireFeatureEnabled gating; ignores commandExecOutputDelta events.
Git Observability
Sources/SwiftASB/Public/CodexAppServer+GitObservability.swift
Adds refreshGitStatus(for:) to run sandboxed git -C <cwd> calls (repo root, HEAD, remotes, status), parse results into GitStatusSnapshot/GitStatusSummary/GitRemoteInfo, and compute GitFactSource; includes parsing helpers.
Library Integration
Sources/SwiftASB/Public/CodexAppServer+Library.swift
Library.Configuration adds featurePolicy; Library stores gitStatusByWorktreeID, lastGitStatusReadAt, exposes selectedGitStatus, schedules/cancels gitStatusTask on selection changes, and adds refreshSelectedGitStatus().
Marketplace Upgrade
Sources/SwiftASB/Public/CodexAppServer+CodexExtensions.swift
Adds MarketplaceUpgradeRequest and MarketplaceUpgradeResult, CodexExtensions.upgradeMarketplace(_:) that gates on extensionMaintenance, prefetches plugin/list, executes codex plugin marketplace upgrade via command/exec, computes status from exit code, publishes a SwiftASBFeatureOperationEvent, and returns diagnostics and outputs.
Bootstrap Configuration
Sources/SwiftASB/Public/CodexAppServer+Bootstrap.swift
CodexAppServer.Configuration adds featurePolicy: SwiftASBFeaturePolicy = .defaults propagated into initialization.
Test Support
Tests/SwiftASBTests/Public/CodexAppServerTestSupport.swift
FakeCodexAppServerTransport adds commandExecResult and commandExecResultQueue; send(_:id:) returns queued or default command/exec results.
Protocol & Unit Tests
Tests/SwiftASBTests/Protocol/CodexAppServerProtocolTests.swift, Tests/SwiftASBTests/Public/SwiftASBFeaturePolicyTests.swift, Tests/SwiftASBTests/Public/SwiftASBFeatureOperationEventTests.swift
Adds tests for command/exec request encoding and outputDelta notification decoding, feature-policy defaults and overrides, and feature-operation event construction.
Integration & Filesystem Tests
Tests/SwiftASBTests/Public/CodexAppServerTests.swift, Tests/SwiftASBTests/Public/CodexAppServerLibraryTests.swift, Tests/SwiftASBTests/Public/CodexAppServerFileSystemTests.swift, Tests/SwiftASBTests/Public/CodexWorkspaceTests.swift
Integration tests validate featureOperationEvents() streaming/replay, executeCommand routing through command/exec, library Git-status refresh via queued command/exec results, marketplace upgrade flows and feature-gate enforcement, and GitStatusSnapshot behavior.
Documentation & Release Tooling
Sources/SwiftASB/SwiftASB.docc/*, README.md, ROADMAP.md, docs/maintainers/*, scripts/repo-maintenance/version-bump.sh
Adds FeaturePermissionPolicy.md; updates CodexAppServer.md, CodexWorkspace.md, AppWideCapabilities.md, SwiftUIObservableCompanions.md; README updated to reference v1.3.0 and quick-start changes; ROADMAP and maintainer docs updated; version-bump.sh adds README release-reference validation.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~60 minutes

Possibly related PRs

  • gaelic-ghost/SwiftASB#75: Modifies CodexWorkspace and CodexAppServer.Library worktree/repository modeling—related at the code level.
  • gaelic-ghost/SwiftASB#72: Modifies library/workspace models for repository/project/thread-source and Git-related info—code-level connection.

Suggested labels

enhancement

Poem

🐰 I hopped through branches, parsed each line,
Commands sandboxed, events in time,
Policies guard the garden gate,
Marketplaces upgraded — small hooray!
A rabbit cheers these tidy traits.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 12.36% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'release: prepare v1.3.0' directly and clearly summarizes the main objective of the PR: preparing the v1.3.0 release. It is concise, specific, and accurately reflects the primary purpose of the changeset.
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.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch docs/feature-permission-plan

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

Copy link
Copy Markdown

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 8

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
Sources/SwiftASB/Public/CodexAppServer.swift (1)

200-215: ⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Finish featureOperationEvents() on unexpected transport shutdown too.

The new stream is cleaned up in stop(), but the existing event-loop error/end paths later in this file still omit finishAllFeatureOperationEventStreams(). After an unexpected transport failure, subscribers to featureOperationEvents() can wait forever for the next element instead of seeing the stream end.

Suggested change
             } catch {
                 await self.finishAllThreadEventStreams(
                     throwing: CodexAppServerError.wrap(error, operation: "server events")
                 )
                 await self.finishAllDiagnosticEventStreams(
                     throwing: CodexAppServerError.wrap(error, operation: "server events")
                 )
                 await self.finishAllLibraryEventStreams()
+                await self.finishAllFeatureOperationEventStreams()
                 await self.finishAllFSChangeStreams()
                 await self.finishAllTurnEventStreams(
                     throwing: CodexAppServerError.wrap(error, operation: "server events")
                 )
             }
@@
         guard hasStarted, !isStopping else {
             finishAllThreadEventStreams(throwing: nil)
             finishAllDiagnosticEventStreams(throwing: nil)
             finishAllLibraryEventStreams()
+            finishAllFeatureOperationEventStreams()
             finishAllFSChangeStreams()
             finishAllThreadObservableActivityStreams()
             finishAllThreadCommandDeltaStreams()
             finishAllThreadFileDeltaStreams()
             finishAllTurnEventStreams(throwing: nil)
@@
         finishAllThreadEventStreams(
             throwing: CodexAppServerError.transportFailure(
                 operation: "server events",
                 reason: "Codex app-server stopped delivering thread notifications before pending thread streams finished."
             )
         )
         finishAllDiagnosticEventStreams(
             throwing: CodexAppServerError.transportFailure(
                 operation: "server events",
                 reason: "Codex app-server stopped delivering diagnostics before pending diagnostic streams finished."
             )
         )
         finishAllLibraryEventStreams()
+        finishAllFeatureOperationEventStreams()
         finishAllFSChangeStreams()
         finishAllThreadObservableActivityStreams()
         finishAllThreadCommandDeltaStreams()
         finishAllThreadFileDeltaStreams()
         finishAllTurnEventStreams(

Also applies to: 254-263, 3355-3362

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@Sources/SwiftASB/Public/CodexAppServer.swift` around lines 200 - 215, The
featureOperationEvents stream isn't closed in the transport shutdown/error/end
paths — add a call to finishAllFeatureOperationEventStreams() alongside the
other cleanup calls (e.g., finishAllFSChangeStreams(),
finishAllThreadObservableActivityStreams(), finishAllTurnEventStreams(...)) so
subscribers receive the stream completion after an unexpected
transport.stop()/error; ensure this call is placed before resetting state
(hasStarted/hasCompletedInitializeHandshake/thread* collections) in every
error/termination branch where other finishAll* functions are invoked (including
the other places analogous to the shown block).
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@README.md`:
- Line 34: Fix the typographical error in the README motivation paragraph by
changing the phrase "on thee desktop" to "on the desktop"; locate the sentence
that contains "I built SwiftASB... on thee desktop" and update it to read "on
the desktop" so the product-facing copy is correct and approachable.

In `@ROADMAP.md`:
- Around line 419-421: The roadmap currently treats `v1.3.0` as already released
(the checklist line "- [x] Update stale release references after the `v1.3.0`
release." and the following "Decision: README now names `v1.3.0` as the current
released baseline...") which will be stale before the tag is published; change
that checklist item and the decision wording to indicate a pending/target
release (e.g., uncheck the box or mark as "pending release" and replace "current
released baseline" with "target release" or "release candidate"), and ensure the
README reference is updated only after the tag is actually published so the
roadmap and README remain consistent with the later "once the tag is published"
language.

In `@Sources/SwiftASB/Public/CodexAppServer.swift`:
- Around line 350-364: The helper requireFeatureEnabled currently only rejects
.disabled and therefore lets a .readOnly policy pass for mutation paths; update
the gate so mutation operations explicitly require the .enabled mode instead of
just not .disabled. Modify requireFeatureEnabled (or add a new helper such as
requireFeatureWritable) to call featurePolicy.mode(for: categoryID) and throw
the same CodexAppServerError.invalidState when the mode != .enabled (preserving
the existing categoryName and error message), and update mutation call sites to
use the new/changed helper while leaving read paths able to accept .readOnly via
the original helper.

In `@Sources/SwiftASB/Public/CodexWorkspace.swift`:
- Around line 318-320: GitStatusSummary.isDirty currently only checks
changedFileCount; update the isDirty computed property (and any dependent checks
like GitStatusSnapshot.isDirty) to return true when either changedFileCount > 0
OR untrackedFileCount > 0 so repositories with only untracked files are treated
as dirty. Locate the isDirty property on GitStatusSummary and modify its boolean
expression to include untrackedFileCount, and ensure any callers relying on
GitStatusSnapshot.isDirty continue to behave correctly.

In `@Sources/SwiftASB/Public/SwiftASBFeaturePolicy.swift`:
- Around line 121-127: The feature policy for the write-capable category
extensionMaintenance in SwiftASBFeaturePolicy is currently set to defaultMode:
.enabled; change defaultMode to .disabled for the extensionMaintenance feature
so it follows the read-only-by-default model, and update any unit tests that
assert the default for extensionMaintenance to expect .disabled instead of
.enabled (ensure SwiftASBFeaturePolicy or the extensionMaintenance constant is
the one modified and adjust related test assertions accordingly).

In `@Sources/SwiftASB/SwiftASB.docc/CodexAppServer.md`:
- Around line 107-108: The Topics list currently includes the request/result
types but omits the API method; add the method symbol
`CodexAppServer/CodexExtensions/upgradeMarketplace(_:)` to the Topics section
alongside `CodexExtensions/MarketplaceUpgradeRequest` and
`CodexExtensions/MarketplaceUpgradeResult` so the `upgradeMarketplace(_:)`
method is discoverable.

In `@Sources/SwiftASB/SwiftASB.docc/FeaturePermissionPolicy.md`:
- Around line 12-14: The docs currently contradict about default mutation
availability: the general statement "mutation categories are disabled until the
consuming app enables them" conflicts with the later statement that
extensionMaintenance is enabled by default; update FeaturePermissionPolicy.md so
the policy is consistent by either (a) making clear that "mutation categories
are disabled by default, except for explicitly allowed mutations such as
extensionMaintenance which is enabled by default" or (b) changing the
extensionMaintenance sentence to indicate it is also disabled unless
enabled—edit the sentences referencing "mutation categories" and the symbol
"extensionMaintenance" so they state the same default behavior and add a brief
note about exceptions if any.

In `@Tests/SwiftASBTests/Protocol/CodexAppServerProtocolTests.swift`:
- Around line 93-94: The test currently force-unwraps the UTF-8 conversion when
creating payload (payload = ... .data(using: .utf8)!), which can crash; replace
the force-unwrap with the Testing framework's throwing assertion (use the
`#require`()/require macro) to assert the Data is non-nil and surface failures via
test errors. Locate the payload declaration in CodexAppServerProtocolTests (the
payload variable in the failing test) and change it to use try require(...) (or
the `#require` variant used in this project) around the .data(using: .utf8) call
so the test fails cleanly instead of crashing.

---

Outside diff comments:
In `@Sources/SwiftASB/Public/CodexAppServer.swift`:
- Around line 200-215: The featureOperationEvents stream isn't closed in the
transport shutdown/error/end paths — add a call to
finishAllFeatureOperationEventStreams() alongside the other cleanup calls (e.g.,
finishAllFSChangeStreams(), finishAllThreadObservableActivityStreams(),
finishAllTurnEventStreams(...)) so subscribers receive the stream completion
after an unexpected transport.stop()/error; ensure this call is placed before
resetting state (hasStarted/hasCompletedInitializeHandshake/thread* collections)
in every error/termination branch where other finishAll* functions are invoked
(including the other places analogous to the shown block).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 7851cb8e-b074-460d-b130-f69648700861

📥 Commits

Reviewing files that changed from the base of the PR and between 7db7f8c and 6347f91.

⛔ Files ignored due to path filters (1)
  • docs/media/swiftasb-codex-apps-promo.mp3 is excluded by !**/*.mp3
📒 Files selected for processing (31)
  • README.md
  • ROADMAP.md
  • Sources/SwiftASB/Protocol/CodexAppServerProtocol+Types.swift
  • Sources/SwiftASB/Protocol/CodexAppServerProtocol.swift
  • Sources/SwiftASB/Public/CodexAppServer+Bootstrap.swift
  • Sources/SwiftASB/Public/CodexAppServer+CodexExtensions.swift
  • Sources/SwiftASB/Public/CodexAppServer+CommandExecution.swift
  • Sources/SwiftASB/Public/CodexAppServer+GitObservability.swift
  • Sources/SwiftASB/Public/CodexAppServer+Library.swift
  • Sources/SwiftASB/Public/CodexAppServer.swift
  • Sources/SwiftASB/Public/CodexWorkspace.swift
  • Sources/SwiftASB/Public/SwiftASBFeatureOperationEvent.swift
  • Sources/SwiftASB/Public/SwiftASBFeaturePolicy.swift
  • Sources/SwiftASB/SwiftASB.docc/AppWideCapabilities.md
  • Sources/SwiftASB/SwiftASB.docc/CodexAppServer.md
  • Sources/SwiftASB/SwiftASB.docc/CodexWorkspace.md
  • Sources/SwiftASB/SwiftASB.docc/FeaturePermissionPolicy.md
  • Sources/SwiftASB/SwiftASB.docc/SwiftASB.md
  • Sources/SwiftASB/SwiftASB.docc/SwiftUIObservableCompanions.md
  • Tests/SwiftASBTests/Protocol/CodexAppServerProtocolTests.swift
  • Tests/SwiftASBTests/Public/CodexAppServerFileSystemTests.swift
  • Tests/SwiftASBTests/Public/CodexAppServerLibraryTests.swift
  • Tests/SwiftASBTests/Public/CodexAppServerTestSupport.swift
  • Tests/SwiftASBTests/Public/CodexAppServerTests.swift
  • Tests/SwiftASBTests/Public/CodexWorkspaceTests.swift
  • Tests/SwiftASBTests/Public/SwiftASBFeatureOperationEventTests.swift
  • Tests/SwiftASBTests/Public/SwiftASBFeaturePolicyTests.swift
  • docs/maintainers/feature-permission-policy-plan.md
  • docs/maintainers/v1-public-api-audit.md
  • docs/maintainers/v1-public-api-symbol-inventory.md
  • scripts/repo-maintenance/version-bump.sh

Comment thread README.md Outdated
Comment thread ROADMAP.md
Comment on lines +419 to 421
- [x] Update stale release references after the `v1.3.0` release.
Decision: README now names `v1.3.0` as the current released baseline and no
longer describes the package as early development.
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor | ⚡ Quick win

Avoid describing v1.3.0 as already released.

This PR is still release prep, and later sections in the same roadmap still say “once the tag is published.” Calling v1.3.0 the current released baseline here will read as stale before the tag is actually public.

🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@ROADMAP.md` around lines 419 - 421, The roadmap currently treats `v1.3.0` as
already released (the checklist line "- [x] Update stale release references
after the `v1.3.0` release." and the following "Decision: README now names
`v1.3.0` as the current released baseline...") which will be stale before the
tag is published; change that checklist item and the decision wording to
indicate a pending/target release (e.g., uncheck the box or mark as "pending
release" and replace "current released baseline" with "target release" or
"release candidate"), and ensure the README reference is updated only after the
tag is actually published so the roadmap and README remain consistent with the
later "once the tag is published" language.

Comment thread Sources/SwiftASB/Public/CodexAppServer.swift
Comment thread Sources/SwiftASB/Public/CodexWorkspace.swift
Comment on lines +121 to +127
id: .extensionMaintenance,
displayName: "Extension Maintenance",
description: "Upgrade already-installed extensions, plugins, skills, or marketplace entries.",
permissionReason: "SwiftASB can keep existing trusted extension installs current while reporting any maintenance write it performs.",
defaultMode: .enabled,
sensitivity: .maintenance,
eventPolicy: .notifyOnMutation
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟠 Major | ⚡ Quick win

Disable extensionMaintenance by default.

Line 125 currently ships a write-capable category as .enabled, which contradicts the documented “read-only defaults, explicit mutation enablement” model and lets marketplace upgrades run unless the host opts out. This should default to .disabled, with the matching test expectations updated alongside it.

Suggested change
         .init(
             id: .extensionMaintenance,
             displayName: "Extension Maintenance",
             description: "Upgrade already-installed extensions, plugins, skills, or marketplace entries.",
             permissionReason: "SwiftASB can keep existing trusted extension installs current while reporting any maintenance write it performs.",
-            defaultMode: .enabled,
+            defaultMode: .disabled,
             sensitivity: .maintenance,
             eventPolicy: .notifyOnMutation
         ),
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
id: .extensionMaintenance,
displayName: "Extension Maintenance",
description: "Upgrade already-installed extensions, plugins, skills, or marketplace entries.",
permissionReason: "SwiftASB can keep existing trusted extension installs current while reporting any maintenance write it performs.",
defaultMode: .enabled,
sensitivity: .maintenance,
eventPolicy: .notifyOnMutation
id: .extensionMaintenance,
displayName: "Extension Maintenance",
description: "Upgrade already-installed extensions, plugins, skills, or marketplace entries.",
permissionReason: "SwiftASB can keep existing trusted extension installs current while reporting any maintenance write it performs.",
defaultMode: .disabled,
sensitivity: .maintenance,
eventPolicy: .notifyOnMutation
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In `@Sources/SwiftASB/Public/SwiftASBFeaturePolicy.swift` around lines 121 - 127,
The feature policy for the write-capable category extensionMaintenance in
SwiftASBFeaturePolicy is currently set to defaultMode: .enabled; change
defaultMode to .disabled for the extensionMaintenance feature so it follows the
read-only-by-default model, and update any unit tests that assert the default
for extensionMaintenance to expect .disabled instead of .enabled (ensure
SwiftASBFeaturePolicy or the extensionMaintenance constant is the one modified
and adjust related test assertions accordingly).

Comment thread Sources/SwiftASB/SwiftASB.docc/CodexAppServer.md
Comment thread Sources/SwiftASB/SwiftASB.docc/FeaturePermissionPolicy.md Outdated
Comment thread Tests/SwiftASBTests/Protocol/CodexAppServerProtocolTests.swift Outdated
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 6347f911fa

ℹ️ 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".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

_ categoryID: SwiftASBFeatureCategory.ID,
for operation: String
) throws {
guard featurePolicy.mode(for: categoryID) != .disabled else {
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Badge Block mutation operations when feature mode is readOnly

requireFeatureEnabled only rejects .disabled, so mutation APIs still run when a category is set to .readOnly. In this commit, upgradeMarketplace relies on this guard, which means hosts that set extensionMaintenance to read-only will still execute command/exec and mutate marketplace state, violating the documented read-only policy semantics.

Useful? React with 👍 / 👎.

sortedBy: SortedBy = .updatedNewestFirst,
groupedBy: GroupedBy = .cwd,
query: CodexAppServer.ThreadListQD = .init(),
featurePolicy: SwiftASBFeaturePolicy = .defaults,
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Inherit app-server feature policy for library by default

The library config defaults featurePolicy to .defaults instead of inheriting the CodexAppServer policy, so makeLibrary() can silently re-enable features that were disabled at app-server construction. A host that disables gitObservability in CodexAppServer.Configuration but uses default Library.Configuration will still trigger Git command/exec probes on selection, which breaks app-wide policy expectations.

Useful? React with 👍 / 👎.

behindCount: Int?
) {
let trimmed = String(line.dropFirst(3))
let branchAndTracking = trimmed.split(separator: " ", maxSplits: 1).first.map(String.init) ?? trimmed
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Parse unborn-branch status line without truncating branch name

Branch parsing currently takes only the first whitespace-delimited token from the ## status line, so porcelain output like ## No commits yet on master is parsed as branch No. This yields incorrect Git metadata for newly initialized repositories and makes GitStatusSnapshot.repository.branch unreliable in that common setup state.

Useful? React with 👍 / 👎.

@gaelic-ghost gaelic-ghost merged commit a7db7e6 into main May 9, 2026
2 checks passed
@gaelic-ghost gaelic-ghost deleted the docs/feature-permission-plan branch May 9, 2026 22:08
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