-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Swift 3.1 - rebuild all frameworks, clean up all swift warnings #421
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
Conversation
|
Could you add the .travis.yml changes as well? |
1. Change all explicit calls to .debugDescription over to String(describing:). This preserves existing behavior which was happening implicitly before swift 3.1 2. Use CGFloat.pi instead of CGFloat(Double.pi), and fix an issue where I accidentally negated one of the values in an earlier commit
Loop/Managers/LoopDataManager.swift
Outdated
| updateGroup.enter() | ||
| deviceDataManager.doseStore.getGlucoseEffects(startDate: effectStartDate) { (effects, error) -> Void in | ||
| if let error = error { | ||
| deviceDataManager.doseStore.getGlucoseEffects(start: effectStartDate, end: .distantFuture) { result -> Void in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The changes here, in StatusExtensionDataManager, PredictionTableViewController, and StatusTableViewController don't appear to be related to swift 3.1. Could you put those into a different PR along with a description of what they're addressing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Swift 3.1 now throws warnings for using these deprecated APIs:
/Users/bharat/local/Loop/Loop/View Controllers/StatusTableViewController.swift:209:38: 'getRecentGlucoseValues(startDate:endDate:resultsHandler:)' is deprecated: Use getGlucoseValues(start:end:completionHandler:) instead
|
Since Swift 3.1 throws warnings for the deprecated APIs, I had rolled those up into this PR. But I can see the value in making those API changes separately so let me pull them out into a separate PR. |
Separate them out from the non-API related warning fixes.
We were accidentally getting 1.2.1 because carthage considers it to be compatible when you use the ~> notation.
* refactor of CGM device management * Adding missing files from last cgm refactor pr * Fail if any command in pipeline fails * handling a memory warning and tweaks to the diagnostic report * Fix tests that had been breaking for a while but were hidden by xcpretty swallowing exit code * Show the glucose chart in the widget (#377) Show the glucose chart in the widget. Thanks @bharat! * Swift 3.1 - rebuild all frameworks, clean up all swift warnings (#421) * Rebuild all frameworks with swift 3.1 * Resolve all Swift 3.1 warnings * Swift 3.1 - update LoopKit to 1.2.1 (#423) update LoopKit to 1.2.1 * Swift 3.1 - post widget merge cleanups (#424) * Extend ChartColorPalette in Loop target to add a .default() palette * Update chart appropriately when we remove glucose targets * Drop the first predicted glucose entry. It's the current glucose and its interval to the second is not uniform with the interval for the rest * Use predictedGlucose.startIndex for clarity instead of hardcoding indexes * Swift 3.1 - update dexcom-share-client-swift and G4ShareSpy frameworks (#422) update dexcom-share-client-swift and G4ShareSpy frameworks * Project and margin cleanups (#427) * support share-only cgm source (#426) * fall back to getting cgm data from share if no others are configured * use absence of g5 transmitter to indicate share-only setup. * Widget should always display data using the preferred dispay unit, (#434) regardless of the units used in the StatusExtensionContext. * Break the tie between two visual constraints. (#439) "<NSLayoutConstraint:0x600000097430 LoopUI.ChartContentView:0x7f808c50aae0.height >= 100 (active)>", "<NSLayoutConstraint:0x60000009c2f0 'UISV-hiding' LoopUI.ChartContentView:0x7f808c50aae0.height == 0 (active)>" Lower the priority of the height >= 100 constraint. * bump version (#441)
This PR resolves all swift 3.1 warnings.