Added a solidity language server #601
Open
+243
−2
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This PR implements comprehensive Solidity programming language support for Serena, enabling the coding agent toolkit to assist with Ethereum smart contract development. This addresses the significant gap in Web3/blockchain language support identified in issue #592.
Changes Made
Core Implementation
Added
SolidityLanguageServerclass inlanguage_servers/solidity_language_server.py@nomicfoundation/solidity-language-serverExtended Language enum in
ls_config.pySOLIDITY = "solidity"language type.solfile pattern matching inget_source_fn_matcher()Registered language server in main
ls.pyfileLanguage.SOLIDITYFeatures Implemented
.solSolidity filessolccompiler andsolc-selectnode_modules,artifacts,cache,typechain, etc.Dependencies Required
Solidity Language Server
npm install -g @nomicfoundation/solidity-language-server
Solidity Compiler Manager
pip3 install solc-select
solc-select install latest
solc-select use latest
text
Testing
Impact
This implementation enables Serena to support the ~24k monthly active Solidity developers and 200k+ total Solidity developers mentioned in the original issue. It positions Serena as a comprehensive coding agent toolkit that can assist with:
Notes
This PR makes Serena blockchain-ready!