From 5f094bcf798ca85f1c3d914eae46701ed3b12cdd Mon Sep 17 00:00:00 2001 From: Aleksei Sapitskii Date: Wed, 13 Nov 2024 17:24:05 +0200 Subject: [PATCH] //wip --- Cartfile | 3 +- Cartfile.Turf.json | 1 + Cartfile.resolved | 1 + MapboxSearch.podspec | 2 +- MapboxSearch.xcodeproj/project.pbxproj | 8 +-- Package.resolved | 69 ++++++++++--------- Package.swift | 4 +- .../PublicAPI/SearchOptions.swift | 2 +- .../Common/Extensions/LotLan+Extensions.swift | 6 -- 9 files changed, 49 insertions(+), 47 deletions(-) create mode 100644 Cartfile.Turf.json diff --git a/Cartfile b/Cartfile index 2314fdd04..63bf6d94f 100644 --- a/Cartfile +++ b/Cartfile @@ -1,2 +1,3 @@ binary "https://api.mapbox.com/downloads/v2/carthage/search-core-sdk/MapboxCoreSearch.xcframework.json" == 2.6.0 -binary "https://api.mapbox.com/downloads/v2/carthage/mapbox-common/MapboxCommon.json" == 24.8.0 \ No newline at end of file +binary "https://api.mapbox.com/downloads/v2/carthage/mapbox-common/MapboxCommon.json" == 24.9.0-daily-2024-11-13-08-38 +binary "Cartfile.Turf.json" == 4.0.0-beta.1 diff --git a/Cartfile.Turf.json b/Cartfile.Turf.json new file mode 100644 index 000000000..31b3bbe9b --- /dev/null +++ b/Cartfile.Turf.json @@ -0,0 +1 @@ +{ "4.0.0-beta.1": "https://github.com/mapbox/turf-swift/releases/download/v4.0.0-beta.1/Turf.xcframework.zip" } diff --git a/Cartfile.resolved b/Cartfile.resolved index ee89f6a54..f435e1a10 100644 --- a/Cartfile.resolved +++ b/Cartfile.resolved @@ -1,2 +1,3 @@ +binary "Cartfile.Turf.json" "4.0.0-beta.1" binary "https://api.mapbox.com/downloads/v2/carthage/mapbox-common/MapboxCommon.json" "24.8.0" binary "https://api.mapbox.com/downloads/v2/carthage/search-core-sdk/MapboxCoreSearch.xcframework.json" "2.6.0" diff --git a/MapboxSearch.podspec b/MapboxSearch.podspec index bbfd179d3..119d3c6d2 100644 --- a/MapboxSearch.podspec +++ b/MapboxSearch.podspec @@ -25,5 +25,5 @@ Some iOS platform specifics applies. s.vendored_frameworks = "**/#{s.name}.xcframework" s.dependency "MapboxCoreSearch", '2.6.0' - s.dependency "MapboxCommon", '24.8.0' + s.dependency "MapboxCommon", '24.9.0-daily-2024-11-13-08-38' end diff --git a/MapboxSearch.xcodeproj/project.pbxproj b/MapboxSearch.xcodeproj/project.pbxproj index 9ecf9a5e6..d5e1bf0c1 100644 --- a/MapboxSearch.xcodeproj/project.pbxproj +++ b/MapboxSearch.xcodeproj/project.pbxproj @@ -170,8 +170,8 @@ 2CE1B9FD2A13D41A005B043F /* address-suggestions-san-francisco.json in Resources */ = {isa = PBXBuildFile; fileRef = 2CE1B9F92A13D412005B043F /* address-suggestions-san-francisco.json */; }; 2CE1B9FE2A13D41A005B043F /* address-retrieve-san-francisco.json in Resources */ = {isa = PBXBuildFile; fileRef = 2CE1B9FA2A13D412005B043F /* address-retrieve-san-francisco.json */; }; 3A0D7E56233522D5006D81BB /* MapboxSearch.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3A0D7E4C233522D4006D81BB /* MapboxSearch.framework */; }; + 5550E1162CD7ACE200191EF8 /* MapboxCoreSearch.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = 5550E1152CD7ACE200191EF8 /* MapboxCoreSearch.xcframework */; }; DFBC8A6D2AD42F5F00D394EF /* Any+dumpAsString.swift in Sources */ = {isa = PBXBuildFile; fileRef = DFBC8A6C2AD42F5F00D394EF /* Any+dumpAsString.swift */; }; - E648C0B626428D2B0044315F /* MapboxCoreSearch.xcframework in Frameworks */ = {isa = PBXBuildFile; fileRef = E648C0B526428D2B0044315F /* MapboxCoreSearch.xcframework */; }; E648C0C9264297A10044315F /* libc++.1.tbd in Frameworks */ = {isa = PBXBuildFile; fileRef = E648C0C8264297730044315F /* libc++.1.tbd */; }; F907440F261B00000091899C /* suggestions-san-francisco.json in Resources */ = {isa = PBXBuildFile; fileRef = F907440E261B00000091899C /* suggestions-san-francisco.json */; }; F9074425261B0DF70091899C /* retrieve-san-francisco.json in Resources */ = {isa = PBXBuildFile; fileRef = F9074424261B0DF70091899C /* retrieve-san-francisco.json */; }; @@ -674,8 +674,8 @@ 2CE1B9FA2A13D412005B043F /* address-retrieve-san-francisco.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = "address-retrieve-san-francisco.json"; sourceTree = ""; }; 3A0D7E4C233522D4006D81BB /* MapboxSearch.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = MapboxSearch.framework; sourceTree = BUILT_PRODUCTS_DIR; }; 3A0D7E55233522D5006D81BB /* MapboxSearchTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = MapboxSearchTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; + 5550E1152CD7ACE200191EF8 /* MapboxCoreSearch.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = MapboxCoreSearch.xcframework; path = Carthage/Build/MapboxCoreSearch.xcframework; sourceTree = ""; }; DFBC8A6C2AD42F5F00D394EF /* Any+dumpAsString.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = "Any+dumpAsString.swift"; sourceTree = ""; }; - E648C0B526428D2B0044315F /* MapboxCoreSearch.xcframework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.xcframework; name = MapboxCoreSearch.xcframework; path = Carthage/Build/MapboxCoreSearch.xcframework; sourceTree = ""; }; E648C0B926428D3D0044315F /* MapboxCommon.xcframework */ = {isa = PBXFileReference; expectedSignature = "AppleDeveloperProgram:GJZR2MEM28:Mapbox, Inc."; lastKnownFileType = wrapper.xcframework; name = MapboxCommon.xcframework; path = Carthage/Build/MapboxCommon.xcframework; sourceTree = ""; }; E648C0C8264297730044315F /* libc++.1.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = "libc++.1.tbd"; path = "usr/lib/libc++.1.tbd"; sourceTree = SDKROOT; }; F907440E261B00000091899C /* suggestions-san-francisco.json */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.json; path = "suggestions-san-francisco.json"; sourceTree = ""; }; @@ -959,7 +959,7 @@ buildActionMask = 2147483647; files = ( 042BEB172C2DDFAA0004CD7B /* MapboxCommon in Frameworks */, - E648C0B626428D2B0044315F /* MapboxCoreSearch.xcframework in Frameworks */, + 5550E1162CD7ACE200191EF8 /* MapboxCoreSearch.xcframework in Frameworks */, E648C0C9264297A10044315F /* libc++.1.tbd in Frameworks */, ); runOnlyForDeploymentPostprocessing = 0; @@ -1576,9 +1576,9 @@ 3A0972062361A19E003F200F /* Frameworks */ = { isa = PBXGroup; children = ( + 5550E1152CD7ACE200191EF8 /* MapboxCoreSearch.xcframework */, E648C0C8264297730044315F /* libc++.1.tbd */, E648C0B926428D3D0044315F /* MapboxCommon.xcframework */, - E648C0B526428D2B0044315F /* MapboxCoreSearch.xcframework */, ); name = Frameworks; sourceTree = ""; diff --git a/Package.resolved b/Package.resolved index 943ea9041..be379888c 100644 --- a/Package.resolved +++ b/Package.resolved @@ -1,34 +1,41 @@ { - "object": { - "pins": [ - { - "package": "CwlCatchException", - "repositoryURL": "https://github.com/mattgallagher/CwlCatchException.git", - "state": { - "branch": null, - "revision": "3b123999de19bf04905bc1dfdb76f817b0f2cc00", - "version": "2.1.2" - } - }, - { - "package": "CwlPreconditionTesting", - "repositoryURL": "https://github.com/mattgallagher/CwlPreconditionTesting.git", - "state": { - "branch": null, - "revision": "dc9af4781f2afdd1e68e90f80b8603be73ea7abc", - "version": "2.2.0" - } - }, - { - "package": "MapboxCommon", - "repositoryURL": "https://github.com/mapbox/mapbox-common-ios.git", - "state": { - "branch": null, - "revision": "66c604ce480a5d2e98dbe017b49886652d4d89a2", - "version": "24.0.0" - } + "pins" : [ + { + "identity" : "cwlcatchexception", + "kind" : "remoteSourceControl", + "location" : "https://github.com/mattgallagher/CwlCatchException.git", + "state" : { + "revision" : "3b123999de19bf04905bc1dfdb76f817b0f2cc00", + "version" : "2.1.2" } - ] - }, - "version": 1 + }, + { + "identity" : "cwlpreconditiontesting", + "kind" : "remoteSourceControl", + "location" : "https://github.com/mattgallagher/CwlPreconditionTesting.git", + "state" : { + "revision" : "dc9af4781f2afdd1e68e90f80b8603be73ea7abc", + "version" : "2.2.0" + } + }, + { + "identity" : "mapbox-common-ios", + "kind" : "remoteSourceControl", + "location" : "https://github.com/mapbox/mapbox-common-ios.git", + "state" : { + "revision" : "a84d60cd007dd7a5119712a22324a531e33c6236", + "version" : "24.9.0-daily-2024-11-13-08-38" + } + }, + { + "identity" : "turf-swift", + "kind" : "remoteSourceControl", + "location" : "https://github.com/mapbox/turf-swift.git", + "state" : { + "revision" : "f869ec2055ace4f95101b623a45f1506fa6f1503", + "version" : "4.0.0-beta.1" + } + } + ], + "version" : 2 } diff --git a/Package.swift b/Package.swift index db088938b..d861c5c65 100644 --- a/Package.swift +++ b/Package.swift @@ -6,7 +6,7 @@ import Foundation let (coreSearchVersion, coreSearchVersionHash) = ("2.6.0", "44c8215e1b0e33b5ea6ce1f2147dd918f2d53a908992f5eed80c4577b36faf00") -let mapboxCommonSDKVersion = Version("24.8.0") +let mapboxCommonSDKVersion = Version("24.9.0-daily-2024-11-13-08-38") let package = Package( name: "MapboxSearch", @@ -50,13 +50,11 @@ let package = Package( .copy("Resources/PrivacyInfo.xcprivacy"), ] ), - coreSearchTarget( name: "MapboxCoreSearch", version: coreSearchVersion, checksum: coreSearchVersionHash ), - .testTarget( name: "MapboxSearchTests", dependencies: [ diff --git a/Sources/MapboxSearch/PublicAPI/SearchOptions.swift b/Sources/MapboxSearch/PublicAPI/SearchOptions.swift index 95cb89858..c1b579213 100644 --- a/Sources/MapboxSearch/PublicAPI/SearchOptions.swift +++ b/Sources/MapboxSearch/PublicAPI/SearchOptions.swift @@ -257,7 +257,7 @@ public struct SearchOptions { route: routeOptions?.route.coordinates.map(Coordinate2D.init(value:)), sarType: routeOptions?.deviation.sarType?.toCore(), timeDeviation: timeDeviation, - addonAPI: unsafeParameters + addonAPI: unsafeParameters, offlineSearchPlacesOutsideBbox: true ) } diff --git a/Tests/MapboxSearchTests/Common/Extensions/LotLan+Extensions.swift b/Tests/MapboxSearchTests/Common/Extensions/LotLan+Extensions.swift index 2e0c3cc05..c25f613a6 100644 --- a/Tests/MapboxSearchTests/Common/Extensions/LotLan+Extensions.swift +++ b/Tests/MapboxSearchTests/Common/Extensions/LotLan+Extensions.swift @@ -10,9 +10,3 @@ extension CoreBoundingBox { } } } - -extension CLLocationCoordinate2D: Equatable { - public static func == (lhs: CLLocationCoordinate2D, rhs: CLLocationCoordinate2D) -> Bool { - return lhs.latitude == rhs.latitude && lhs.longitude == rhs.longitude - } -}