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

Hi,I'm having some problems #1

Open
yunhouhuang opened this issue Dec 17, 2023 · 3 comments
Open

Hi,I'm having some problems #1

yunhouhuang opened this issue Dec 17, 2023 · 3 comments

Comments

@yunhouhuang
Copy link

iOS17.02
XCode15.1

When running the app:

Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[NSMutableOrderedSet addObject:]: object cannot be nil'

@R3-da
Copy link

R3-da commented Oct 12, 2024

IOS 17.2
Xcode 15.2

same here i got the same problem, did you find any solution ?
image

@yunhouhuang
Copy link
Author

oh, It's been a long time, and I'm now successful with ios18.

@R3-da
Copy link

R3-da commented Oct 14, 2024

just tested it with ios 18.0 and it's working like a charm thanks !

i found the root of the issue with ios 17.2 though

i had to:

  • change the MapPitchButton() on mapControls to MapPitchToggle()
  • comment out the following line for it to launch successfully on the simulator, but obviously didn't work as expected ( the "You are here" location marker is not showing )

// draw route from driver to pick up
if let route = vm.routeDriverToPickup {
MapPolyline(route)
.stroke(LinearGradient.gradientWalk, style: .strokeWalk)
}
// draw route from pick up to drop off
if let route = vm.routePickupToDropOff {
MapPolyline(route)
.stroke(.orange, lineWidth: 5)
}
// find my location. Here is demo
ForEach(vm.myLocation, id: \.self){ result in
Annotation(selectedPickupItem == nil ? "You are here" : "Pickup Point", coordinate: result.placemark.coordinate) {
pickupView
.onAppear{
updateCameraPosition(focus: .locU, distance: 992, heading: 70, pitch: 60)
}
}
.annotationTitles(.automatic)
}

down belown are the changes that i made to the NewMapView.swift file

https://github.com/R3-da/PackageDeliverySwiftUI/blob/930b25a2a50e755afd0fba356deade34ae114890/PackageDeliverySwiftUI/Core/Views/Map/Views/NewMapView.swift#L77-L99

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants