Skip to content

Commit

Permalink
Bump libsqlite3-sys to 0.28
Browse files Browse the repository at this point in the history
  • Loading branch information
weiznich committed Mar 14, 2024
1 parent 9117d29 commit 151d32e
Show file tree
Hide file tree
Showing 8 changed files with 43 additions and 42 deletions.
71 changes: 36 additions & 35 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Increasing the minimal supported Rust version will always be coupled at least wi
* Fix an inconsistent unit test
* Fix a clippy lint
* Fix ./bin/test feature flag calls.
* Update `libsqlite3-sys` to allow version 0.28 as well

## [2.1.4] 2023-11-14

Expand Down Expand Up @@ -59,6 +60,8 @@ Increasing the minimal supported Rust version will always be coupled at least wi

### Added

* Added `serialize_database_to_buffer` and `deserialize_readonly_database_from_buffer` methods in `SqliteConnection` to support serialization/deserialization of SQLite databases to and from byte buffers.
* Added `SerializedDatabase` wrapper type for a serialized database that is dynamically allocated by calling `serialize_database_to_buffer`. This RAII wrapper deallocates the memory when it goes out of scope with `sqlite3_free`.
* Added the `custom_type_derives` config option to customize the derives for SQL
type definitions automatically generated by Diesel CLI.
* Add a `#[derive(MultiConnection)]` proc-macro that lets you easily implement `diesel::Connection`
Expand All @@ -73,7 +76,7 @@ Increasing the minimal supported Rust version will always be coupled at least wi

## [2.0.4] 2023-04-18

## Fixed
## Fixed

* Workaround the missing name resolution in rust-analyzer. This should fix type inference for some diesel queries. (It remains broken for queries containing `.filter()`/`.inner_join()`/`.left_join()`. These require fixes in rust-analyzer itself)
* Fixed a bug that could lead to inserting null values instead of empty values for custom sqlite types
Expand All @@ -84,9 +87,9 @@ Increasing the minimal supported Rust version will always be coupled at least wi

* Support for `libsqlite3-sys` 0.26

## [diesel_derives 2.0.2] 2023-03-13
## [diesel_derives 2.0.2] 2023-03-13

## Fixed
## Fixed

* Fixing the fallout of a breaking change from `quote` by not using their internal API

Expand Down Expand Up @@ -155,7 +158,7 @@ Increasing the minimal supported Rust version will always be coupled at least wi
in such a way to support constructing a dynamic value depending on this type.

* Added a `without-deprecated` feature that unconditionally disables deprecated items.
Use this feature flag to verify that none of your dependencies is setting
Use this feature flag to verify that none of your dependencies is setting
the `with-deprecated` flag internally.

* Added support for PostgreSQL's `SIMILAR TO` and `NOT SIMILAR TO`.
Expand All @@ -179,7 +182,7 @@ Increasing the minimal supported Rust version will always be coupled at least wi

* Diesel CLI will now generate SQL type definitions for SQL types that are not supported by diesel out of the box. It's possible to disable this behavior via the `generate_missing_sql_type_definitions` config option.

* Added an option to `#[derive(Insertable)]` that let you insert `NULL` values instead of `DEFAULT` values for `Option<T>`
* Added an option to `#[derive(Insertable)]` that let you insert `NULL` values instead of `DEFAULT` values for `Option<T>`

* Added support for all the derive attributes being inside `#[diesel(...)]`

Expand Down Expand Up @@ -284,12 +287,12 @@ Increasing the minimal supported Rust version will always be coupled at least wi
card implementations for types implementing `Queryable<ST, DB>` or `QueryableByName<DB>`
so non generic code does not require any change. For generic code you likely need to
replace a trait bound on `Queryable<ST, DB>` with a trait bound on `FromSqlRow<ST, DB>`
and a bound to `QueryableByName<DB>` with `FromSqlRow<Untyped, DB>`.
and a bound to `QueryableByName<DB>` with `FromSqlRow<Untyped, DB>`.

* CLI flags of `only-tables` and `except-tables` are now interpreted as regular expressions.
Similarly, `only_tabels` and `except_tables` in `diesel.toml` are treated as regular expressions.
Similarly, `only_tables` and `except_tables` in `diesel.toml` are treated as regular expressions.

* Now you can sort column fields by name with the `column-sorting` option.
* Now you can sort column fields by name with the `column-sorting` option.
It can be set to either `ordinal_position` (default) or `name`.
This ensures stable sorting even if columns are removed and re-added.

Expand All @@ -302,25 +305,25 @@ Increasing the minimal supported Rust version will always be coupled at least wi

* `TypeMetadata::MetadataLookup` is now `?Sized`.

* Multiple implementations of `Connection<Backend=Pg>` are now possible
* Multiple implementations of `Connection<Backend=Pg>` are now possible
because of the new `PgMetadataLookup` trait.

* For the `Pg` backend, `TypeMetadata::MetadataLookup` has changed to `dyn PgMetadataLookup`.

* Diesel's migration framework was rewritten from the ground. Existing migrations continue to
* Diesel's migration framework was rewritten from the ground. Existing migrations continue to
be compatible with the rewrite, but code calling into `diesel_migrations` requires an update.
See the [migration guide](2-0-migration) for details.

* `eq_any()` now emits a `= ANY()` expression for the postgresql backend instead of `IN()`
* `ne_all()` now emits a `!= ALL()` expression for the postgresql backend instead of `NOT IN()`
* The sqlite backend now uses a single batch insert statement if there are now default values present
* The sqlite backend now uses a single batch insert statement if there are now default values present
in the values clause

* The MySQL connection is using the CLIENT_FOUND_ROWS from now on. This means that updating rows without changing any values will return the number of matched rows (like most other SQL servers do), as opposed to the number of changed rows.

* The definition of `ToSql::to_sql` and `QueryFragment::walk_ast` has changed to allow serializing values without
* The definition of `ToSql::to_sql` and `QueryFragment::walk_ast` has changed to allow serializing values without
copying the value itself. This is useful for database backends like sqlite where you can directly share a buffer
with the database. Beside of the changed signature, existing impls of this trait should remain unchanged in almost
with the database. Beside of the changed signature, existing impls of this trait should remain unchanged in almost
all cases.

* The `PIPES_AS_CONCAT` sql_mode is no longer set
Expand Down Expand Up @@ -367,14 +370,14 @@ queries or set `PIPES_AS_CONCAT` manually.
* We've refactored our type level representation of nullable values. This allowed us to
fix multiple long standing bugs regarding the correct handling of nullable values in some
corner cases (#104, #2274)

* Parenthesis are now inserted around all infix operations provided by diesel's `ExpressionMethods` traits

* Queries containing a `distinct on` clause check now on compile time that a compatible order clause was set.

* Implementations of custom SQLite SQL functions now check for panics

* `diesel print-schema` now generates `Array<Nullable<ST>>` rather than `Array<ST>` for Postgres Array types. Existence of
* `diesel print-schema` now generates `Array<Nullable<ST>>` rather than `Array<ST>` for Postgres Array types. Existence of
`NULL` values in database arrays would previously result in deserialization errors. Non-nullable arrays are now opt
in (by schema patching).

Expand All @@ -388,10 +391,11 @@ queries or set `PIPES_AS_CONCAT` manually.

* `diesel::pg::upsert` has been deprecated to support upsert queries on more than one backend.
Please use `diesel::upsert` instead.

* `diesel::dsl::any` and `diesel::dsl::all` are now deprecated in
* `diesel::dsl::any` and `diesel::dsl::all` are now deprecated in
favour of `ExpressionMethods::eq_any()` and `ExpressionMethods::ne_all()`


[2-0-migration]: https://github.com/diesel-rs/diesel/blob/master/guide_drafts/migration_guide.md

## [1.4.8] - 2021-09-20
Expand Down Expand Up @@ -443,6 +447,7 @@ queries or set `PIPES_AS_CONCAT` manually.
* Fixed issue where rustdoc failed to build the documentation
* `diesel_derives` and `diesel_migrations` are updated to syn 1.0


## [1.4.2] - 2019-03-19

### Fixed
Expand Down Expand Up @@ -1569,7 +1574,7 @@ queries or set `PIPES_AS_CONCAT` manually.
* Added partial support for composite primary keys.

* Added support for PostgreSQL `NULLS FIRST` and `NULLS LAST` when sorting.
See <https://docs.diesel.rs/diesel/prelude/trait.SortExpressionMethods.html>
See https://docs.diesel.rs/diesel/prelude/trait.SortExpressionMethods.html
for details.

* Added support for the `timestamp with time zone` type in PostgreSQL (referred
Expand Down Expand Up @@ -1639,22 +1644,22 @@ queries or set `PIPES_AS_CONCAT` manually.

* The `Insertable!` macro can now be used instead of `#[insertable_into]` for
those wishing to avoid syntax extensions from `diesel_codegen`. See
<https://docs.diesel.rs/diesel/macro.Insertable!.html> for details.
https://docs.diesel.rs/diesel/macro.Insertable!.html for details.

* The `Queryable!` macro can now be used instead of `#[derive(Queryable)]` for
those wishing to avoid syntax extensions from `diesel_codegen`. See
<https://docs.diesel.rs/diesel/macro.Queryable!.html> for details.
https://docs.diesel.rs/diesel/macro.Queryable!.html for details.

* The `Identifiable!` macro can now be used instead of `#[derive(Identifiable)]` for
those wishing to avoid syntax extensions from `diesel_codegen`. See
<https://docs.diesel.rs/diesel/macro.Identifiable!.html> for details.
https://docs.diesel.rs/diesel/macro.Identifiable!.html for details.

* The `AsChangeset!` macro can now be used instead of `#[changeset_for(table)]`
for those wishing to avoid syntax extensions from `diesel_codegen`. See
<https://docs.diesel.rs/diesel/macro.AsChangeset!.html> for details.
https://docs.diesel.rs/diesel/macro.AsChangeset!.html for details.

* Added support for the PostgreSQL `ALL` operator. See
<https://docs.diesel.rs/diesel/pg/expression/dsl/fn.all.html> for details.
https://docs.diesel.rs/diesel/pg/expression/dsl/fn.all.html for details.

* Added support for `RETURNING` expressions in `DELETE` statements. Implicitly
these queries will use `RETURNING *`.
Expand All @@ -1681,8 +1686,8 @@ queries or set `PIPES_AS_CONCAT` manually.
`#[column_name(name)]`.

* The structure of `DatabaseError` has changed to hold more information. See
<https://docs.diesel.rs/diesel/result/enum.Error.html> and
<https://docs.diesel.rs/diesel/result/trait.DatabaseErrorInformation.html> for
https://docs.diesel.rs/diesel/result/enum.Error.html and
https://docs.diesel.rs/diesel/result/trait.DatabaseErrorInformation.html for
more information

* Structs which implement `Identifiable` can now be passed to `update` and
Expand Down Expand Up @@ -2057,14 +2062,10 @@ queries or set `PIPES_AS_CONCAT` manually.
[1.4.8]: https://github.com/diesel-rs/diesel/compare/v1.4.7...v1.4.8
[2.0.0 Rc0]: https://github.com/diesel-rs/diesel/compare/v.1.4.0...v2.0.0-rc0
[2.0.0 Rc1]: https://github.com/diesel-rs/diesel/compare/v.2.0.0-rc0...v2.0.0-rc1
[2.0.0]: https://github.com/diesel-rs/diesel/compare/v1.4.0...v2.0.0
[2.0.1]: https://github.com/diesel-rs/diesel/compare/v2.0.0...v2.0.1
[2.0.2]: https://github.com/diesel-rs/diesel/compare/v2.0.1...v2.0.2
[2.0.0]: https://github.com/diesel-rs/diesel/compare/v.1.4.0...v2.0.0
[2.0.1]: https://github.com/diesel-rs/diesel/compare/v.2.0.0...v2.0.1
[2.0.2]: https://github.com/diesel-rs/diesel/compare/v.2.0.1...v2.0.2
[diesel_derives 2.0.2]: https://github.com/diesel-rs/diesel/compare/v.2.0.2...diesel_derives_v2.0.2
[2.0.3]: https://github.com/diesel-rs/diesel/compare/v2.0.2...v2.0.3
[2.0.4]: https://github.com/diesel-rs/diesel/compare/v2.0.3...v2.0.4
[2.1.0]: https://github.com/diesel-rs/diesel/compare/v2.0.0...v2.1.0
[2.1.1]: https://github.com/diesel-rs/diesel/compare/v2.1.0...v2.1.1
[2.1.2]: https://github.com/diesel-rs/diesel/compare/v2.1.1...v2.1.2
[2.1.3]: https://github.com/diesel-rs/diesel/compare/v2.1.2...v2.1.3
[2.1.4]: https://github.com/diesel-rs/diesel/compare/v2.1.3...v2.1.4
[2.0.3]: https://github.com/diesel-rs/diesel/compare/v.2.0.2...v2.0.3
[2.0.4]: https://github.com/diesel-rs/diesel/compare/v.2.0.3...v2.0.4
[2.1.0]: https://github.com/diesel-rs/diesel/compare/v.2.0.0...v2.1.0
2 changes: 1 addition & 1 deletion diesel/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ rust-version = "1.65.0"
byteorder = { version = "1.0", optional = true }
chrono = { version = "0.4.20", optional = true, default-features = false, features = ["clock", "std"] }
libc = { version = "0.2.0", optional = true }
libsqlite3-sys = { version = ">=0.17.2, <0.28.0", optional = true, features = ["bundled_bindings"] }
libsqlite3-sys = { version = ">=0.17.2, <0.29.0", optional = true, features = ["bundled_bindings"] }
mysqlclient-sys = { version = "0.2.5", optional = true }
pq-sys = { version = "0.4.0", optional = true }
quickcheck = { version = "1.0.3", optional = true }
Expand Down
2 changes: 1 addition & 1 deletion diesel_cli/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ heck = "0.4.0"
serde = { version = "1.0.0", features = ["derive"] }
toml = "0.7"
url = { version = "2.2.2" }
libsqlite3-sys = { version = ">=0.17.2, <0.28.0", optional = true }
libsqlite3-sys = { version = ">=0.17.2, <0.29.0", optional = true }
diffy = "0.3.0"
regex = "1.0.6"
serde_regex = "1.1"
Expand Down
2 changes: 1 addition & 1 deletion diesel_tests/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ ipnet = { version = "2.5.0" }
ipnetwork = ">=0.12.2, <0.21.0"
bigdecimal = ">= 0.0.13, < 0.5.0"
rand = "0.8.4"
libsqlite3-sys = { version = "0.27", optional = true }
libsqlite3-sys = { version = "0.28", optional = true }

[features]
default = []
Expand Down
2 changes: 1 addition & 1 deletion examples/sqlite/all_about_inserts/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ diesel = { version = "2.1.0", path = "../../../diesel", features = ["sqlite", "c
serde = { version = "1.0.130", features = ["derive"] }
serde_json = "1.0.68"
chrono = { version = "0.4.20", default-features = false, features = ["clock", "std"] }
libsqlite3-sys = { version = "0.27.0", features = ["bundled"] }
libsqlite3-sys = { version = "0.28.0", features = ["bundled"] }

[lib]
doc = false
2 changes: 1 addition & 1 deletion examples/sqlite/getting_started_step_1/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ publish = false
[dependencies]
diesel = { version = "2.1.0", path = "../../../diesel", features = ["sqlite"] }
dotenvy = "0.15"
libsqlite3-sys = { version = "0.27.0", features = ["bundled"] }
libsqlite3-sys = { version = "0.28.0", features = ["bundled"] }

[[bin]]
name = "show_posts"
Expand Down
2 changes: 1 addition & 1 deletion examples/sqlite/getting_started_step_2/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ publish = false
[dependencies]
diesel = { version = "2.1.0", path = "../../../diesel", features = ["sqlite", "returning_clauses_for_sqlite_3_35"] }
dotenvy = "0.15"
libsqlite3-sys = { version = "0.27.0", features = ["bundled"] }
libsqlite3-sys = { version = "0.28.0", features = ["bundled"] }

[[bin]]
name = "show_posts"
Expand Down
2 changes: 1 addition & 1 deletion examples/sqlite/getting_started_step_3/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ publish = false
[dependencies]
diesel = { version = "2.1.0", path = "../../../diesel", features = ["sqlite", "returning_clauses_for_sqlite_3_35"] }
dotenvy = "0.15"
libsqlite3-sys = { version = "0.27.0", features = ["bundled"] }
libsqlite3-sys = { version = "0.28.0", features = ["bundled"] }

[[bin]]
name = "show_posts"
Expand Down

0 comments on commit 151d32e

Please sign in to comment.