Closed hongquan closed 1 year ago
So, is there currently any way to work with datetime
? I see some code in the repo for datetimes, but if chrono doesn't work, then what's the intended workflow?
Update: actually, you can use Datetime
from use edgedb_protocol::model::Datetime
, and it sorta works.
Apparently, there was https://github.com/edgedb/edgedb-rust/issues/198 and chrono types should now be supported. I have added "chrono"
as a feature to edgedb-protocol
in my Cargo.toml and yet I get the same error as the OP. In fact, the OP reproduction repo has the feature enabled too. Something is wrong. @tailhook ?
This should be working now thanks to #274 , closing
Hi @AlexDaniel @Dhghomon @hongquan,
I am still facing the same issue. Here's my Cargo.toml.
chrono = { version = "0.4.26", features = ["serde"] }
edgedb-derive = "0.5.1"
edgedb-protocol = { version = "0.6.0", features = ["chrono", "with-chrono"] }
edgedb-tokio = "0.5.0"
When define a struct with a
DateTime<Utc>
field, that struct can not be used as query result.This is a reproducible repo: https://bitbucket.org/hongquan/edgedb-chrono.
When building it, we get this error: