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

refactor(netlify): support @netlify/blobs v8 and improve options types #486

Merged
merged 4 commits into from
Oct 13, 2024

Conversation

serhalp
Copy link
Contributor

@serhalp serhalp commented Sep 15, 2024

The peer dependency only specifies support for v6 and v7, but v8 works just fine.

Closes #485.

This adds v8 to the peer dependencies, bumps the dev dep to v8, updates the tests (there's a new requirement that's specific to unusual use cases like unstorage's tests, which are run outside of the Netlify platform and the Netlify CLI), and adjust the driver types to ensure compatibility with all supported versions.

See netlify/blobs#183.

I believe @netlify/blobs@8 will error in local dev when using netlify-cli before 17.21.1. This doesn't seem like unstorage's problem though, so I didn't do anything about that here.

The peer dependency only specifies support for v6 and v7, but v8 works
just fine.

This adds v8 to the peer dependencies, bumps the dev dep to v8, updates
the tests (there's a new requirement that's specific to unusual use
cases like unstorage's tests, which are run outside of the Netlify
platform and the Netlify CLI), and adjust the driver types to ensure
compatibility with all supported versions.

See netlify/blobs#183.

I believe @netlify/blobs@8 will error in local dev when using
netlify-cli before 17.21.1. This doesn't seem like unstorage's problem
though, so I didn't do anything about that here.
src/drivers/netlify-blobs.ts Outdated Show resolved Hide resolved
@serhalp serhalp marked this pull request as ready for review October 11, 2024 16:08
@serhalp serhalp requested a review from pi0 October 11, 2024 16:08
Copy link

codecov bot commented Oct 13, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 58.66%. Comparing base (4d61c78) to head (c2c1c0f).
Report is 78 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #486      +/-   ##
==========================================
- Coverage   65.05%   58.66%   -6.39%     
==========================================
  Files          39       38       -1     
  Lines        4055     3109     -946     
  Branches      487      523      +36     
==========================================
- Hits         2638     1824     -814     
+ Misses       1408     1276     -132     
  Partials        9        9              

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

@pi0 pi0 changed the title chore(deps): support @netlify/blobs v8 fix(netlify): support @netlify/blobs v8 Oct 13, 2024
@pi0 pi0 changed the title fix(netlify): support @netlify/blobs v8 refactor(netlify): support @netlify/blobs v8 and improve options types Oct 13, 2024
Copy link
Member

@pi0 pi0 left a comment

Choose a reason for hiding this comment

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

Thank you ❤️

@pi0 pi0 merged commit bec8788 into unjs:main Oct 13, 2024
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

@netlify/blobs@8 is compatible but is reported as a peer dependency error
2 participants