Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add deno-kv driver #233

Merged
merged 16 commits into from
Dec 12, 2024
Merged

feat: add deno-kv driver #233

merged 16 commits into from
Dec 12, 2024

Conversation

so1ve
Copy link
Contributor

@so1ve so1ve commented May 25, 2023

close #224
continue #227

@Hebilicious Hebilicious added enhancement New feature or request driver labels Jun 30, 2023 — with Volta.net
@Hebilicious Hebilicious self-assigned this Jun 30, 2023
@Hebilicious Hebilicious self-requested a review June 30, 2023 17:24
@Hebilicious Hebilicious removed the enhancement New feature or request label Jun 30, 2023 — with Volta.net
Copy link
Member

@Hebilicious Hebilicious left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR @so1ve !

It's missing documentation and tests.

We also might have some issues testing this with the CI. Maybe we can stub or mock DenoKV, or run the Deno test alone.

@so1ve
Copy link
Contributor Author

so1ve commented Jul 3, 2023

I can add documentation for it, but I'm not sure how to test :( Maybe just simply run deno alone?

@Hebilicious
Copy link
Member

Hebilicious commented Jul 3, 2023

I can add documentation for it, but I'm not sure how to test :( Maybe just simply run deno alone?

You can try a similar approach to here https://github.com/unjs/nitro/blob/main/test/presets/deno-server.test.ts
and for the CI https://github.com/unjs/nitro/blob/1d0c12026e7f07d7e7b09e794b1159d9edb57a79/.github/workflows/ci.yml#L46

@nakasyou
Copy link
Contributor

nakasyou commented Jul 8, 2023

I wrote this test on so1ve#10.
Because I want to marge this pull request.

* fix(prefixStorage): prefix `getItemRaw` and `setItemRaw` (unjs#232)

* fix(github): fetchFiles should return files (unjs#229)

* chore(deps): update all non-major dependencies (unjs#220)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* chore: update eslint

* test: skip cloudflare-kv-http on node >= 18

* chore(release): v1.6.1

* docs: add social share image

* chore: update deps

* docs: fix typo (unjs#239)

Change `environemnt` to `environment`
Update cloudflare-kv-http.md

* chore: update dependencies

* feat: generic type support (unjs#237)

* refactor: fix issues with typescript strict (unjs#250)

* chore: add type check to ci

* ci: skip flaky azure tests

* chore(release): v1.7.0

* chore(deps): update all non-major dependencies

* docs: fix typo (unjs#252)

* chore(deps): update all non-major dependencies

* test: add test for `github` driver (unjs#259)

* feat: experimental operation batching (unjs#240)

Co-authored-by: Pooya Parsa <pooya@pi0.io>

* feat(cloudflare-kv): support `base` option for keys (unjs#261)

* feat: `cloudflare-r2-binding` driver (unjs#235)

* fix: add missing `cloudflareR2Binding` to the `builtinDrivers`

* chore: update dev dependencies

* chore(release): v1.8.0

* Fix typescript checks

* add typehint

* Install execa

* Write test code

* Remove not using import

---------

Co-authored-by: 魔王少年 <q267009886.work@gmail.com>
Co-authored-by: Andrei Dyldin <and@cesbo.com>
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Pooya Parsa <pooya@pi0.io>
Co-authored-by: Sébastien Chopin <seb@nuxt.com>
Co-authored-by: Neelansh Mathur <53081208+neelansh15@users.noreply.github.com>
Co-authored-by: 魔王少年 <q267009886.tw@gmail.com>
Co-authored-by: Alex Duval <alexduval71@gmail.com>
Co-authored-by: Hebilicious <xsh4k3@gmail.com>
@nuxt-studio
Copy link

nuxt-studio bot commented Jul 8, 2023

Live Preview ready!

Name Edit Preview Latest Commit
unstorage Edit on Studio ↗︎ View Live Preview ee3c8d5

Copy link
Member

@Hebilicious Hebilicious left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Testing with Deno can be complicated, so I'm not sure we should do more. @pi0 will review it

src/drivers/deno-kv.ts Outdated Show resolved Hide resolved
@mavdotjs mavdotjs mentioned this pull request Jan 28, 2024
8 tasks
@pi0 pi0 changed the title feat(drivers): add support for Deno KV feat: add deno-kv driver Dec 11, 2024
Copy link

codecov bot commented Dec 12, 2024

Codecov Report

Attention: Patch coverage is 0% with 94 lines in your changes missing coverage. Please review.

Project coverage is 60.34%. Comparing base (4d61c78) to head (85338c4).
Report is 118 commits behind head on main.

Files with missing lines Patch % Lines
src/drivers/deno-kv.ts 0.00% 93 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #233      +/-   ##
==========================================
- Coverage   65.05%   60.34%   -4.72%     
==========================================
  Files          39       38       -1     
  Lines        4055     3311     -744     
  Branches      487      557      +70     
==========================================
- Hits         2638     1998     -640     
+ Misses       1408     1309      -99     
+ Partials        9        4       -5     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@pi0
Copy link
Member

pi0 commented Dec 12, 2024

Thanks again for the PR.

I have worked on implementation updates (mainly in b79cf2e), updated tests to run all of the test-suit, and added initial docs, we can move it forward now!

@pi0 pi0 merged commit 9a8fe4c into unjs:main Dec 12, 2024
3 of 4 checks passed
@pi0 pi0 mentioned this pull request Dec 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support deno kv
4 participants