Skip to content

Remove the ReadiumInternal package#855

Merged
mickael-menu merged 4 commits into
swift6from
remove-readiuminternal
Jul 14, 2026
Merged

Remove the ReadiumInternal package#855
mickael-menu merged 4 commits into
swift6from
remove-readiuminternal

Conversation

@mickael-menu

Copy link
Copy Markdown
Member

Removed

  • The ReadiumInternal package has been removed. Its utilities were internal helpers and are now folded into ReadiumShared with package visibility. If you imported ReadiumInternal directly, remove the import.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Pull request overview

This pull request removes the ReadiumInternal SwiftPM/CocoaPods module and migrates its former helpers into ReadiumShared using Swift’s package visibility, while updating downstream modules, tests, and podspec tooling accordingly.

Changes:

  • Removed the ReadiumInternal target/podspecs and stripped import ReadiumInternal across the codebase.
  • Moved/merged internal helpers into ReadiumShared (mostly as package extensions) and added “unavailable” tombstones for a few previously-leaked helpers to provide clearer migration errors.
  • Updated sample apps/integrations (Playground/TestApp) and CocoaPods publishing scripts/specs to no longer reference ReadiumInternal.

Reviewed changes

Copilot reviewed 161 out of 161 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
Tests/StreamerTests/Parser/EPUB/EPUBMetadataParserTests.swift Removes ReadiumInternal import from Streamer tests.
Tests/StreamerTests/Parser/EPUB/EPUBManifestParserTests.swift Removes ReadiumInternal import from Streamer tests.
Tests/SharedTests/Toolkit/HTTP/DefaultHTTPClientTests.swift Drops ReadiumInternal import in Shared tests.
Tests/SharedTests/Toolkit/Extensions/URLTests.swift Switches test target from ReadiumInternal to ReadiumShared.
Tests/SharedTests/Toolkit/Extensions/RangeTests.swift Switches test target from ReadiumInternal to ReadiumShared.
Tests/SharedTests/Toolkit/Extensions/Date+ISO8601Tests.swift Switches test target from ReadiumInternal to ReadiumShared.
Tests/SharedTests/Toolkit/Data/Resource/TransformingResourceTests.swift Drops ReadiumInternal import in Shared tests.
Tests/SharedTests/Toolkit/Data/Resource/TailCachingResourceTests.swift Drops ReadiumInternal import in Shared tests.
Tests/SharedTests/Toolkit/Data/Resource/BufferingResourceTests.swift Drops ReadiumInternal import in Shared tests.
Tests/SharedTests/Publication/Services/Content/Iterators/PDFResourceContentIteratorTests.swift Drops ReadiumInternal import in Shared tests.
Tests/SharedTests/Publication/Extensions/Audio/Locator+AudioTests.swift Migrates off ReadiumInternal and updates prefix-removal helper usage.
Tests/SharedTests/OPDS/OPDSAvailabilityTests.swift Drops ReadiumInternal import in Shared tests.
Tests/InternalTests/KeychainTests.swift Removes obsolete ReadiumInternal test target file.
Tests/InternalTests/Extensions/StringTests.swift Removes obsolete ReadiumInternal test target file.
TestApp/Sources/Common/Toolkit/Extensions/String.swift Adds app-local replacement for sanitizedPathComponent.
TestApp/Sources/Common/Toolkit/Extensions/Optional.swift Adds app-local optional helpers previously sourced from internals.
TestApp/Sources/Common/Toolkit/Extensions/Collection.swift Adds app-local getOrNil helper.
TestApp/Sources/Common/Toolkit/Extensions/Array.swift Adds app-local array helpers (e.g. appending, removingDuplicates).
Support/CocoaPods/Specs.swift Removes ReadiumInternal module spec + dependencies in generated podspec model.
Support/CocoaPods/ReadiumStreamer.podspec Removes CocoaPods dependency on ReadiumInternal.
Support/CocoaPods/ReadiumShared.podspec Removes CocoaPods dependency on ReadiumInternal.
Support/CocoaPods/ReadiumOPDS.podspec Removes CocoaPods dependency on ReadiumInternal.
Support/CocoaPods/ReadiumNavigator.podspec Removes CocoaPods dependency on ReadiumInternal.
Support/CocoaPods/ReadiumLCP.podspec Removes CocoaPods dependency on ReadiumInternal.
Support/CocoaPods/ReadiumInternal.podspec Deletes the ReadiumInternal podspec.
Sources/Streamer/Parser/Readium/ReadiumWebPubParser.swift Removes ReadiumInternal import from Streamer parser code.
Sources/Streamer/Parser/PDF/Services/LCPDFTableOfContentsService.swift Removes ReadiumInternal import from PDF service.
Sources/Streamer/Parser/PDF/Services/LCPDFPositionsService.swift Removes ReadiumInternal import from PDF service.
Sources/Streamer/Parser/PDF/PDFParser.swift Removes ReadiumInternal import from PDF parser.
Sources/Streamer/Parser/EPUB/Services/EPUBPositionsService.swift Removes ReadiumInternal import from EPUB service.
Sources/Streamer/Parser/EPUB/OPFParser.swift Removes ReadiumInternal import from EPUB OPF parser.
Sources/Streamer/Parser/EPUB/EPUBMetadataParser.swift Removes ReadiumInternal import from metadata parser.
Sources/Streamer/Parser/Audio/AudioPublicationManifestAugmentor.swift Removes ReadiumInternal import from audio augmentor.
Sources/Streamer/Parser/Audio/AudioParser.swift Removes ReadiumInternal import from audio parser.
Sources/Shared/Toolkit/ZIP/ZIPFoundation/ZIPFoundationContainer.swift Removes ReadiumInternal import from ZIPFoundation container.
Sources/Shared/Toolkit/ZIP/ZIPFoundation/ZIPFoundationArchiveFactory.swift Removes ReadiumInternal import from ZIPFoundation factory.
Sources/Shared/Toolkit/ZIP/Minizip/MinizipContainer.swift Removes ReadiumInternal import from Minizip container.
Sources/Shared/Toolkit/UTI.swift Restricts UTI helper to package visibility.
Sources/Shared/Toolkit/URL/URLProtocol.swift Removes ReadiumInternal import from URL protocol utilities.
Sources/Shared/Toolkit/URL/URLExtensions.swift Adds/keeps URL helpers and introduces package-scoped scheme helper.
Sources/Shared/Toolkit/URL/URITemplate.swift Removes ReadiumInternal import from URI template implementation.
Sources/Shared/Toolkit/URL/RelativeURL.swift Removes ReadiumInternal import from relative URL type.
Sources/Shared/Toolkit/URL/AnyURL.swift Removes ReadiumInternal import from any URL type.
Sources/Shared/Toolkit/URL/Absolute URL/FileURL.swift Removes ReadiumInternal import from file URL type.
Sources/Shared/Toolkit/URL/Absolute URL/AbsoluteURL.swift Removes ReadiumInternal import from absolute URL protocol.
Sources/Shared/Toolkit/Throttle.swift Removes ReadiumInternal import from throttling utility.
Sources/Shared/Toolkit/Poller.swift Removes ReadiumInternal import from poller.
Sources/Shared/Toolkit/JSONValue.swift Removes ReadiumInternal import from JSON value utilities.
Sources/Shared/Toolkit/HTTP/HTTPClient.swift Removes ReadiumInternal import from HTTP client definitions.
Sources/Shared/Toolkit/HTTP/DefaultHTTPClient.swift Removes ReadiumInternal import from default HTTP client.
Sources/Shared/Toolkit/Format/Sniffers/HTMLFormatSniffer.swift Removes ReadiumInternal import from HTML sniffer.
Sources/Shared/Toolkit/Format/Sniffers/EPUBFormatSniffer.swift Removes ReadiumInternal import from EPUB sniffer.
Sources/Shared/Toolkit/Format/Sniffers/CompositeFormatSniffer.swift Removes ReadiumInternal import from composite sniffer.
Sources/Shared/Toolkit/Format/MediaType.swift Removes ReadiumInternal import from media type helper.
Sources/Shared/Toolkit/Format/FormatSnifferBlob.swift Removes ReadiumInternal import from sniffer blob actor.
Sources/Shared/Toolkit/Format/FormatSniffer.swift Removes ReadiumInternal import from sniffer protocols.
Sources/Shared/Toolkit/Format/Format.swift Removes ReadiumInternal import from format type.
Sources/Shared/Toolkit/File/FileResource.swift Removes ReadiumInternal import from file-backed resource.
Sources/Shared/Toolkit/Extensions/UInt64.swift Restricts numeric helper to package visibility.
Sources/Shared/Toolkit/Extensions/Task.swift Restricts Task helpers to package and removes leaked replace.
Sources/Shared/Toolkit/Extensions/String.swift Restricts String helpers to package and removes leaked helpers.
Sources/Shared/Toolkit/Extensions/Sequence.swift Restricts Sequence helpers to package.
Sources/Shared/Toolkit/Extensions/Result.swift Restricts Result helpers to package and removes leaked helpers.
Sources/Shared/Toolkit/Extensions/Range.swift Adds/migrates HTTP Range parsing helper as package.
Sources/Shared/Toolkit/Extensions/Optional.swift Restricts Optional helpers to package and adds async variants.
Sources/Shared/Toolkit/Extensions/Number.swift Restricts Numeric helpers to package.
Sources/Shared/Toolkit/Extensions/NSRegularExpression.swift Restricts regex helpers/types to package.
Sources/Shared/Toolkit/Extensions/Double.swift Restricts Double helper to package.
Sources/Shared/Toolkit/Extensions/Deprecations.swift Adds unavailable “tombstones” for leaked helpers with migration messages.
Sources/Shared/Toolkit/Extensions/Date+ISO8601.swift Restricts ISO-8601 helpers to package.
Sources/Shared/Toolkit/Extensions/Data.swift Restricts Data helpers to package.
Sources/Shared/Toolkit/Extensions/Comparable.swift Restricts Comparable helpers to package.
Sources/Shared/Toolkit/Extensions/Collection.swift Restricts Collection helpers to package.
Sources/Shared/Toolkit/Extensions/Array.swift Restricts Array helpers to package and removes leaked helpers.
Sources/Shared/Toolkit/DocumentTypes.swift Removes ReadiumInternal import from document type utilities.
Sources/Shared/Toolkit/Data/Streamable.swift Removes ReadiumInternal import from Streamable protocol.
Sources/Shared/Toolkit/Data/Resource/TransformingResource.swift Removes ReadiumInternal import from transforming resource.
Sources/Shared/Toolkit/Data/Resource/TailCachingResource.swift Removes ReadiumInternal import from tail caching resource.
Sources/Shared/Toolkit/Data/Resource/ResourceContentExtractor.swift Removes ReadiumInternal import from resource content extractor.
Sources/Shared/Toolkit/Data/Resource/BufferingResource.swift Removes ReadiumInternal import from buffering resource.
Sources/Shared/Toolkit/Data/Container/Container.swift Removes ReadiumInternal import from container protocol.
Sources/Shared/Toolkit/Data/Asset/AssetRetriever.swift Removes ReadiumInternal import from asset retriever.
Sources/Shared/Toolkit/Archive/ArchiveProperties.swift Removes ReadiumInternal import from archive properties.
Sources/Shared/Publication/TDM.swift Removes ReadiumInternal import from publication model.
Sources/Shared/Publication/Subject.swift Removes ReadiumInternal import from publication model.
Sources/Shared/Publication/Services/Search/SearchService.swift Removes ReadiumInternal import from service definitions.
Sources/Shared/Publication/Services/Locator/DefaultLocatorService.swift Removes ReadiumInternal import from locator service.
Sources/Shared/Publication/Services/Content/Iterators/PublicationContentIterator.swift Removes ReadiumInternal import from iterators.
Sources/Shared/Publication/Services/Content/Iterators/PDFResourceContentIterator.swift Removes ReadiumInternal import from PDF iterator.
Sources/Shared/Publication/Services/Content/Iterators/HTMLResourceContentIterator.swift Removes ReadiumInternal import from HTML iterator.
Sources/Shared/Publication/Services/Content/ContentTokenizer.swift Removes ReadiumInternal import from tokenizer.
Sources/Shared/Publication/Services/Content/Content.swift Removes ReadiumInternal import from content protocol.
Sources/Shared/Publication/PublicationCollection.swift Removes ReadiumInternal import from collection model.
Sources/Shared/Publication/Publication.swift Removes ReadiumInternal import from publication model.
Sources/Shared/Publication/Properties.swift Removes ReadiumInternal import from manifest model.
Sources/Shared/Publication/Metadata.swift Removes ReadiumInternal import from manifest model.
Sources/Shared/Publication/Manifest.swift Removes ReadiumInternal import from manifest model.
Sources/Shared/Publication/Locator.swift Removes ReadiumInternal import from locator model.
Sources/Shared/Publication/LocalizedString.swift Removes ReadiumInternal import from localized string type.
Sources/Shared/Publication/LinkRelation.swift Removes ReadiumInternal import from link model.
Sources/Shared/Publication/Link.swift Removes ReadiumInternal import from link model.
Sources/Shared/Publication/GuidedNavigation/GuidedNavigationObject.swift Removes ReadiumInternal import from guided navigation model.
Sources/Shared/Publication/GuidedNavigation/GuidedNavigationDocument.swift Removes ReadiumInternal import from guided navigation model.
Sources/Shared/Publication/Extensions/OPDS/Properties+OPDS.swift Removes ReadiumInternal import from OPDS extensions.
Sources/Shared/Publication/Extensions/HTML/DOMRange.swift Removes ReadiumInternal import from HTML extensions.
Sources/Shared/Publication/Extensions/EPUB/Properties+EPUB.swift Removes ReadiumInternal import from EPUB extensions.
Sources/Shared/Publication/Extensions/EPUB/EPUBMediaOverlay.swift Removes ReadiumInternal import from EPUB extensions.
Sources/Shared/Publication/Extensions/Encryption/Encryption.swift Removes ReadiumInternal import from encryption model.
Sources/Shared/Publication/Contributor.swift Removes ReadiumInternal import from contributor model.
Sources/Shared/Publication/Accessibility/AccessibilityMetadataDisplayGuide.swift Removes ReadiumInternal import from accessibility model.
Sources/Shared/Publication/Accessibility/Accessibility.swift Removes ReadiumInternal import from accessibility model.
Sources/Shared/OPDS/OPDSPrice.swift Removes ReadiumInternal import from OPDS model.
Sources/Shared/OPDS/OPDSHolds.swift Removes ReadiumInternal import from OPDS model.
Sources/Shared/OPDS/OPDSCopies.swift Removes ReadiumInternal import from OPDS model.
Sources/Shared/OPDS/OPDSAvailability.swift Removes ReadiumInternal import from OPDS model.
Sources/Shared/OPDS/OPDSAcquisition.swift Removes ReadiumInternal import from OPDS model.
Sources/OPDS/OPDS2Parser.swift Removes ReadiumInternal import from OPDS parser.
Sources/OPDS/OPDS1Parser.swift Removes ReadiumInternal import from OPDS parser.
Sources/Navigator/Viewport/ViewportProgressionCalculator.swift Removes ReadiumInternal import from Navigator.
Sources/Navigator/TTS/TTSVoice.swift Removes ReadiumInternal import from TTS.
Sources/Navigator/TTS/PublicationSpeechSynthesizer.swift Removes ReadiumInternal import from TTS.
Sources/Navigator/Toolkit/PaginationView.swift Removes ReadiumInternal import from UI toolkit.
Sources/Navigator/Toolkit/HTMLInjection.swift Removes ReadiumInternal import from HTML injection support.
Sources/Navigator/Preferences/Types.swift Removes ReadiumInternal import from preferences.
Sources/Navigator/Preferences/ProxyPreference.swift Migrates import to ReadiumShared.
Sources/Navigator/Preferences/ProgressionStrategy.swift Migrates import to ReadiumShared.
Sources/Navigator/Preferences/MappedPreference.swift Migrates import to ReadiumShared.
Sources/Navigator/PDF/Preferences/PDFSettings.swift Removes ReadiumInternal import from PDF settings.
Sources/Navigator/PDF/PDFViewportCalculator.swift Removes ReadiumInternal import from PDF viewport calculation.
Sources/Navigator/PDF/PDFPageNumberResolver.swift Removes ReadiumInternal import from PDF resolver.
Sources/Navigator/PDF/PDFNavigatorViewController.swift Removes ReadiumInternal import from PDF navigator.
Sources/Navigator/Navigator.swift Removes ReadiumInternal import from public Navigator APIs.
Sources/Navigator/EPUB/WebViewServer.swift Removes ReadiumInternal import from WebView server.
Sources/Navigator/EPUB/Preferences/EPUBPreferencesEditor.swift Removes ReadiumInternal import from EPUB preferences.
Sources/Navigator/EPUB/Preferences/EPUBPreferences+Legacy.swift Removes ReadiumInternal import from EPUB preferences.
Sources/Navigator/EPUB/Preferences/EPUBPreferences.swift Removes ReadiumInternal import from EPUB preferences.
Sources/Navigator/EPUB/EPUBViewportAndLocationCalculator.swift Removes ReadiumInternal import from EPUB calculations.
Sources/Navigator/EPUB/EPUBSpreadView.swift Removes ReadiumInternal import from EPUB view layer.
Sources/Navigator/EPUB/EPUBSpread.swift Removes ReadiumInternal import from EPUB spread model.
Sources/Navigator/EPUB/EPUBReflowableSpreadView.swift Removes ReadiumInternal import from EPUB reflow view.
Sources/Navigator/EPUB/EPUBNavigatorViewModel.swift Removes ReadiumInternal import from view model.
Sources/Navigator/EPUB/EPUBNavigatorViewController.swift Removes ReadiumInternal import from EPUB navigator UI.
Sources/Navigator/EPUB/CSS/ReadiumCSS.swift Removes ReadiumInternal import from CSS helper.
Sources/Navigator/Audiobook/PublicationMediaLoader.swift Removes ReadiumInternal import from audiobook loader.
Sources/Navigator/Audiobook/Preferences/AudioPreferencesEditor.swift Migrates import to ReadiumShared.
Sources/LCP/Services/PassphrasesService.swift Removes ReadiumInternal import from LCP services.
Sources/LCP/License/LicenseValidation.swift Removes ReadiumInternal import from LCP license logic.
Sources/LCP/License/License.swift Removes ReadiumInternal import from LCP license logic.
Sources/LCP/Content Protection/LCPDecryptor.swift Removes ReadiumInternal import from LCP decryptor.
Sources/LCP/Content Protection/LCPContentProtection.swift Removes ReadiumInternal import from content protection.
Sources/LCP/Content Protection/EncryptionParser.swift Removes ReadiumInternal import from encryption parsing.
Sources/LCP/Authentications/LCPDialogViewController.swift Removes ReadiumInternal import from auth UI.
Sources/LCP/Authentications/LCPDialog.swift Removes ReadiumInternal import from auth UI.
Sources/Internal/Extensions/URL.swift Deletes Internal URL helpers (now in Shared / tombstoned).
Sources/Internal/Extensions/Range.swift Deletes Internal Range helpers (now in Shared).
Sources/Internal/Extensions/Optional.swift Deletes Internal Optional helpers (now in Shared).
scripts/release-publish-podspecs.sh Removes ReadiumInternal from podspec publishing order.
Playground/Sources/App/Data/DocumentRepository.swift Inlines safe indexing after getOrNil becomes non-public/package-only.
Playground/Playground.xctestplan Removes ReadiumInternalTests from Playground test plan.
Package.swift Removes ReadiumInternal/ReadiumInternalTests targets from SwiftPM manifest.
CHANGELOG.md Adds changelog entry documenting removal of ReadiumInternal.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread Sources/Shared/Toolkit/Extensions/Deprecations.swift Outdated
Comment thread Sources/Shared/Toolkit/Extensions/Deprecations.swift
Comment thread Package.swift
Comment thread Tests/InternalTests/KeychainTests.swift
@mickael-menu
mickael-menu requested a review from stevenzeck July 14, 2026 10:20
@mickael-menu
mickael-menu merged commit 69968f3 into swift6 Jul 14, 2026
5 checks passed
@mickael-menu
mickael-menu deleted the remove-readiuminternal branch July 14, 2026 14:42
mickael-menu added a commit that referenced this pull request Jul 17, 2026
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.

3 participants