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

Version 7.2.6 breaks build and throws an error Error: ENOENT: no such file or directory, open ... #1975

Open
agadzhalov opened this issue Mar 5, 2024 · 2 comments

Comments

@agadzhalov
Copy link

When using v7.2.5 our proto project works just fine. But when we are using v7.2.6 the project can not be compiled because of thrown error Error: ENOENT: no such file or directory, open 'src/proto/mirror/basic_types.proto'. We didn't change anything in the protobuf files, they are the same for both version.

Currently we are limited to using only v7.2.5 because of fix: report missing import properly in loadSync

Reference issue for more details: Build operation does not work as expected.

Steps to reproduce:

  1. git clone git@github.com:hashgraph/hedera-sdk-js.git
  2. cd packages/proto/
  3. pnpm install protobufjs@7.2.6
  4. cd ../../
  5. task build -> Error: ENOENT: no such file or directory, open 'src/proto/mirror/basic_types.proto

protobuf.js version: 7.2.6

@abscondment
Copy link

I'm seeing the same thing. Interestingly, the "no such file or directory" path given in my error is a truly nonexistent path, merging two different real directories.

@patricio-hondagneu-simplisafe

I'm seeing the same thing. Interestingly, the "no such file or directory" path given in my error is a truly nonexistent path, merging two different real directories.

I'm experiencing the same issue when I pass a glob like myFolder/**/*.proto: for the first .proto file it works fine, but the moment it tries to read the second it prepends the URI of the previous one.

For a structure like:

/myFolder
│
└───/mySubfolder
    │
    ├───/A
    │   │
    │   └───a.proto
    │
    └───/B
        │
        └───b.proto

it reads a.proto just fine but then it tries to read b.proto as if it were located at /myFolder/mySubfolder/A/B/b.proto.

Very weird.

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

No branches or pull requests

3 participants