# set\_solidity\_version

选择 Solidity 版本,若该版本未安装则会自动安装。

## 方法定义

```python
@staticmethod
def set_solidity_version(solidity_version: str) -> None
```

## 参数说明

| 参数                | 类型  | 说明           |
| ----------------- | --- | ------------ |
| solidity\_version | str | Solidity 版本号 |

## 返回值

无

## 示例代码

```python
from poseidon.evm import Utils

# 设置 Solidity 版本
Utils.set_solidity_version("0.8.20")
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://poseidon.seaeye.cn/evm/utils/set_solidity_version.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
