host contracts in contender repo
@zeroXbrock 已经在做这个了。
开始于 2025年12月19日。
评估
这个 Issue 还没有评估数据。
描述
Is your feature request related to a problem? Please describe.
Firstly, contender scenario files use raw bytecode, which is hard to reason about. Additionally, if bytecode is specified without a comment linking to the source, then it's practically impossible to know the exact source code, making debugging difficult.
Most of the scenarios I've written so far have used high-volume-contract at their core (it contains the SpamMe contract). The fill-block spam subcommand relies on it as well. We also frequently use include TestToken and Unicheat.
It would be nice to have that contract be tightly coupled with contender as we add more subcommands and iterate on the contract.
Describe the solution you'd like
We still need our scenarios to use specific bytecode, but we could also use relative file paths, which are easy to read.
We should start by adding support for .hex files, but we should also support json files, so the user doesn't have to manually parse the bytecode from their json file into hex.
for .hex files:
- we only need the path.
- the contents should be utf8-encoded hex (like these)
- support contents with or without the 0x prefix
for .json files:
-
we need the path and a filter string to tell us where in the JSON our bytecode is
-
filter strings should be interpreted jq-style
- example: the filter string (jq-style) for bytecode from forge builds is
.bytecode.object - hardhat's is just
.bytecode
- example: the filter string (jq-style) for bytecode from forge builds is
-
make
bytecodeoptional in scenario files, addfile(andfilterfor json)
add contracts to the contender repo
- add high-volume-contracts, testToken, unicheater to this repo as submodules
- add a shell script under
scripts/that checks for the submodules, downloads them if needed, runsforge buildand writes bytecode from forge artifacts tocrates/cli/src/default_scenarios/contracts/*.hex
- 主要语言
- Rust
- 星标
- 144
- 派生
- 58
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 提供 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
flashbots/contender 的其他 Issue
-
enhancement
难度 5/5 一周以上 新手友好度 45/100
-
enhancement
难度 4/5 3-5 天 新手友好度 45/100
-
server: export DB from session可能重新可做 @zeroXbrock 于 203 天前认领,目前没有进行中的 PR。 未关闭enhancement help wanted question
-
enhancement
难度 4/5 3-5 天 新手友好度 62/100
-
bug
难度 3/5 1-2 天 新手友好度 52/100
查看 flashbots/contender 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
open-telemetry/weaver#1917 ·
维护者通常 2 天内回复
-
bug host P3 web
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
documentation pkg:sdk project
难度 2/5 1-3 小时 新手友好度 76/100
-
priority middle
难度 1/5 1 小时以内 新手友好度 72/100
KATO-Hiro/AtCoderClans#13029 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 76/100
RustCrypto/formats#2544 ·
维护者通常 1 天内回复