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

solidity-language-server ENOENT: solidity-language-server/out/antlr/Solidity.tokens #558

Closed
Ethnical opened this issue Apr 18, 2024 · 2 comments · Fixed by #559
Closed
Assignees
Labels
status:ready This issue is ready to be worked on type:bug Something isn't working

Comments

@Ethnical
Copy link

Hey there,
On the last version 0.8.0 of the solidity-language-server I got an error. I tried with multiples version of node (with the latests version and other version from 18 to 20) but always failed with the same error.

  code: 'ENOENT',
  path: '/Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/antlr/Solidity.tokens'

Here, the test is with the 20.5.0 and the npm version is: 9.8.0.
I don't know why I got this missing antlr/Solidity.tokens if someone have an idea would happy to know for know. I am downgrading to 0.7.3 that is current working for me there.

Error: ENOENT: no such file or directory, open '/Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/antlr/Solidity.tokens'
    at Object.openSync (node:fs:602:3)
    at Object.readFileSync (node:fs:470:35)
    at /Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/index.js:87:30951
    at /Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/index.js:56:70348
    at node_modules/@solidity-parser/parser/dist/index.cjs.js (/Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/index.js:301:129281)
    at /Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/index.js:2:1341
    at Object.<anonymous> (/Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/index.js:2897:89590)
    at Module._compile (node:internal/modules/cjs/loader:1233:14)
    at Module._extensions..js (node:internal/modules/cjs/loader:1287:10)
    at Module.load (node:internal/modules/cjs/loader:1091:32) {
  errno: -2,
  syscall: 'open',
  code: 'ENOENT',
  path: '/Users/ethnical/.nvm/versions/node/v20.5.0/lib/node_modules/@nomicfoundation/solidity-language-server/out/antlr/Solidity.tokens'
}

For reproducing, I just tried to install with a simple npm install and the package name.

npm install @nomicfoundation/solidity-language-server -g

I am on Macos Sillicon maybe this can help?

Thanks!

@kanej
Copy link
Member

kanej commented Apr 18, 2024

I have been able to reproduce this locally. It looks like our packaging config is behaving different with the latest version of npm.

@kanej kanej self-assigned this Apr 18, 2024
@kanej kanej added type:bug Something isn't working status:ready This issue is ready to be worked on and removed status:triaging labels Apr 18, 2024
kanej added a commit that referenced this issue Apr 18, 2024
The run of `npm pack` was not picking up `./out/**` subfolders. The
`files` property has now been changed to include the entire folder.

Fixes #558.
kanej added a commit that referenced this issue Apr 18, 2024
The run of `npm pack` was not picking up `./out/**` subfolders. The
`files` property has now been changed to include the entire folder.

Fixes #558.
@kanej kanej mentioned this issue Apr 18, 2024
kanej added a commit that referenced this issue Apr 18, 2024
The run of `npm pack` was not picking up `./out/**` subfolders. The
`files` property has now been changed to include the entire folder.

Fixes #558.
@kanej
Copy link
Member

kanej commented Apr 18, 2024

@Ethnical can you try the latest version v0.8.1?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status:ready This issue is ready to be worked on type:bug Something isn't working
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants