From 23fca6f4e182c5040bfbabe23d5dfe6ed303a9f2 Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 15 Mar 2024 16:22:47 +0100 Subject: [PATCH 01/11] Bump swift tools version --- Package.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Package.swift b/Package.swift index 19654c66..2bd81d6c 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.8 +// swift-tools-version:5.9 import PackageDescription From 26365f9dd4f0e77701bd1a1cc306b0cbae5d729b Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 24 May 2024 15:00:33 +0200 Subject: [PATCH 02/11] Enable complete concurrency checking --- Package.swift | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Package.swift b/Package.swift index 2bd81d6c..58c2614d 100644 --- a/Package.swift +++ b/Package.swift @@ -32,7 +32,10 @@ let package = Package( dependencies: [ .product(name: "Collections", package: "swift-collections") ], - exclude: ["Abstraction/README.md", "Framework/README.md"] + exclude: ["Abstraction/README.md", "Framework/README.md"], + swiftSettings: [ + .enableExperimentalFeature("StrictConcurrency=complete") + ] ), .target( name: "HTMLKitConverter", @@ -54,6 +57,9 @@ let package = Package( dependencies: [ .target(name: "HTMLKit"), .product(name: "Vapor", package: "vapor"), + ], + swiftSettings: [ + .enableExperimentalFeature("StrictConcurrency=complete") ] ), .target( From 2d964782ca578cd095af677cce8cb3b4e4dfe2f9 Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 24 May 2024 15:42:12 +0200 Subject: [PATCH 03/11] Update test workflow --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 9527b938..22724929 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -9,7 +9,7 @@ on: jobs: test-pushpull: runs-on: ubuntu-latest - container: swift:5.8-focal + container: swift:5.9.2-jammy steps: - uses: actions/checkout@v3 - name: Run tests From 558f10200eafc449353d77b6f43aa42ddbdf2b1e Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Mon, 2 Sep 2024 20:03:51 +0200 Subject: [PATCH 04/11] Make the features optionset sendable --- Sources/HTMLKit/Framework/Rendering/Features.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/HTMLKit/Framework/Rendering/Features.swift b/Sources/HTMLKit/Framework/Rendering/Features.swift index 780ea9e2..697a2ae6 100644 --- a/Sources/HTMLKit/Framework/Rendering/Features.swift +++ b/Sources/HTMLKit/Framework/Rendering/Features.swift @@ -1,5 +1,5 @@ /// An option set of features. -public struct Features: OptionSet { +public struct Features: OptionSet, Sendable { public var rawValue: Int From 12760a293a20c0427c127003e543ef1a3d1d87c5 Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Mon, 2 Sep 2024 20:06:33 +0200 Subject: [PATCH 05/11] Make the markdown structure sendable --- Sources/HTMLKit/Framework/Rendering/Markdown/Markdown.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/HTMLKit/Framework/Rendering/Markdown/Markdown.swift b/Sources/HTMLKit/Framework/Rendering/Markdown/Markdown.swift index a13a3de7..9a46b776 100644 --- a/Sources/HTMLKit/Framework/Rendering/Markdown/Markdown.swift +++ b/Sources/HTMLKit/Framework/Rendering/Markdown/Markdown.swift @@ -1,6 +1,6 @@ import Foundation -internal final class Markdown { +internal struct Markdown: Sendable { /// The markdowns characters internal static let characters = CharacterSet(charactersIn: "*_~[`") From 8277c8fd942015bd3d96fe6fc6fda9c62dd84c9a Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 28 Nov 2025 10:10:34 +0100 Subject: [PATCH 06/11] Bump swift tools version --- Package.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Package.swift b/Package.swift index 9ac366b1..e81545f7 100644 --- a/Package.swift +++ b/Package.swift @@ -1,4 +1,4 @@ -// swift-tools-version:5.9 +// swift-tools-version:5.10 import PackageDescription From b79b4cb17f6996e6ef19f6ad2fd6be4dde5a4b17 Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 28 Nov 2025 15:07:05 +0100 Subject: [PATCH 07/11] Mark the interpolationargument enum as sendable --- .../HTMLKit/Framework/Localization/InterpolationArgument.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/HTMLKit/Framework/Localization/InterpolationArgument.swift b/Sources/HTMLKit/Framework/Localization/InterpolationArgument.swift index 415c7513..83c1e7f2 100644 --- a/Sources/HTMLKit/Framework/Localization/InterpolationArgument.swift +++ b/Sources/HTMLKit/Framework/Localization/InterpolationArgument.swift @@ -5,7 +5,7 @@ import Foundation /// Each case corresponds to a specific data type and provides a placeholder /// that can be used for replacing values in the localized string. @_documentation(visibility: internal) -public enum InterpolationArgument { +public enum InterpolationArgument: Sendable { /// Holds an integer value case int(Int) From 2509f182ed9565958b5bf94202f7b1fefc9f0f47 Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 28 Nov 2025 15:08:56 +0100 Subject: [PATCH 08/11] Mark the localizedstringkey structure as sendable --- Sources/HTMLKit/Framework/Localization/LocalizedStringKey.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/HTMLKit/Framework/Localization/LocalizedStringKey.swift b/Sources/HTMLKit/Framework/Localization/LocalizedStringKey.swift index 0e138f5e..ce657c34 100644 --- a/Sources/HTMLKit/Framework/Localization/LocalizedStringKey.swift +++ b/Sources/HTMLKit/Framework/Localization/LocalizedStringKey.swift @@ -2,7 +2,7 @@ import Foundation /// A string key for the localization @_documentation(visibility: internal) -public struct LocalizedStringKey { +public struct LocalizedStringKey: Sendable { /// The key value internal let value: String From f3d9fa30e0eac09034cefc6fb1e9ff19e0fd0c4d Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 28 Nov 2025 15:11:40 +0100 Subject: [PATCH 09/11] Mark the translationtable structure as sendable --- Sources/HTMLKit/Framework/Localization/TranslationTable.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/HTMLKit/Framework/Localization/TranslationTable.swift b/Sources/HTMLKit/Framework/Localization/TranslationTable.swift index cd6a481b..b47f6caf 100644 --- a/Sources/HTMLKit/Framework/Localization/TranslationTable.swift +++ b/Sources/HTMLKit/Framework/Localization/TranslationTable.swift @@ -1,7 +1,7 @@ /// A type that represents a translation table /// /// A translation table stores multiple localized strings, mapping unique string keys to their corresponding translations -internal struct TranslationTable { +internal struct TranslationTable: Sendable { /// The name of the table internal let name: String From 76ba9124496e0a7a143673240b4934fe7de5c90f Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 28 Nov 2025 15:42:13 +0100 Subject: [PATCH 10/11] Mark the localizedstring structure as sendable --- Sources/HTMLKit/Framework/Localization/LocalizedString.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Sources/HTMLKit/Framework/Localization/LocalizedString.swift b/Sources/HTMLKit/Framework/Localization/LocalizedString.swift index fa00f711..a88668b3 100644 --- a/Sources/HTMLKit/Framework/Localization/LocalizedString.swift +++ b/Sources/HTMLKit/Framework/Localization/LocalizedString.swift @@ -2,7 +2,7 @@ import Foundation /// A type thats holds the information for the localization @_documentation(visibility: internal) -public struct LocalizedString: Content { +public struct LocalizedString: Content, Sendable { /// The key of the translation value internal let key: LocalizedStringKey From 2c3bb7094de0402e2acff76b75f65e37f56de94a Mon Sep 17 00:00:00 2001 From: Mattes Mohr Date: Fri, 28 Nov 2025 15:42:45 +0100 Subject: [PATCH 11/11] Update test workflow --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 22724929..0296e0e9 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -9,7 +9,7 @@ on: jobs: test-pushpull: runs-on: ubuntu-latest - container: swift:5.9.2-jammy + container: swift:5.10.1-jammy steps: - uses: actions/checkout@v3 - name: Run tests