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 for new SQLKit and support more URL string formats #325

Merged
merged 18 commits into from
Apr 29, 2024

Conversation

gwynne
Copy link
Member

@gwynne gwynne commented Apr 28, 2024

These changes are now available in 4.8.0

Adds support for several additional mysql: URL formats, following in the footsteps of similar support in PostgresKit. Also takes advantage of the recent updates to SQLKit, bumps minimum Swift version to 5.8, and does some general cleanup.

Details on new URL formats can be found in the MySQLKit API documentation.

@gwynne gwynne added enhancement New feature or request semver-minor Contains new APIs labels Apr 28, 2024
@gwynne gwynne requested review from 0xTim, MahdiBM and ptoffy April 28, 2024 09:27
Copy link

codecov bot commented Apr 28, 2024

Codecov Report

Attention: Patch coverage is 61.95652% with 70 lines in your changes are missing coverage. Please review.

Project coverage is 66.04%. Comparing base (a9375f8) to head (452f20f).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #325      +/-   ##
==========================================
+ Coverage   60.85%   66.04%   +5.18%     
==========================================
  Files           8        9       +1     
  Lines         281      321      +40     
==========================================
+ Hits          171      212      +41     
+ Misses        110      109       -1     
Files Coverage Δ
Sources/MySQLKit/MySQLConnectionSource.swift 94.44% <100.00%> (ø)
Sources/MySQLKit/MySQLRow+SQL.swift 85.71% <100.00%> (ø)
Sources/MySQLKit/MySQLDialect.swift 67.79% <83.33%> (-0.54%) ⬇️
Sources/MySQLKit/ConnectionPool+MySQL.swift 27.77% <33.33%> (ø)
Sources/MySQLKit/MySQLDataDecoder.swift 68.57% <68.42%> (+9.87%) ⬆️
Sources/MySQLKit/MySQLDatabase+SQL.swift 74.07% <73.91%> (-9.26%) ⬇️
...urces/MySQLKit/Optional+MySQLDataConvertible.swift 22.22% <22.22%> (ø)
Sources/MySQLKit/MySQLConfiguration.swift 79.22% <81.66%> (+53.73%) ⬆️
Sources/MySQLKit/MySQLDataEncoder.swift 48.43% <38.88%> (-24.78%) ⬇️

Copy link

@MahdiBM MahdiBM left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I definitely didn't totally understand what's going on with every single change but looks good anyway 🫣

let json: JSONDecoder

/// The `JSONDecoder` used for decoding values that can't be directly converted.
let json: FakeSendable<JSONDecoder>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could just @preconcurrency import Foundation on Linux instead

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That triggers a whole different mess of warnings, since Sendability on macOS isn't available before macOS 13.0. This is actually much easier.

@gwynne gwynne merged commit 395a6ea into main Apr 29, 2024
25 checks passed
@gwynne gwynne deleted the update-for-new-sqlkit branch April 29, 2024 12:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request semver-minor Contains new APIs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants