Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update nav-native to 9.2.1 #2412

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 25 additions & 7 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,17 +36,26 @@ step-library:
paths:
- "~/.cocoapods/repos/master"

- &prepare
- &prepare-mapbox-file
run:
name: Prepare
name: Prepare .mapbox file
command: |
echo "foo" > ~/.mapbox
brew unlink carthage
brew install carthage --HEAD

- &prepare-netrc-file
run:
name: Prepare .netrc file
command: |
echo "machine dl.bintray.com" > ~/.netrc
echo "login $BINTRAY_LOGIN" >> ~/.netrc
echo "password $BINTRAY_API_KEY" >> ~/.netrc

- &update-carthage-version
run:
name: Update Carthage version
command: |
brew update && brew upgrade carthage

- &verify-missing-localizable-strings
run:
name: Verify missing localizable strings
Expand All @@ -57,7 +66,9 @@ step-library:
- &install-dependencies
run:
name: Install Dependencies
command: carthage bootstrap --platform ios --cache-builds --configuration Debug --no-use-binaries --use-netrc
command: |
carthage bootstrap --platform ios --cache-builds --configuration Debug --no-use-binaries --use-netrc
carthage outdated --xcode-warnings # prints warnings if there are outdated carthage dependencies

- &build-Example
run:
Expand Down Expand Up @@ -86,6 +97,9 @@ jobs:
HOMEBREW_NO_AUTO_UPDATE: 1
steps:
- checkout
- *prepare-mapbox-file
- *prepare-netrc-file
- *update-carthage-version
- *restore-cache-podmaster
- *restore-cache-cocoapods
- when:
Expand Down Expand Up @@ -131,7 +145,9 @@ jobs:
HOMEBREW_NO_AUTO_UPDATE: 1
steps:
- checkout
- *prepare
- *prepare-mapbox-file
- *prepare-netrc-file
- *update-carthage-version
- *restore-cache
- when:
condition: << parameters.delete_private_deps >>
Expand Down Expand Up @@ -168,7 +184,9 @@ jobs:
HOMEBREW_NO_AUTO_UPDATE: 1
steps:
- checkout
- *prepare
- *prepare-mapbox-file
- *prepare-netrc-file
- *update-carthage-version
- *restore-cache
- *install-dependencies
- *build-Example
Expand Down
20 changes: 15 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,35 @@

## master

### MAU Billing
### Packaging

* Enabled MAU billing by default, so that SDKs usage of Mapbox APIs is [billed](https://www.mapbox.com/pricing/) together based on [monthly active users](https://docs.mapbox.com/help/glossary/monthly-active-users/) rather than individually by HTTP request. If you prefer to still use request-based billing, set the `MBXNavigationBillingMethod` key in Info.plist to `request` ([#2405](https://github.com/mapbox/mapbox-navigation-ios/pull/2405).
* Added a Greek localization. ([#2385](https://github.com/mapbox/mapbox-navigation-ios/pull/2385))

### User location

* Fixed issues where the user puck would sometimes drift away from the route line even though the user was following the route. ([#2404](https://github.com/mapbox/mapbox-navigation-ios/pull/2404))
* Fixed an issue where `RouteController` took longer than usual to detect that the user had gone off-route. ([#2404](https://github.com/mapbox/mapbox-navigation-ios/pull/2404))
* Fixed an issue where `RouteController` would detect that the user had gone off-route due to a single errant location update. ([#2404](https://github.com/mapbox/mapbox-navigation-ios/pull/2404))

### Offline navigation

* Fixed a crash that occurred after setting `RouteOptions.shapeFormat` to `RouteShapeFormat.geoJSON`. ([valhalla/valhalla#1867](https://github.com/valhalla/valhalla/pull/1867))
* Fixed an issue where some routes had unreasonably long expected travel times. ([valhalla/valhalla#2102](https://github.com/valhalla/valhalla/pull/2102))
* Fixed incorrect routing at some intersections of divided roads where there are turn restrictions. ([valhalla/valhalla#2109](https://github.com/valhalla/valhalla/pull/2109))
* Fixed issues where routes would sometimes require divebombing. ([valhalla/valhalla#1931](https://github.com/valhalla/valhalla/pull/1931))
* Fixed an issue where the route would sometimes contain duplicate waypoints. ([valhalla/valhalla#1880](https://github.com/valhalla/valhalla/pull/1880))
* Fixed an issue where an exception to a road closure on a public holiday was being ignored. ([valhalla/valhalla#2198](https://github.com/valhalla/valhalla/pull/2198))
* By default, calculated routes follow alleys less often. ([valhalla/valhalla#2231](https://github.com/valhalla/valhalla/pull/2231))
* Turn lane indications are now shown below the turn banner as when navigating online. ([valhalla/valhalla#1830](https://github.com/valhalla/valhalla/pull/1830), [valhalla/valhalla#1859](https://github.com/valhalla/valhalla/pull/1859))
* Fixed an issue where the `RouteStep.expectedTravelTime` properties of each step did not add up to the `RouteLeg.expectedTravelTime` property. ([valhalla/valhalla#2195](https://github.com/valhalla/valhalla/pull/2195))
* Fixed an issue where a forward- or backward-only speed limit was not considered when calculating some expected travel times. ([valhalla/valhalla#2198](https://github.com/valhalla/valhalla/pull/2198))
* Suppressed extraneous fork instructions. ([valhalla/valhalla#1886](https://github.com/valhalla/valhalla/pull/1886), [valhalla/valhalla#1909](https://github.com/valhalla/valhalla/pull/1909), [valhalla/valhalla#1928](https://github.com/valhalla/valhalla/pull/1928))
* Merge instructions now indicate whether to merge to the left or the right, as when navigating online. ([valhalla/valhalla#1892](https://github.com/valhalla/valhalla/pull/1892), [valhalla/valhalla#1989](https://github.com/valhalla/valhalla/pull/1989))
* Fixed ungrammatical spoken instructions at sharp turns in English. ([valhalla/valhalla#2226](https://github.com/valhalla/valhalla/pull/2226))
* Fixed an issue where spoken and visual instructions sometimes omitted the cardinal direction after a route number in the United States. ([valhalla/valhalla#1917](https://github.com/valhalla/valhalla/pull/1917))
* A spoken instruction about an exit ramp no longer specifies the side of the road if the ramp branches off the slow lane (on the right side in regions that drive on the right). ([valhalla/valhalla#1990](https://github.com/valhalla/valhalla/pull/1990))

### Other changes

* Added a Greek localization. ([#2385](https://github.com/mapbox/mapbox-navigation-ios/pull/2385))

## v0.40.0

### Packaging
Expand Down
2 changes: 1 addition & 1 deletion Cartfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
binary "https://www.mapbox.com/ios-sdk/MapboxAccounts.json" ~> 2.3
binary "https://mapbox-gl-native-ios.s3.amazonaws.com/public/internal/Mapbox-iOS-SDK.json" == 5.9.1000
binary "https://www.mapbox.com/ios-sdk/MapboxNavigationNative.json" == 9.0.4
binary "https://www.mapbox.com/ios-sdk/MapboxNavigationNative.json" ~> 9.2.1
github "mapbox/mapbox-directions-swift" ~> 0.32
github "mapbox/turf-swift" ~> 0.5
github "mapbox/mapbox-events-ios" ~> 0.10
Expand Down
2 changes: 1 addition & 1 deletion Cartfile.resolved
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
binary "https://mapbox-gl-native-ios.s3.amazonaws.com/public/internal/Mapbox-iOS-SDK.json" "5.9.1000"
binary "https://www.mapbox.com/ios-sdk/MapboxAccounts.json" "2.3.0"
binary "https://www.mapbox.com/ios-sdk/MapboxNavigationNative.json" "9.0.4"
binary "https://www.mapbox.com/ios-sdk/MapboxNavigationNative.json" "9.2.1"
github "CedarBDD/Cedar" "v1.0"
github "Quick/Nimble" "v8.1.1"
github "Quick/Quick" "v2.2.1"
Expand Down
2 changes: 1 addition & 1 deletion MapboxCoreNavigation.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ Pod::Spec.new do |s|
s.requires_arc = true
s.module_name = "MapboxCoreNavigation"

s.dependency "MapboxNavigationNative", "= 9.0.4"
s.dependency "MapboxNavigationNative", "~> 9.2.1"
s.dependency "MapboxAccounts", "~> 2.3.0"
s.dependency "MapboxDirections", "~> 0.32.0"
s.dependency "MapboxMobileEvents", "~> 0.10.2" # Always pin to a patch release if pre-1.0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import CoreLocation
import Foundation
import MapboxNavigationNative
import CoreLocation

extension FixLocation {
convenience init(_ location: CLLocation) {
Expand All @@ -13,25 +13,3 @@ extension FixLocation {
provider: nil)
}
}

/// :nodoc:
extension MBRouteState: CustomStringConvertible {
public var description: String {
switch self {
case .invalid:
return "invalid"
case .initialized:
return "initialized"
case .tracking:
return "tracking"
case .complete:
return "complete"
case .offRoute:
return "offRoute"
case .stale:
return "stale"
@unknown default:
fatalError("Indescribable route state \(rawValue)")
}
}
}
24 changes: 24 additions & 0 deletions MapboxCoreNavigation/RouteState.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import Foundation
import MapboxNavigationNative

/// :nodoc:
extension RouteState: CustomStringConvertible {
public var description: String {
switch self {
case .invalid:
return "invalid"
case .initialized:
return "initialized"
case .tracking:
return "tracking"
case .complete:
return "complete"
case .offRoute:
return "offRoute"
case .stale:
return "stale"
case .uncertain:
return "uncertain"
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -244,8 +244,7 @@
"${BUILT_PRODUCTS_DIR}/MapboxNavigation/MapboxNavigation.framework",
"${PODS_ROOT}/MapboxNavigationNative/MapboxNavigationNative.framework",
"${PODS_ROOT}/MapboxNavigationNative/MapboxNavigationNative.framework.dSYM",
"${PODS_ROOT}/MapboxNavigationNative/A8E27795-23A6-3C82-9BA8-2C7578AC7E97.bcsymbolmap",
"${PODS_ROOT}/MapboxNavigationNative/FD2B23C2-808F-3297-B5E8-B3D024CB9C70.bcsymbolmap",
"${PODS_ROOT}/MapboxNavigationNative/9E1DC337-5279-3C31-9D5D-D8BA2ECDEB2C.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/MapboxSpeech/MapboxSpeech.framework",
"${BUILT_PRODUCTS_DIR}/Polyline/Polyline.framework",
"${BUILT_PRODUCTS_DIR}/Solar/Solar.framework",
Expand All @@ -266,8 +265,7 @@
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxNavigation.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxNavigationNative.framework",
"${DWARF_DSYM_FOLDER_PATH}/MapboxNavigationNative.framework.dSYM",
"${BUILT_PRODUCTS_DIR}/A8E27795-23A6-3C82-9BA8-2C7578AC7E97.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/FD2B23C2-808F-3297-B5E8-B3D024CB9C70.bcsymbolmap",
"${BUILT_PRODUCTS_DIR}/9E1DC337-5279-3C31-9D5D-D8BA2ECDEB2C.bcsymbolmap",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/MapboxSpeech.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Polyline.framework",
"${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/Solar.framework",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ PODS:
- MapboxAccounts (~> 2.3.0)
- MapboxDirections (~> 0.32.0)
- MapboxMobileEvents (~> 0.10.2)
- MapboxNavigationNative (= 9.0.4)
- MapboxNavigationNative (= 9.2.1)
- Turf (~> 0.5.0)
- MapboxDirections (0.32.0):
- Polyline (~> 4.2)
Expand All @@ -18,7 +18,7 @@ PODS:
- MapboxMobileEvents (~> 0.10.2)
- MapboxSpeech (~> 0.3.0)
- Solar (~> 2.1)
- MapboxNavigationNative (9.0.4)
- MapboxNavigationNative (9.2.1)
- MapboxSpeech (0.3.0)
- Polyline (4.2.1)
- Solar (2.1.0)
Expand Down Expand Up @@ -49,11 +49,11 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
Mapbox-iOS-SDK: a5915700ec84bc1a7f8b3e746d474789e35b7956
MapboxAccounts: 84abfdde95d9dc483f604c1b0fe1861edf691ce7
MapboxCoreNavigation: ddd42a0c92935d7d6090fdccd63fc8c84e5dbf8b
MapboxCoreNavigation: 3aab7ff9c1d56f0da6c2f8656162e90e918ba281
MapboxDirections: 7f36b3e9ef6a53fc997c114a341ab4da721756bd
MapboxMobileEvents: 2bc0ca2eedb627b73cf403258dce2b2fa98074a6
MapboxNavigation: 42bae50b0381dce317c85884ba0de38fc68a4814
MapboxNavigationNative: 50436c659f40d7f67ed8a60652c9d344f0e10e27
MapboxNavigationNative: 97104806edeb30c77f96f81a255999a4d52f5451
MapboxSpeech: 403415e932e084cf290b9d55c49ab7ea210b9595
Polyline: 0e9890790292741c8186201a536b6bb6a78d02dd
Solar: 2dc6e7cc39186cb0c8228fa08df76fb50c7d8f24
Expand Down
15 changes: 15 additions & 0 deletions MapboxCoreNavigationTests/Extensions/RouteStateTests.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import XCTest
@testable import MapboxNavigationNative
@testable import MapboxCoreNavigation

class RouteStateTests: XCTestCase {
func testDescriptionPropertyReturnsExpectedValue() {
XCTAssertEqual(RouteState.invalid.description, "invalid")
XCTAssertEqual(RouteState.initialized.description, "initialized")
XCTAssertEqual(RouteState.tracking.description, "tracking")
XCTAssertEqual(RouteState.complete.description, "complete")
XCTAssertEqual(RouteState.offRoute.description, "offRoute")
XCTAssertEqual(RouteState.stale.description, "stale")
XCTAssertEqual(RouteState.uncertain.description, "uncertain")
}
}
26 changes: 0 additions & 26 deletions MapboxCoreNavigationTests/NavigationServiceTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -483,32 +483,6 @@ class NavigationServiceTests: XCTestCase {
waitForExpectations(timeout: 10)
}

func testNineLeggedRouteForOutOfBounds() {
let options = NavigationRouteOptions(coordinates: [
CLLocationCoordinate2D(latitude: 46.423728, longitude: 13.593578),
CLLocationCoordinate2D(latitude: 46.339747, longitude: 13.574151),
CLLocationCoordinate2D(latitude: 46.34447, longitude: 13.57594),
CLLocationCoordinate2D(latitude: 46.37798, longitude: 13.58583),
CLLocationCoordinate2D(latitude: 46.408308, longitude: 13.605585),
CLLocationCoordinate2D(latitude: 46.420338, longitude: 13.602128),
CLLocationCoordinate2D(latitude: 46.429376, longitude: 13.614679),
CLLocationCoordinate2D(latitude: 46.435762, longitude: 13.626714),
CLLocationCoordinate2D(latitude: 46.436658, longitude: 13.639499),
CLLocationCoordinate2D(latitude: 46.43878, longitude: 13.64052),
])
let route = Fixture.route(from: "9-legged-route", options: options)
let directions = Directions(credentials: Fixture.credentials)
let locationManager = DummyLocationManager()
let trace = Fixture.generateTrace(for: route, speedMultiplier: 4).shiftedToPresent()

let service = MapboxNavigationService(route: route, routeOptions: options, directions: directions, locationSource: locationManager, eventsManagerType: nil)
service.start()

for location in trace {
service.locationManager(locationManager, didUpdateLocations: [location])
}
}

func testUnimplementedLogging() {
unimplementedTestLogs = []

Expand Down
Loading