sea-query icon indicating copy to clipboard operation
sea-query copied to clipboard

get time from sqlx-sqlite directly

Open kyoto7250 opened this issue 2 years ago • 8 comments

PR Info

  • Closes close #409

Changes

  • [x] get time from sqlx-sqlite directly

Breaking Changes

  • [x] In DateType, time is no longer compatible with chrono .

kyoto7250 avatar Aug 10 '22 12:08 kyoto7250

@kyoto7250 some tests failed

ikrivosheev avatar Aug 10 '22 13:08 ikrivosheev

Ah, This code does not work because It is not pattern matching anymore. I didn't notice because the test passes.

v @ Value::TimeDate(_) => query.bind(v.as_deref())

Thank you, I fixed in https://github.com/SeaQL/sea-query/pull/412/commits/a8806ed1c5eff57ebdb4f248e179294626c671d9.

kyoto7250 avatar Aug 10 '22 13:08 kyoto7250

@ikrivosheev

Hmm, we got a runtime error in CI.

Sorry, I will check it.

kyoto7250 avatar Aug 10 '22 13:08 kyoto7250

@ikrivosheev

Hmm, we got a runtime error in CI.

Sorry, I will check it.

I think sqlx convert time object differently than sea-query do it before...

ikrivosheev avatar Aug 10 '22 13:08 ikrivosheev

It appears that sqlx v0.6.1 returns subsecond in DateTime, but this behaviour is different from chrono. I think this PR includes breaking change.

https://github.com/SeaQL/sea-query/blob/6db27fdc82285a9e585997a762438b5c941b0073/src/value.rs#L436-L437

kyoto7250 avatar Aug 14 '22 12:08 kyoto7250

Sorry, I am traveling until this week, so I will check it in this weekend.

Thank you for your kind 👍🏽

kyoto7250 avatar Aug 31 '22 00:08 kyoto7250

I'm sorry I'm late. I resolved the conflict. And I revert 34b96fb, so could you please review again?

kyoto7250 avatar Sep 04 '22 14:09 kyoto7250

@kyoto7250 hello! Can you resolve merge conflict?

ikrivosheev avatar Sep 19 '22 10:09 ikrivosheev

@kyoto7250 any updates?

ikrivosheev avatar Sep 30 '22 17:09 ikrivosheev