Repository navigation
Conversation
petstore.swagger.io now answers plain http with a 302 to https. On the iOS 26 simulator used by CI, the redirected POST is re-sent as a GET, so creating pets and placing orders fails with 405 and the dependent tests fail with 404 or time out. Point the test apps of the nine swift6 samples at https://petstore.swagger.io/v2 at launch.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Bitrise swift6 job currently fails on every PR that touches the swift6 samples (e.g. #25188 to #25194). The test apps call
http://petstore.swagger.io:80/v2, the spec's host, and petstore.swagger.io now answers plain http with a302tohttps://petstore.swagger.io:443/.... On the iOS 26 simulator used by CI, URLSession re-sends the redirected POST as a GET, soaddPetandplaceOrderfail with405and the dependent get/delete tests fail with404or time out. That's 14 failures in alamofireLibrary, and the script stops there, so the other samples' tests never run.This sets
PetstoreClientAPIConfiguration.shared.basePath = "https://petstore.swagger.io/v2"indidFinishLaunchingof the nine swift6 test host apps run byswift6_test_all.sh. Specs and generated samples are unchanged:defaultuses the shared 2.0 petstore spec, and the Swift-specific spec also feeds the swift5 samples, so changing the host there would touch many unrelated samples.Checked: all nine test projects build with
build-for-testing, andaddPet,getPetById,placeOrderanddeletePetsucceed againsthttps://petstore.swagger.io/v2with the generated client. macOS 27's URLSession upgrades the http request to https on its own, which is why the failure doesn't reproduce on newer OS versions.PR checklist
Summary by cubic
Fixes the Bitrise swift6 CI job, which fails on every PR that touches the swift6 samples. The test apps call
http://petstore.swagger.io:80/v2, the spec's host, and petstore.swagger.io now answers plain http with a 302 tohttps://petstore.swagger.io:443/.... On the iOS 26 simulator used by CI, URLSession re-sends the redirected POST as a GET, soaddPetandplaceOrderfail with 405 and the dependent get/delete tests fail with 404 or time out.Sets
PetstoreClientAPIConfiguration.shared.basePathtohttps://petstore.swagger.io/v2indidFinishLaunchingof the nine swift6 test host apps run byswift6_test_all.sh, adding the missingPetstoreClientimport where needed. Specs and generated samples are unchanged. macOS 27's URLSession upgrades the http request to https on its own, which is why the failure doesn't reproduce on newer OS versions.Written for commit 385c872. Summary will update on new commits.