Changelog History
Page 2
-
v0.7.1 Changes
March 26, 2022- 🛠 Fix sea-orm-cli error
- 🛠 Fix sea-orm cannot build without
with-json
-
v0.7.0 Changes
March 26, 2022🆕 New Features
- ⚡️ Update ActiveModel by JSON by @billy1624 in https://github.com/SeaQL/sea-orm/pull/492
- 👌 Supports
time
crate by @billy1624 https://github.com/SeaQL/sea-orm/pull/602 - 👍 Allow for creation of indexes for PostgreSQL and SQLite @nickb937 https://github.com/SeaQL/sea-orm/pull/593
- Added
delete_by_id
@ShouvikGhosh2048 https://github.com/SeaQL/sea-orm/pull/590 - Implement
PaginatorTrait
forSelectorRaw
@shinbunbun https://github.com/SeaQL/sea-orm/pull/617
✨ Enhancements
- ➕ Added axum graphql example by @aaronleopold in https://github.com/SeaQL/sea-orm/pull/587
- ➕ Add example for integrate with jsonrpsee by @hunjixin https://github.com/SeaQL/sea-orm/pull/632
- Codegen add serde derives to enums, if specified by @BenJeau https://github.com/SeaQL/sea-orm/pull/463
- Codegen Unsigned Integer by @billy1624 https://github.com/SeaQL/sea-orm/pull/397
- ➕ Add
Send
bound toQueryStream
andTransactionStream
by @sebpuetz https://github.com/SeaQL/sea-orm/pull/471 - ➕ Add
Send
toStreamTrait
by @nappa85 https://github.com/SeaQL/sea-orm/pull/622 sea
as an alternative bin name tosea-orm-cli
by @ZhangHanDong https://github.com/SeaQL/sea-orm/pull/558
🐛 Bug Fixes
- 🛠 Fix codegen with Enum in expanded format by @billy1624 https://github.com/SeaQL/sea-orm/pull/624
- 🛠 Fixing and testing into_json of various field types by @billy1624 https://github.com/SeaQL/sea-orm/pull/539
💥 Breaking changes
- 🤡 Exclude
mock
from default features by @billy1624 https://github.com/SeaQL/sea-orm/pull/562 create_table_from_entity
will no longer create index for MySQL, please use the new methodcreate_index_from_entity
📚 Documentations
- 0️⃣ Describe default value of ActiveValue on document by @Ken-Miura in https://github.com/SeaQL/sea-orm/pull/556
- community: add axum-book-management by @lz1998 in https://github.com/SeaQL/sea-orm/pull/564
- ➕ Add Backpack to project showcase by @JSH32 in https://github.com/SeaQL/sea-orm/pull/567
- ➕ Add mediarepo to showcase by @Trivernis in https://github.com/SeaQL/sea-orm/pull/569
- COMMUNITY: add a link to Svix to showcase by @tasn in https://github.com/SeaQL/sea-orm/pull/537
- ⚡️ Update COMMUNITY.md by @naryand in https://github.com/SeaQL/sea-orm/pull/570
- ⚡️ Update COMMUNITY.md by @BobAnkh in https://github.com/SeaQL/sea-orm/pull/568
- ⚡️ Update COMMUNITY.md by @KaniyaSimeji in https://github.com/SeaQL/sea-orm/pull/566
- ⚡️ Update COMMUNITY.md by @aaronleopold in https://github.com/SeaQL/sea-orm/pull/565
- ⚡️ Update COMMUNITY.md by @gudaoxuri in https://github.com/SeaQL/sea-orm/pull/572
- ⚡️ Update Wikijump's entry in COMMUNITY.md by @ammongit in https://github.com/SeaQL/sea-orm/pull/573
- ⚡️ Update COMMUNITY.md by @koopa1338 in https://github.com/SeaQL/sea-orm/pull/574
- ⚡️ Update COMMUNITY.md by @gengteng in https://github.com/SeaQL/sea-orm/pull/580
- ⚡️ Update COMMUNITY.md by @Yama-Tomo in https://github.com/SeaQL/sea-orm/pull/582
- ➕ add oura-postgres-sink to COMMUNITY.md by @rvcas in https://github.com/SeaQL/sea-orm/pull/594
- ➕ Add rust-example-caster-api to COMMUNITY.md by @bkonkle in https://github.com/SeaQL/sea-orm/pull/623
🛠 Fixed Issues
- orm-cli generated incorrect type for #[sea_orm(primary_key)]. Should be u64. Was i64. https://github.com/SeaQL/sea-orm/issues/295
- ⚡️ how to update dynamically from json value https://github.com/SeaQL/sea-orm/issues/346
- 0️⃣ Make
DatabaseConnection
Clone
with the default features enabled https://github.com/SeaQL/sea-orm/issues/438 - ⚡️ Updating multiple fields in a Model by passing a reference https://github.com/SeaQL/sea-orm/issues/460
- SeaORM CLI not adding serde derives to Enums https://github.com/SeaQL/sea-orm/issues/461
- sea-orm-cli generates wrong data type for nullable blob https://github.com/SeaQL/sea-orm/issues/490
- 👌 Support the time crate in addition (instead of?) chrono https://github.com/SeaQL/sea-orm/issues/499
- PaginatorTrait for SelectorRaw https://github.com/SeaQL/sea-orm/issues/500
- 0️⃣ sea_orm::DatabaseConnection should implement
Clone
by default https://github.com/SeaQL/sea-orm/issues/517 - 👀 How do you seed data in migrations using ActiveModels? https://github.com/SeaQL/sea-orm/issues/522
- Datetime fields are not serialized by
.into_json()
on queries https://github.com/SeaQL/sea-orm/issues/530 - ⚡️ Update / Delete by id https://github.com/SeaQL/sea-orm/issues/552
#[sea_orm(indexed)]
only works for MySQL https://github.com/SeaQL/sea-orm/issues/554sea-orm-cli generate --with-serde
does not work on Postgresql custom type https://github.com/SeaQL/sea-orm/issues/581sea-orm-cli generate --expanded-format
panic when postgres table contains enum type https://github.com/SeaQL/sea-orm/issues/614- UUID fields are not serialized by
.into_json()
on queries https://github.com/SeaQL/sea-orm/issues/619
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.6.0...0.7.0
-
v0.6.0 Changes
February 07, 2022🆕 New Features
- 👍 Migration Support by @billy1624 in https://github.com/SeaQL/sea-orm/pull/335
- 👌 Support
DateTime<Utc>
&DateTime<Local>
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/489 - ➕ Add
max_lifetime
connection option by @billy1624 in https://github.com/SeaQL/sea-orm/pull/493
✨ Enhancements
- Model with Generics by @billy1624 in https://github.com/SeaQL/sea-orm/pull/400
- ➕ Add Poem example by @sunli829 in https://github.com/SeaQL/sea-orm/pull/446
- Codegen
column_name
proc_macro attribute by @billy1624 in https://github.com/SeaQL/sea-orm/pull/433 - 🤡 Easy joins with MockDatabase #447 by @cemoktra in https://github.com/SeaQL/sea-orm/pull/455
🐛 Bug Fixes
- CLI allow generate entity with url without password by @billy1624 in https://github.com/SeaQL/sea-orm/pull/436
- 👌 Support up to 6-ary composite primary key by @billy1624 in https://github.com/SeaQL/sea-orm/pull/423
- 🛠 Fix FromQueryResult when Result is redefined by @tasn in https://github.com/SeaQL/sea-orm/pull/495
- ✂ Remove
r#
prefix when derivingFromQueryResult
by @smrtrfszm in https://github.com/SeaQL/sea-orm/pull/494
💥 Breaking Changes
- Name conflict of foreign key constraints when two entities have more than one foreign keys by @billy1624 in https://github.com/SeaQL/sea-orm/pull/417
🛠 Fixed Issues
- Is it possible to have 4 values Composite Key? https://github.com/SeaQL/sea-orm/issues/352
- 👌 Support
DateTime<Utc>
&DateTime<Local>
https://github.com/SeaQL/sea-orm/issues/381 - Codegen
column_name
proc_macro attribute if column name isn't in snake case https://github.com/SeaQL/sea-orm/issues/395 - Model with Generics https://github.com/SeaQL/sea-orm/issues/402
- Foreign key constraint collision when multiple keys exist between the same two tables https://github.com/SeaQL/sea-orm/issues/405
- sea-orm-cli passwordless database user causes "No password was found in the database url" error https://github.com/SeaQL/sea-orm/issues/435
- ✅ Testing joins with MockDatabase https://github.com/SeaQL/sea-orm/issues/447
- Surface max_lifetime connection option https://github.com/SeaQL/sea-orm/issues/475
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.5.0...0.6.0
-
v0.5.0 Changes
January 01, 2022🛠 Fixed Issues
- ⚡️ Why insert, update, etc return an ActiveModel instead of Model? https://github.com/SeaQL/sea-orm/issues/289
- Rework
ActiveValue
https://github.com/SeaQL/sea-orm/issues/321 - Some missing ActiveEnum utilities https://github.com/SeaQL/sea-orm/issues/338
🔀 Merged PRs
- First metric and tracing implementation by @nappa85 in https://github.com/SeaQL/sea-orm/pull/373
- ⚡️ Update sea-orm to depends on SeaQL/sea-query#202 by @billy1624 in https://github.com/SeaQL/sea-orm/pull/370
- Codegen ActiveEnum & Create Enum From ActiveEnum by @billy1624 in https://github.com/SeaQL/sea-orm/pull/348
- ⚡️ Axum example: update to Axum v0.4.2 by @ttys3 in https://github.com/SeaQL/sea-orm/pull/383
- 🛠 Fix rocket version by @Gabriel-Paulucci in https://github.com/SeaQL/sea-orm/pull/384
- ⚡️ Insert & Update Return
Model
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/339 - Rework
ActiveValue
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/340 - ➕ Add wrapper method
ModelTrait::delete
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/396 - ➕ Add docker create script for contributors to setup databases locally by @billy1624 in https://github.com/SeaQL/sea-orm/pull/378
- 🌲 Log with tracing-subscriber by @billy1624 in https://github.com/SeaQL/sea-orm/pull/399
- Codegen SQLite by @billy1624 in https://github.com/SeaQL/sea-orm/pull/386
- ⚠ PR without clippy warnings in file changed tab by @billy1624 in https://github.com/SeaQL/sea-orm/pull/401
- 📇 Rename
sea-strum
lib back tostrum
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/361
💥 Breaking Changes
- ⚡️
ActiveModel::insert
andActiveModel::update
returnModel
instead ofActiveModel
- Method
ActiveModelBehavior::after_save
takesModel
as input instead ofActiveModel
- Rename method
sea_orm::unchanged_active_value_not_intended_for_public_use
tosea_orm::Unchanged
- 📇 Rename method
ActiveValue::unset
toActiveValue::not_set
- Rename method
ActiveValue::is_unset
toActiveValue::is_not_set
PartialEq
ofActiveValue
will also check the equality of state instead of just checking the equality of value
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.4.2...0.5.0
-
v0.5.0-rc.1 Changes
December 25, 2021🛠 Fixed Issues
(Please help fill in)
🔀 Merged PRs
- First metric and tracing implementation by @nappa85 in https://github.com/SeaQL/sea-orm/pull/373
- ⚡️ Update sea-orm to depends on SeaQL/sea-query#202 by @billy1624 in https://github.com/SeaQL/sea-orm/pull/370
- Codegen ActiveEnum & Create Enum From ActiveEnum by @billy1624 in https://github.com/SeaQL/sea-orm/pull/348
- ⚡️ Axum example: update to Axum v0.4.2 by @ttys3 in https://github.com/SeaQL/sea-orm/pull/383
- 🛠 Fix rocket version by @Gabriel-Paulucci in https://github.com/SeaQL/sea-orm/pull/384
- ⚡️ Insert & Update Return
Model
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/339 - Rework
ActiveValue
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/340 - ➕ Add wrapper method
ModelTrait::delete
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/396 - ➕ Add docker create script for contributors to setup databases locally by @billy1624 in https://github.com/SeaQL/sea-orm/pull/378
- 🌲 Log with tracing-subscriber by @billy1624 in https://github.com/SeaQL/sea-orm/pull/399
- Codegen SQLite by @billy1624 in https://github.com/SeaQL/sea-orm/pull/386
- PR without clippy warmings in file changed tab by @billy1624 in https://github.com/SeaQL/sea-orm/pull/401
- 📇 Rename
sea-strum
lib back tostrum
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/361
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.4.2...0.5.0
-
v0.4.2 Changes
December 12, 2021🛠 Fixed Issues
- ✂ Delete::many() doesn't work when schema_name is defined https://github.com/SeaQL/sea-orm/issues/362
- find_with_related panic https://github.com/SeaQL/sea-orm/issues/374
- How to define the rust type of TIMESTAMP? https://github.com/SeaQL/sea-orm/issues/344
- ➕ Add Table on the generated Column enum https://github.com/SeaQL/sea-orm/issues/356
🔀 Merged PRs
Delete::many()
withTableRef
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/363- 🛠 Fix related & linked with enum columns by @billy1624 in https://github.com/SeaQL/sea-orm/pull/376
- Temporary Fix: Handling MySQL & SQLite timestamp columns by @billy1624 in https://github.com/SeaQL/sea-orm/pull/379
- ➕ Add feature to generate table Iden by @Sytten in https://github.com/SeaQL/sea-orm/pull/360
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.4.1...0.4.2
-
v0.4.1 Changes
December 05, 2021🛠 Fixed Issues
- Is it possible to have 4 values Composite Key? https://github.com/SeaQL/sea-orm/issues/352
- 👍 [sea-orm-cli] Better handling of relation generations https://github.com/SeaQL/sea-orm/issues/239
🔀 Merged PRs
- ➕ Add TryFromU64 trait for
DateTime<FixedOffset>
. by @kev0960 in https://github.com/SeaQL/sea-orm/pull/331 - ➕ add offset and limit by @lz1998 in https://github.com/SeaQL/sea-orm/pull/351
- For some reason the
axum_example
fail to compile by @billy1624 in https://github.com/SeaQL/sea-orm/pull/355 - 👌 Support Up to 6 Values Composite Primary Key by @billy1624 in https://github.com/SeaQL/sea-orm/pull/353
- Codegen Handle Self Referencing & Multiple Relations to the Same Related Entity by @billy1624 in https://github.com/SeaQL/sea-orm/pull/347
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.4.0...0.4.1
-
v0.4.0 Changes
November 19, 2021🛠 Fixed Issues
- 🌲 Disable SQLx query logging https://github.com/SeaQL/sea-orm/issues/290
- Code generated by
sea-orm-cli
cannot pass clippy https://github.com/SeaQL/sea-orm/issues/296 - Should return detailed error message for connection failure https://github.com/SeaQL/sea-orm/issues/310
DateTimeWithTimeZone
does not implementSerialize
andDeserialize
https://github.com/SeaQL/sea-orm/issues/319- 👌 Support returning clause to avoid database hits https://github.com/SeaQL/sea-orm/issues/183
🔀 Merged PRs
- ⚡️ chore: update to Rust 2021 Edition by @sno2 in https://github.com/SeaQL/sea-orm/pull/273
- Enumeration - 3 by @billy1624 in https://github.com/SeaQL/sea-orm/pull/274
- Enumeration - 2 by @billy1624 in https://github.com/SeaQL/sea-orm/pull/261
- ⚠ Codegen fix clippy warnings by @billy1624 in https://github.com/SeaQL/sea-orm/pull/303
- ➕ Add axum example by @YoshieraHuang in https://github.com/SeaQL/sea-orm/pull/297
- Enumeration by @billy1624 in https://github.com/SeaQL/sea-orm/pull/258
- ➕ Add
PaginatorTrait
andCountTrait
for more constraints by @YoshieraHuang in https://github.com/SeaQL/sea-orm/pull/306 - Continue
PaginatorTrait
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/307 - 🔨 Refactor
Schema
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/309 - Detailed connection errors by @billy1624 in https://github.com/SeaQL/sea-orm/pull/312
- ⚠ Suppress
ouroboros
missing docs warnings by @billy1624 in https://github.com/SeaQL/sea-orm/pull/288 with-json
feature requireschrono/serde
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/320- Pass the argument
entity.table_ref()
instead of justentity
. by @josh-codes in https://github.com/SeaQL/sea-orm/pull/318 - Unknown types could be a newtypes instead of
ActiveEnum
by @billy1624 in https://github.com/SeaQL/sea-orm/pull/324 - Returning by @billy1624 in https://github.com/SeaQL/sea-orm/pull/292
💥 Breaking Changes
🔨 Refactor
paginate()
&count()
utilities intoPaginatorTrait
. You can use the paginator as usual but you might need to importPaginatorTrait
manually when upgrading from the previous version.use futures::TryStreamExt; use sea_orm::{entity::*, query::*, tests_cfg::cake}; let mut cake_stream = cake::Entity::find() .order_by_asc(cake::Column::Id) .paginate(db, 50) .into_stream(); while let Some(cakes) = cake_stream.try_next().await? { // Do something on cakes: Vec<cake::Model> }
The helper struct
Schema
convertingEntityTrait
into differentsea-query
statements now has to be initialized withDbBackend
.use sea_orm::{tests_cfg::*, DbBackend, Schema}; use sea_orm::sea_query::TableCreateStatement; // 0.3.x let _: TableCreateStatement = Schema::create_table_from_entity(cake::Entity); // 0.4.x let schema: Schema = Schema::new(DbBackend::MySql); let _: TableCreateStatement = schema.create_table_from_entity(cake::Entity);
⚡️ When performing insert or update operation on
ActiveModel
against PostgreSQL,RETURNING
clause will be used to perform select in a single SQL statement.// For PostgreSQL cake::ActiveModel { name: Set("Apple Pie".to_owned()), ..Default::default() } .insert(&postgres_db) .await?; assert_eq!( postgres_db.into_transaction_log(), vec![Transaction::from_sql_and_values( DbBackend::Postgres, r#"INSERT INTO "cake" ("name") VALUES ($1) RETURNING "id", "name""#, vec!["Apple Pie".into()] )]);
// For MySQL & SQLite cake::ActiveModel { name: Set("Apple Pie".to_owned()), ..Default::default() } .insert(&other_db) .await?; assert_eq!( other_db.into_transaction_log(), vec![ Transaction::from_sql_and_values( DbBackend::MySql, r#"INSERT INTO `cake` (`name`) VALUES (?)"#, vec!["Apple Pie".into()] ), Transaction::from_sql_and_values( DbBackend::MySql, r#"SELECT `cake`.`id`, `cake`.`name` FROM `cake` WHERE `cake`.`id` = ? LIMIT ?"#, vec![15.into(), 1u64.into()] )]);
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.3.2...0.4.0
-
v0.3.2 Changes
November 03, 2021🛠 Fixed Issues
- 👌 Support for BYTEA Postgres primary keys https://github.com/SeaQL/sea-orm/issues/286
🔀 Merged PRs
- 📚 Documentation for sea-orm by @charleschege in https://github.com/SeaQL/sea-orm/pull/280
- 👌 Support
Vec<u8>
primary key by @billy1624 in https://github.com/SeaQL/sea-orm/pull/287
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.3.1...0.3.2
-
v0.3.1 Changes
October 23, 2021(We are changing our Changelog format from now on)
🛠 Fixed Issues
- Align case transforms across derive macros https://github.com/SeaQL/sea-orm/issues/262
- Added
is_null
andis_not_null
toColumnTrait
https://github.com/SeaQL/sea-orm/issues/267
(The following is generated by GitHub)
🔀 Merged PRs
- 🔄 Changed manual url parsing to use Url crate by @AngelOnFira in https://github.com/SeaQL/sea-orm/pull/253
- ✅ Test self referencing relation by @billy1624 in https://github.com/SeaQL/sea-orm/pull/256
- Unify case-transform using the same crate by @billy1624 in https://github.com/SeaQL/sea-orm/pull/264
- CI cleaning by @AngelOnFira in https://github.com/SeaQL/sea-orm/pull/263
- CI install sea-orm-cli in debug mode by @billy1624 in https://github.com/SeaQL/sea-orm/pull/265
Full Changelog: https://github.com/SeaQL/sea-orm/compare/0.3.0...0.3.1