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

Cannot install typescript dependencies with yarn #1719

Open
inceenes10 opened this issue Jan 9, 2023 · 5 comments
Open

Cannot install typescript dependencies with yarn #1719

inceenes10 opened this issue Jan 9, 2023 · 5 comments
Labels
Feature New feature or request

Comments

@inceenes10
Copy link

Hi,
I am learning buf package manager for a few days and practicing it with nestjs. I have a problem with it.

If I use npm install @buf/openfga_api.grpc_node, package is installed successfully, but with yarn yarn add @buf/openfga_api.grpc_node it gives an error like this

error An unexpected error occurred: "The first argument must be of type string or an instance of Buffer, ArrayBuffer, or Array or an Array-like Object. Received undefined".

I don't understand the error. Help, please.

@timostamm
Copy link
Member

Hi Enes, thanks for the report. The error message from yarn really isn't ideal helpful. From our documentation:

Please be aware that Yarn versions greater than v1.10.0 and less than v2 are not supported. These versions of Yarn require the shasum field in the dist object to be set, but the BSR can't compute a digest without generating the code for all possible versions of the package.

We are currently looking into removing this limitation. In the meantime, is it an option for you to switch to a newer version?

@inceenes10
Copy link
Author

Do I have the option to contribute, but I don't really know where to start?

@timostamm
Copy link
Member

Thanks for the initiative, Enes! The code for the NPM registry implementation that runs Remote Packages is part of the BSR, which is closed source. It is definitely possible that the BSR will be open source in the future, but it is not currently planned. So we unfortunately cannot accept contributions right now.

Yarn berry makes some very opinionated choices that not everybody might agree with, but staying at v1 doesn't seem to be a great option either, judging from the maintainers note on GitHub:

If you hit bugs or issues with Yarn 1.x, we strongly suggest you migrate to the latest release - at this point they have been maintained longer than 1.x, and many classes of problems have already been addressed there.

@bufdev bufdev added the BSR label Jan 14, 2023
@bufdev
Copy link
Member

bufdev commented Mar 9, 2023

@timostamm is there anything for us to do here?

@timostamm
Copy link
Member

@bufdev, we're working on a feature that allows us to provide a hash for the package, which will make yarn v1 work.

Makes sense to me to wait for this feature to land, and close this issue as fixed then, so that users looking at this issue will know.

@doriable doriable added the Feature New feature or request label Jun 10, 2024
@bufdev bufdev removed the BSR label Jun 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants