Skip to content

Commit ff17f56

Browse files
authored
chore: remove orphaned directories and correct stale documentation (#4267)
* chore: remove orphaned test app, tools, and dead CI scripts These directories were orphaned when the root Amplify.xcodeproj was deleted in 937c47e (Feb 2022) and have had no live references since. Every commit touching them afterwards was a release bump or a repo-wide formatting sweep, so they were costing maintenance without being built or run. - AmplifyTestApp/: an iOS app bundle with no .xcodeproj to build it. Its only mention anywhere was the .swiftlint.yml exclusion list. Its awsconfiguration.json is not even valid JSON (unterminated string on the PoolId line), confirming nothing has parsed it in years. - AmplifyFunctionalTests/: not a target in Package.swift and not run by any workflow; uncompiled, unrunnable test code. - AmplifyTools/: 48 files including a nested SPM package and its own .xcodeproj, never built by CI. Self-declared deprecated in its own README ("will be completely removed in a future release"). Also cleans up the CircleCI leftovers. There has been no .circleci/ config since 2022, but the directory name survived: - Deleted pre_start_simulator.sh (untouched since 2019; depends on CircleCI-only $BASH_ENV and circleci-test-device, so it cannot work on GitHub Actions). - Deleted check_api_breakage.sh, superseded by api-breaking-changes-detection.yml. It had already drifted stale: it checked 2 modules while api-dump/ tracks 4, so a local run gave a false pass. - Renamed CircleciScripts/ to scripts/, keeping the one live script (jazzy_doc_gen.sh), and updated its three workflow references. Finally, drops two unreferenced readme-images assets and the now-dangling .swiftlint.yml exclusions. Verified: `swift package dump-package` succeeds, `swiftlint` reports zero errors, and no references to the removed paths remain outside CHANGELOG.md. * docs: correct stale versions, paths, links, and API signatures Audited the markdown against the actual repo contents and fixed the claims that contradict it. Each item below was verified against Package.swift, the source, or by resolving the URL. Version and tooling facts: - CONTRIBUTING.md said Xcode 13.4 minimum; README.md and AGENTS.md say 16.0, and 13.4 cannot even parse `swift-tools-version:5.9`. - CONTRIBUTING.md specified a 100-character line limit; SwiftLint enforces 160. - CONTRIBUTING.md's Tools section listed only Xcode, omitting the SwiftFormat 0.60.1 / SwiftLint 0.54.0 pins and Fastlane that CI actually requires. - AGENTS.md said 19 test targets (there are 23) and "60+" workflows (70). Wrong or dead references: - AWS SDK for Swift linked to github.com/aws-amplify/aws-sdk-swift; the correct org is awslabs, per Package.swift. - Six dead CONTRIBUTING.md TOC anchors (off-by-one step links, a "Running Cocoapods Locally" entry with no target section). - Four legacy docs.amplify.aws /lib/...q/platform/ios URLs updated to the paths they now redirect to. - bug_report.yaml pointed at the old amplify-ios repo and asked Swift users for an Amplify CLI log; LogsGuidance.md is about Xcode console output. - ETHOS.md named a nonexistent AWSStoragePlugin (it is AWSS3StoragePlugin). - AmplifyTests/CoreTests/README.md described an amplifyconfiguration.json sample that is not in that directory, and predated amplify_outputs.json. Corrected code and structure claims: - AmplifyClients/AGENTS.md: KinesisError.unknown has three associated values, not two; the initializer is `throws`; `record` is `@discardableResult`; the User-Agent example double-stamped the version, which UserAgentClientEngine already injects as lib/amplify-swift#<version>. - AmplifyClients/AGENTS.md: added the missing AmplifyRecordCache layer (used by Kinesis and Firehose) and corrected the integration-test layout, which is not co-located per client. - AmplifyPlugins/AGENTS.md: unit-test directory names vary by plugin, so the single stated pattern was wrong for most of them. Also removed `@visibleForTesting`, which is not a Swift attribute and has zero occurrences in this codebase. - Amplify/AGENTS.md: named the two actual DefaultPlugins and resolved the contradiction about Hub needing no plugin. - Documented that api-dump/ covers only four modules, and distinguished api-breaking-changes-detection.yml from api_digester_check.yml. - Documented that SwiftLint's `included:` scope excludes AmplifyClients/, AmplifyFoundation/, and AmplifyFoundationBridge/, and that the lint workflows do not run on pull_request. - Added the footnote the README's visionOS "Preview*" marker was missing, and noted visionOS is not declared in Package.swift but inherited from iOS. - Surfaced the Amazon Pinpoint retirement notice (Oct 30, 2026) in README.md and AmplifyPlugins/AGENTS.md; previously only the migration guide carried it while the README still listed Analytics as GA with no caveat. - Fixed a syntax error in both README-combine-support.md samples (`search(for "coffee")` was missing its colon) and two LogsGuidance.md typos. * ci: bump checkout pin on lint workflows and drop stale scheme testable The SwiftLint and SwiftFormat workflows were the only two of 26 still pinned to actions/checkout v3.5.3, which runs on the deprecated Node 16 runtime. Bumped both to the v4.1.1 pin the other 24 workflows already use. Also removed the AmplifyConnectClientIntegrationTests testable from Amplify-Package.xcscheme. That target does not exist in Package.swift — the integration tests live in a separate host-app project (AmplifyClients/AmplifyConnectClient/Tests/ConnectClientHostApp) where the scheme is named ConnectClientIntegrationTests. This was harmless only because Amplify-Package is used for `xcodebuild build` and never `test`; it would fail for anyone invoking the scheme's test action. Verified the scheme is still valid XML.
1 parent 8270037 commit ff17f56

90 files changed

Lines changed: 83 additions & 9416 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/ISSUE_TEMPLATE/bug_report.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,8 @@ body:
8787
attributes:
8888
label: Relevant log output
8989
description: >-
90-
Include any relevant log output under
91-
`~/.amplify/logs/amplify-cli-<issue-date>.log` (See: [Logs Guidance](https://github.com/aws-amplify/amplify-ios/blob/main/LogsGuidance.md))
90+
Include any relevant log output from the Xcode console
91+
(See: [Logs Guidance](https://github.com/aws-amplify/amplify-swift/blob/main/LogsGuidance.md))
9292
value: |
9393
<details>
9494
<summary>Log Messages</summary>

.github/workflows/deploy_package.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,4 +80,4 @@ jobs:
8080
working-directory: ${{ github.workspace }}
8181
run: |
8282
git checkout -B gh-pages
83-
bash ./CircleciScripts/jazzy_doc_gen.sh
83+
bash ./scripts/jazzy_doc_gen.sh

.github/workflows/deploy_release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,4 +75,4 @@ jobs:
7575
working-directory: ${{ github.workspace }}
7676
run: |
7777
git checkout -B gh-pages
78-
bash ./CircleciScripts/jazzy_doc_gen.sh
78+
bash ./scripts/jazzy_doc_gen.sh

.github/workflows/release_doc.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,4 @@ jobs:
4545
env:
4646
GITHUB_EMAIL: aws-amplify-ops@amazon.com
4747
GITHUB_USER: aws-amplify-ops
48-
run: bash ./CircleciScripts/jazzy_doc_gen.sh
48+
run: bash ./scripts/jazzy_doc_gen.sh

.github/workflows/swiftformat.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
SWIFTFORMAT_VERSION: '0.60.1'
2929
SWIFTFORMAT_SHA256: 'cb4738085cf39c08da00b79b4a3683e77458ca12909934d04e5087d8e73f5e43'
3030
steps:
31-
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 #v3.5.3
31+
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
3232
with:
3333
persist-credentials: false
3434

.github/workflows/swiftlint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
container:
2828
image: ghcr.io/realm/swiftlint:0.54.0
2929
steps:
30-
- uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 #v3.5.3
30+
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 #v4.1.1
3131
with:
3232
persist-credentials: false
3333

.swiftlint.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,6 @@ excluded:
99
- Pods
1010
- .build
1111
- AmplifyAsyncTesting
12-
- AmplifyFunctionalTests
13-
- AmplifyTestApp
1412
- AmplifyTestCommon
1513
- AmplifyTests
1614
- AmplifyPlugins/Core/AWSPluginsCoreTests

.swiftpm/xcode/xcshareddata/xcschemes/Amplify-Package.xcscheme

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -895,16 +895,6 @@
895895
ReferencedContainer = "container:">
896896
</BuildableReference>
897897
</TestableReference>
898-
<TestableReference
899-
skipped = "NO">
900-
<BuildableReference
901-
BuildableIdentifier = "primary"
902-
BlueprintIdentifier = "AmplifyConnectClientIntegrationTests"
903-
BuildableName = "AmplifyConnectClientIntegrationTests"
904-
BlueprintName = "AmplifyConnectClientIntegrationTests"
905-
ReferencedContainer = "container:">
906-
</BuildableReference>
907-
</TestableReference>
908898
</Testables>
909899
</TestAction>
910900
<LaunchAction

AGENTS.md

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,13 @@ Detailed conventions and patterns live closer to the code. Read the relevant gui
1313

1414
- [`Amplify/AGENTS.md`](Amplify/AGENTS.md) — Core framework: categories, plugin protocols, error handling, configuration, Hub
1515
- [`AmplifyPlugins/AGENTS.md`](AmplifyPlugins/AGENTS.md) — Plugin implementations: Auth, API, Storage, DataStore, etc.
16-
- [`AmplifyClients/AGENTS.md`](AmplifyClients/AGENTS.md) — Standalone clients: Foundation, Bridge, Kinesis (new pattern)
16+
- [`AmplifyClients/AGENTS.md`](AmplifyClients/AGENTS.md) — Standalone clients: Kinesis, Firehose, Connect, EventEnrichment, plus shared RecordCache (new pattern)
1717

1818
## Linting & Formatting (MUST pass)
1919

20-
**Always run `swiftformat` on changed files before every commit.** CI enforces both formatting and linting — PRs will fail if files are not formatted. See `.swiftlint.yml` and `.swiftformat` for full rules.
20+
**Always run `swiftformat` on changed files before every commit.** The SwiftFormat and SwiftLint workflows run on pushes to non-default branches (not on `pull_request`), so format locally rather than relying on a PR check to catch it. See `.swiftlint.yml` and `.swiftformat` for full rules.
21+
22+
Note that `.swiftlint.yml` only lints `Amplify/` and `AmplifyPlugins/``AmplifyClients/`, `AmplifyFoundation/`, and `AmplifyFoundationBridge/` are outside SwiftLint's `included:` scope, though SwiftFormat covers the whole repo.
2123

2224
```bash
2325
swiftformat <changed-files> # Format changed files before committing
@@ -42,7 +44,7 @@ swiftlint --fix # Then lint
4244
amplify-swift/
4345
├── Amplify/ # Core framework (categories, protocols, errors, config)
4446
├── AmplifyPlugins/ # AWS service plugins (Auth, API, Storage, DataStore, etc.)
45-
├── AmplifyClients/ # Standalone AWS clients (Kinesis) — new pattern
47+
├── AmplifyClients/ # Standalone AWS clients (Kinesis, Firehose, Connect, EventEnrichment) — new pattern
4648
├── AmplifyFoundation/ # Shared protocols (credentials, logging, errors) — no deps
4749
├── AmplifyFoundationBridge/ # Foundation ↔ AWS SDK adapters
4850
├── AmplifyTests/ # Core unit tests
@@ -84,7 +86,7 @@ chore: update aws-swift-sdk dependency
8486
```
8587

8688
**Types**: `feat`, `fix`, `chore`, `refactor`, `test`, `docs`, `perf`, `ci`
87-
**Scopes**: `auth`, `api`, `storage`, `datastore`, `geo`, `analytics`, `logging`, `predictions`, `push`, `kinesis`, `core`, `foundation`
89+
**Scopes**: `auth`, `api`, `storage`, `datastore`, `geo`, `analytics`, `logging`, `predictions`, `push`, `kinesis`, `firehose`, `connect`, `core`, `foundation`
8890

8991
No period at end. One feature/bugfix per PR. Reference issues: `fixes #<issue>`.
9092

@@ -95,7 +97,7 @@ swift test # All unit tests
9597
swift test --filter AWSCognitoAuthPluginUnitTests # Specific target
9698
```
9799

98-
- **Unit tests**: XCTest, defined in Package.swift (19 test targets)
100+
- **Unit tests**: XCTest, defined in Package.swift (23 test targets)
99101
- **Integration tests**: Xcode host app projects under `AmplifyPlugins/<Category>/Tests/<Category>HostApp/`
100102
- **Conventions**: Mock via behavior protocols, use `AmplifyTestCommon` for shared utilities, `AmplifyAsyncTesting` for async helpers
101103
- **Test documentation**: Use Given/When/Then doc comments on all test methods:
@@ -114,11 +116,11 @@ swift test --filter AWSCognitoAuthPluginUnitTests # Specific target
114116

115117
## Semver
116118

117-
New enum cases = **minor** bump. Breaking API changes = **major** (rare, needs approval). API surface tracked via `api-dump/` JSON snapshots and CI checks.
119+
New enum cases = **minor** bump. Breaking API changes = **major** (rare, needs approval). API surface tracked via `api-dump/` JSON snapshots and CI checks, currently covering four modules only: `Amplify`, `AWSPluginsCore`, `AWSDataStorePlugin`, and `CoreMLPredictionsPlugin`.
118120

119121
## CI/CD
120122

121-
60+ GitHub Actions workflows in `.github/workflows/`: per-category unit tests (`unit_test_*.yml`), integration tests (`integ_test_*.yml`), platform builds, SwiftLint/SwiftFormat checks, API digester, CodeQL, Fortify. Releases via Fastlane.
123+
70 GitHub Actions workflows in `.github/workflows/`: per-category unit tests (`unit_test_*.yml`), integration tests (`integ_test_*.yml`), platform builds, SwiftLint/SwiftFormat checks, API digester, CodeQL, Fortify. Releases via Fastlane.
122124

123125
## Common Agent Tasks
124126

Amplify/AGENTS.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Amplify/
3434
│ ├── Auth/ # AuthCategoryBehavior (sign-in, sign-up, session, MFA)
3535
│ ├── DataStore/ # DataStoreCategoryBehavior (sync, query, observe)
3636
│ ├── Geo/ # GeoCategoryBehavior (search, maps)
37-
│ ├── Hub/ # Built-in pub/sub event system (no plugin needed)
37+
│ ├── Hub/ # Pub/sub event system (no user setup needed — backed by the built-in AWSHubPlugin)
3838
│ ├── Logging/ # LoggingCategoryBehavior
3939
│ ├── Notifications/ # Push notification behavior
4040
│ ├── Predictions/ # ML prediction behavior (text, vision, speech)
@@ -47,7 +47,7 @@ Amplify/
4747
│ ├── Model/ # Model, Schema, Field definitions (DataStore)
4848
│ ├── Plugin/ # Plugin protocol, PluginKey, Resettable
4949
│ └── Support/ # AmplifyError protocol, utilities
50-
├── DefaultPlugins/ # Built-in default plugin implementations
50+
├── DefaultPlugins/ # AWSHubPlugin and AWSUnifiedLoggingPlugin (registered automatically)
5151
└── DevMenu/ # Developer debug menu
5252
```
5353

@@ -107,7 +107,7 @@ let token = Amplify.Hub.listen(to: .auth) { payload in ... }
107107

108108
## API Surface Stability
109109

110-
API dumps in `api-dump/*.json` track the public surface. Breaking changes detected by CI (`api_digester_check.yml`). New enum cases = minor bump; removing/renaming public APIs = major bump (needs approval).
110+
API dumps in `api-dump/*.json` track the public surface of four modules (`Amplify`, `AWSPluginsCore`, `AWSDataStorePlugin`, `CoreMLPredictionsPlugin`). Breaking changes detected by CI (`api-breaking-changes-detection.yml`; `api_digester_check.yml` separately verifies the digester tool itself against the `api-dump-test/` fixtures). New enum cases = minor bump; removing/renaming public APIs = major bump (needs approval).
111111

112112
## Adding a New API to a Category
113113

0 commit comments

Comments
 (0)