Skip to content
CAI
Software that uses CAICheck a score

3lvis/Networking

68.6

Adequate · 1 October 2026

3.2k

lines of production code

Swift

primary language

2

measurements over time

CAI band scale
CAI trend line
CAI lens gauges

What this system is

This system is a modernized Swift networking library that provides a type-safe, async/await-based HTTP client with support for iOS 18 and later. It features a composable interceptor chain for handling authentication, retries, and validation, alongside a configurable caching system for in-memory and on-disk storage. The project has been fully migrated to Swift Package Manager with comprehensive test coverage and automated linting infrastructure.

Features

Added automated Swift linting with oida

Introduced a new linting workflow using the oida tool to enforce code style and formatting for Swift files. The \bin/lint\ script manages the oida binary (pinned by version and checksum for security), supports modes for checking, fixing, and CI validation, and integrates with \bin/staged-swift-files\ to identify relevant files while excluding build artifacts and generated sources.

bin · high confidence

Developers can now run linting and formatting checks locally before committing by enabling the pre-commit hook via the new setup script. This hook executes the repository's linting tool on staged files, ensuring that the code passing local checks matches what CI validates. Additionally, a new script checks for broken relative links within markdown documentation files, failing the check if any dead links are detected.

.githooks, scripts · high confidence

Behavioural changes

Cleanup for v8 release: new tooling, documentation, and CI configuration

This change prepares the repository for the v8 release by introducing a new linting and formatting infrastructure (oida and .swift-format), establishing developer guidelines (AGENTS.md, VOICE.md, LEARNINGS.md), and updating the CI pipeline to use Swift 6.4 and Xcode 27. It also removes legacy build and dependency support files (.travis.yml, CocoaPods references) and updates the .gitignore to exclude new build artifacts.

(repo-wide) · high confidence

Migrate test configuration to Swift Package Manager

The project has migrated its test infrastructure from a legacy Xcode project structure to native Swift Package Manager (SPM) support. This change introduces a new \Networking.xctestplan\ file to define test configurations and moves workspace and scheme files into the \.swiftpm\ directory. The updated \Networking.xcscheme\ now targets the \NetworkingTests\ test bundle directly, enables parallel test execution, and upgrades the scheme version to 1.7 (Xcode 14.3), replacing the previous \Tests.xcodeproj\-based setup.

.swiftpm · high confidence

Networking library rewritten with async/await, typed responses, and request interceptors

The networking layer has been completely rewritten to use Swift's async/await concurrency model, replacing the previous callback-based API. Requests now return a \Result\<T, NetworkingError\>\ envelope, providing consistent error handling and access to response metadata like status codes and headers alongside the payload. The library introduces a composable interceptor chain (\HTTPInterceptor\) that enables built-in features such as automatic authentication refresh, exponential backoff retry logic, and response validation. Additionally, a new caching system (\CacheStore\) supports both in-memory and on-disk storage with configurable TTLs and sharding, while the API now supports typed requests, form encoding, and multipart uploads.

Sources · high confidence

Removal of Networking module files

The Networking.h and Networking.m files in the Source directory have been deleted. This removes the existing networking implementation from the codebase, likely as part of a refactoring or migration process given the commit history mentions switching between NSURLSession and NSURLConnection.

Source · high confidence

Test coverage

Added comprehensive test coverage for the Networking library; Removal of legacy Objective-C test bundle; Removal of legacy Xcode project file for tests.

Dependencies

Migration to Swift Package Manager with Swift 6 and iOS 18 support

The project has switched from CocoaPods to Swift Package Manager (SPM) as its primary distribution mechanism. The new Package.swift defines the library for Swift 6 language mode and sets minimum deployment targets to iOS 18, macOS 15, tvOS 18, and watchOS 11. The legacy Networking.podspec has been removed, and the source structure has been updated to use a 'Sources' directory for the main target and a 'Tests' directory for the test target.

(dependencies) · high confidence

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

How this codebase got here

This is the PUBLIC form of this artifact. Findings are listed in full, but the details of SECURITY findings — which rule fired, in which file, on which line, and how to fix it — are deliberately withheld, and any secret-scanner results are excluded entirely. Where detail is absent here it was REMOVED FOR PUBLICATION; it is not missing from the analysis. The complete artifact is available from the repository owner.

Score

  • CAI 61 → 69 (+7.4)
  • Rubric changed (rubric-2026.09.11 → rubric-2026.09.18) — scores are not directly comparable.

Lenses

  • Code Health 94 → 96 (+2.1)
  • Architecture 89 → 96 (+7.1)
  • Maturity 46 → 63 (+17.6)
  • Readiness 54 → 57 (+3.3)
  • Security 100 → 92 (-8.0)

Resolved (8)

  • Dependency hygiene PARTLY measured — SwiftPM pinning read, dependency currency NOT established
  • FakeRequest.find (cognitive 42) (Sources/Networking/FakeRequest.swift)
  • FakeRequest.find (cyclomatic 18) (Sources/Networking/FakeRequest.swift)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • High: security finding (details withheld)
  • TooManyMethods: Networking (Sources/Networking/Networking.swift)

New (8)

  • Coverage not measured — Swift suite
  • DecodingError.detailedMessage (cognitive 18) (Sources/Networking/NetworkingError.swift)
  • Duplicate intent with different generic constraints. One overload takes a concrete array of URLQueryItems, the other takes a generic type Q. Without seeing the implementation of Q, it is unclear if this is a convenience for encoding structs vs manual query building, or if it's redundant. If Q is just a wrapper or protocol implemented by [URLQueryItem], it's confusing. If Q is a distinct encoding mechanism, the naming doesn't reflect that distinction clearly.
  • Duplicated block (7 lines × 4) (Sources/Networking/NetworkingError.swift)
  • High: security finding (details withheld)
  • Inconsistent authorization configuration API. The first two methods imply specific auth schemes (Basic and Bearer/Token), while the third is a generic header setter. This forces users to know the internal implementation details of how 'token' auth is handled versus generic headers, and creates ambiguity about precedence or behavior.
  • Inconsistent fake/mock API design. The fake methods have three distinct overloads for different response sources (Encodable object, raw headers/status, file path). This is inconsistent with the real API which uses a unified post/get with body/query parameters. The fake API forces users to choose a response format at the call site in a way that doesn't mirror the production API's structure, making mocking harder to reason about.
  • Inconsistent return types for similar operations. downloadImage returns Result<T, NetworkingError> (where T is likely Image based on context, but the signature is generic T), while downloadData also returns Result<T, NetworkingError>. However, looking at ImageResponse and DataResponse, there are specific response types. The generic T in the download methods is ambiguous. Does downloadImage return Result<Image, ...>? If so, why is it generic? If downloadData returns Result<Data, ...>, why is it generic? This suggests a lack of specific typing for these domain-specific downloads.

Changes since last survey

  • 8 commits — 8 feature/other, 0 fixes

By area

  • (root) — 2 commits
  • .github/workflows — 2 commits
  • Sources/Networking — 2 commits
  • Tests/NetworkingTests — 2 commits

Notable commits

  • change: Drop the config that 0.16.0 and swift-format already say (#332)
  • change: Lint gets its own workflow, and the checkout is a commit (#337)
  • change: Lint with oida, at zero baseline (#331)
  • change: One line length across every repo (#334)
  • change: The cancel path keeps its selection, not a void helper (#335)
  • change: The doc link check reads markdown, so it reads it on Linux (#339)
  • change: oida 0.16.1, and the isolation hop stops needing a disable (#336)
  • change: oida 0.17.1 (#338)

Written by watchdog.canine.dev from the codebase's own history, inside the signed delivery this page is composed from.

Survey your own repository

3lvis/Networking was measured the same way every project in this corpus was: the same rubric, at a pinned commit, with the result published in full. Point a surveyor at a repository you know and see whether you agree with it.

About this page

  • The score is its most recent published measurement, taken on 1 October 2026 at a pinned commit. It is not a live figure and does not change until the project is measured again.
  • Measured at commit ec2f04d61a86422d61c155865ad9806b7c4f1758 — the exact code this score is about.
  • Scored under rubric-2026.09.18 — the same rubric and the same method as every other entry in this index.
  • Measured by watchdog.canine.dev using codehealth-analyzer preprod-e569280dd5e2.