You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Assume I'm storing my javascript files in \\DESKTOP-2PLO61T\distributed\node\my-package\
Attempt to load api.proto from \\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\google\protobuf\api.proto using Root.load()
util.path.resolve() calls util.path.normalize() and the path to api.proto changes to /DESKTOP-2PLO61T/distributed/node/my-package/node_modules/protobufjs/google/protobuf/api.proto
Note the single forward slash at the beginning of the path instead of two back slashes
Exception thrown because the normalized path is not a valid path to api.proto
Exception from running node \\DESKTOP-2PLO61T\distributed\node\my-package\index.js:
\\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\src\root.js:94
throw err;
^
Error: ENOENT: no such file or directory, open '/DESKTOP-2PLO61T/distributed/node/my-package/node_modules/protobufjs/google/protobuf/api.proto'
at Object.openSync (fs.js:443:3)
at Object.readFileSync (fs.js:343:35)
at fetch (\\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\src\root.js:160:34)
at Root.load (\\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\src\root.js:194:13)
at Root.loadSync (\\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\src\root.js:235:17)
at Object.loadSync (\\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\src\index-light.js:69:17)
at Object.<anonymous> (\\DESKTOP-2PLO61T\distributed\node\my-package\index.js:6:10)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
If you think this is a valid issue and there's no workaround, I'll try to find time to make a PR to address it.
The text was updated successfully, but these errors were encountered:
protobuf.js version: 6.8.8
\\DESKTOP-2PLO61T\distributed\node\my-package\
api.proto
from\\DESKTOP-2PLO61T\distributed\node\my-package\node_modules\protobufjs\google\protobuf\api.proto
usingRoot.load()
util.path.resolve()
callsutil.path.normalize()
and the path toapi.proto
changes to/DESKTOP-2PLO61T/distributed/node/my-package/node_modules/protobufjs/google/protobuf/api.proto
api.proto
index.js:
package.json:
Exception from running
node \\DESKTOP-2PLO61T\distributed\node\my-package\index.js
:If you think this is a valid issue and there's no workaround, I'll try to find time to make a PR to address it.
The text was updated successfully, but these errors were encountered: