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

fix(deps): move @bufbuild/protobuf to dependencies #351

Merged
merged 4 commits into from
Jan 7, 2025

Conversation

danielmahon
Copy link
Contributor

@danielmahon danielmahon commented Dec 6, 2024

Move @bufbuild/protobuf to dependencies as its used in runtime and can conflict with newer versions (2.x)

2.x versions no longer export the WKT classes and because we are using 2.x in the parent app livekit-server-sdk will resolve to using that version throwing this error:

main-1  | file:///usr/src/app/node_modules/livekit-server-sdk/dist/SipClient.js:1
main-1  | import { Duration } from "@bufbuild/protobuf";
main-1  |          ^^^^^^^^
main-1  | SyntaxError: The requested module '@bufbuild/protobuf' does not provide an export named 'Duration'
main-1  |     at ModuleJob._instantiate (node:internal/modules/esm/module_job:146:21)
main-1  |     at ModuleJob.run (node:internal/modules/esm/module_job:229:5)
main-1  |     at ModuleLoader.import (node:internal/modules/esm/loader:473:24)
main-1  | 

(for a quick fix we patched this file to use the new 2.x DurationSchema creation method)

Move @bufbuild/protobuf to dependencies as its used in runtime and can conflict with newer versions
Copy link

changeset-bot bot commented Dec 6, 2024

🦋 Changeset detected

Latest commit: 100cdbe

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
livekit-server-sdk Patch
agent-dispatch Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@danielmahon danielmahon changed the title Move @bufbuild/protobuf to dependencies fix(deps): move @bufbuild/protobuf to dependencies Dec 6, 2024
Copy link
Contributor

@lukasIO lukasIO left a comment

Choose a reason for hiding this comment

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

great catch, thanks for this!

@lukasIO lukasIO merged commit 0b54ed5 into livekit:main Jan 7, 2025
10 checks passed
@github-actions github-actions bot mentioned this pull request Jan 6, 2025
@danielmahon danielmahon deleted the patch-1 branch January 7, 2025 22:01
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.

2 participants