kysely-libsql icon indicating copy to clipboard operation
kysely-libsql copied to clipboard

Incompatible types with recent `@libsql/client`

Open akoenig opened this issue 1 year ago • 7 comments

Using the recent version (0.10.0) of @libsql/client leads to the following typing error when initializing the dialect via:

const dialect = new LibsqlDialect({
  client: createClient({
    url: "file:database.db"
  }),
});

Typing error:

 The types returned by 'sync()' are incompatible between these types.
    Type 'Promise<Replicated>' is not assignable to type 'Promise<void>'.
      Type 'Replicated' is not assignable to type 'void'.
        Type '{ frame_no: number; frames_synced: number; }' is not assignable to type 'void'.

Version of @libsql/kysely-libsql is 0.4.1.

akoenig avatar Sep 02 '24 09:09 akoenig

This is updated in the main branch but @penberg needs to release a new version

ottomated avatar Sep 03 '24 21:09 ottomated

REOPEN PLS

yigsvnsla avatar Apr 08 '25 06:04 yigsvnsla

@yigsvnsla I'm maintaining a fork at https://www.npmjs.com/package/kysely-libsql in the meantime

ottomated avatar Apr 08 '25 17:04 ottomated

Plese fix this issue.

wldbest avatar Aug 08 '25 10:08 wldbest

Any Update ?

TomEverson avatar Aug 21 '25 08:08 TomEverson

Use: https://www.npmjs.com/package/kysely-libsql or This: https://turso.tech/blog/introducing-turso-serverless-javascript-driver

I've used serverless driver and solved my problem.

wldbest avatar Aug 21 '25 13:08 wldbest

I've also faced this issue. What is holding back the new release? BR

Proallone avatar Aug 31 '25 18:08 Proallone