Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 95bb2f8

Browse files
Enable strict concurrency checking in CI (#11)
Enable strict concurrency checking in CI ### Motivation To further avoid concurrency bugs, enable complete concurrency checking in CI. ### Modifications Added the compiler flag to the docker-compose scripts. ### Result If a warning of this nature comes up, because we have warnings-as-errors, it'll fail CI. ### Test Plan Locally built without any warnings with the flag enabled. Reviewed by: glbrntt Builds: ✔︎ pull request validation (5.8) - Build finished. ✔︎ pull request validation (5.9) - Build finished. ✔︎ pull request validation (nightly) - Build finished. ✔︎ pull request validation (soundness) - Build finished. #11
1 parent 762f5e5 commit 95bb2f8

File tree

5 files changed

+12
-2
lines changed

5 files changed

+12
-2
lines changed

‎Sources/OpenAPIAsyncHTTPClient/AsyncHTTPClientTransport.swift

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,15 @@ import OpenAPIRuntime
1515
import AsyncHTTPClient
1616
import NIOCore
1717
import NIOHTTP1
18-
import Foundation
1918
import NIOFoundationCompat
19+
#if canImport(Darwin)
20+
import Foundation
21+
#else
22+
@preconcurrency import struct Foundation.URL
23+
import struct Foundation.URLComponents
24+
import struct Foundation.Data
25+
import protocol Foundation.LocalizedError
26+
#endif
2027

2128
/// A client transport that performs HTTP operations using the HTTPClient type
2229
/// provided by the AsyncHTTPClient library.

‎docker/docker-compose.2204.58.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ services:
1313
environment:
1414
- WARN_AS_ERROR_ARG=-Xswiftc -warnings-as-errors
1515
- IMPORT_CHECK_ARG=--explicit-target-dependency-import-check error
16+
- STRICT_CONCURRENCY_ARG=-Xswiftc -strict-concurrency=complete
1617

1718
shell:
1819
image: *image

‎docker/docker-compose.2204.59.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ services:
1212
environment:
1313
- WARN_AS_ERROR_ARG=-Xswiftc -warnings-as-errors
1414
- IMPORT_CHECK_ARG=--explicit-target-dependency-import-check error
15+
- STRICT_CONCURRENCY_ARG=-Xswiftc -strict-concurrency=complete
1516

1617
shell:
1718
image: *image

‎docker/docker-compose.2204.main.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ services:
1212
environment:
1313
- WARN_AS_ERROR_ARG=-Xswiftc -warnings-as-errors
1414
- IMPORT_CHECK_ARG=--explicit-target-dependency-import-check error
15+
- STRICT_CONCURRENCY_ARG=-Xswiftc -strict-concurrency=complete
1516

1617
shell:
1718
image: *image

‎docker/docker-compose.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ services:
3030

3131
test:
3232
<<: *common
33-
command: /bin/bash -xcl "swift $${SWIFT_TEST_VERB-test} $${WARN_AS_ERROR_ARG-} $${SANITIZER_ARG-} $${IMPORT_CHECK_ARG-}"
33+
command: /bin/bash -xcl "swift $${SWIFT_TEST_VERB-test} $${WARN_AS_ERROR_ARG-} $${SANITIZER_ARG-} $${IMPORT_CHECK_ARG-} $${STRICT_CONCURRENCY_ARG-}"
3434

3535
shell:
3636
<<: *common

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /