dolmos 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (232) hide show
  1. dolmos-0.1.0/.git-blame-ignore-revs +3 -0
  2. dolmos-0.1.0/.gitignore +36 -0
  3. dolmos-0.1.0/.gitmodules +15 -0
  4. dolmos-0.1.0/.pre-commit-config.yaml +13 -0
  5. dolmos-0.1.0/BUILDING.md +1 -0
  6. dolmos-0.1.0/CHANGELOG.md +41 -0
  7. dolmos-0.1.0/CONTRIBUTING.md +94 -0
  8. dolmos-0.1.0/LICENSE +661 -0
  9. dolmos-0.1.0/MANIFEST.in +6 -0
  10. dolmos-0.1.0/NOTICE +45 -0
  11. dolmos-0.1.0/PKG-INFO +240 -0
  12. dolmos-0.1.0/README.md +198 -0
  13. dolmos-0.1.0/RELEASING.md +60 -0
  14. dolmos-0.1.0/docs/getting-started.md +243 -0
  15. dolmos-0.1.0/docs/warnings.md +54 -0
  16. dolmos-0.1.0/examples/README.md +50 -0
  17. dolmos-0.1.0/examples/invariants/README.md +32 -0
  18. dolmos-0.1.0/examples/invariants/foundry.toml +6 -0
  19. dolmos-0.1.0/examples/invariants/remappings.txt +1 -0
  20. dolmos-0.1.0/examples/invariants/src/ERC20.sol +19 -0
  21. dolmos-0.1.0/examples/invariants/src/ERC721.sol +13 -0
  22. dolmos-0.1.0/examples/invariants/src/MiniVat.sol +56 -0
  23. dolmos-0.1.0/examples/invariants/src/Vat.sol +341 -0
  24. dolmos-0.1.0/examples/invariants/test/ERC20.t.sol +97 -0
  25. dolmos-0.1.0/examples/invariants/test/ERC721.t.sol +35 -0
  26. dolmos-0.1.0/examples/invariants/test/MiniVat.t.sol +25 -0
  27. dolmos-0.1.0/examples/invariants/test/Reentrancy.t.sol +112 -0
  28. dolmos-0.1.0/examples/invariants/test/SimpleState.t.sol +37 -0
  29. dolmos-0.1.0/examples/invariants/test/Vat.t.sol +27 -0
  30. dolmos-0.1.0/examples/simple/README.md +47 -0
  31. dolmos-0.1.0/examples/simple/foundry.toml +10 -0
  32. dolmos-0.1.0/examples/simple/remappings.txt +2 -0
  33. dolmos-0.1.0/examples/simple/src/BadElections.sol +66 -0
  34. dolmos-0.1.0/examples/simple/src/IsPowerOfTwo.sol +19 -0
  35. dolmos-0.1.0/examples/simple/src/TotalPrice.sol +24 -0
  36. dolmos-0.1.0/examples/simple/src/Vault.sol +21 -0
  37. dolmos-0.1.0/examples/simple/src/multicaller/MulticallerWithSender.sol +151 -0
  38. dolmos-0.1.0/examples/simple/test/BadElections.t.sol +76 -0
  39. dolmos-0.1.0/examples/simple/test/Fork.t.sol +54 -0
  40. dolmos-0.1.0/examples/simple/test/IsPowerOfTwo.t.sol +39 -0
  41. dolmos-0.1.0/examples/simple/test/Multicaller.t.sol +218 -0
  42. dolmos-0.1.0/examples/simple/test/TotalPrice.t.sol +29 -0
  43. dolmos-0.1.0/examples/simple/test/Vault.t.sol +56 -0
  44. dolmos-0.1.0/examples/tokens/ERC20/foundry.toml +6 -0
  45. dolmos-0.1.0/examples/tokens/ERC20/remappings.txt +3 -0
  46. dolmos-0.1.0/examples/tokens/ERC20/src/BackdoorERC20.sol +19 -0
  47. dolmos-0.1.0/examples/tokens/ERC20/src/OpenZeppelinERC20.sol +10 -0
  48. dolmos-0.1.0/examples/tokens/ERC20/src/SoladyERC20.sol +36 -0
  49. dolmos-0.1.0/examples/tokens/ERC20/src/SolmateERC20.sol +10 -0
  50. dolmos-0.1.0/examples/tokens/ERC20/test/BackdoorERC20.t.sol +76 -0
  51. dolmos-0.1.0/examples/tokens/ERC20/test/CurveTokenV3.t.sol +72 -0
  52. dolmos-0.1.0/examples/tokens/ERC20/test/DEIStablecoin.sol +70 -0
  53. dolmos-0.1.0/examples/tokens/ERC20/test/DEIStablecoin.t.sol +70 -0
  54. dolmos-0.1.0/examples/tokens/ERC20/test/ERC20Test.sol +98 -0
  55. dolmos-0.1.0/examples/tokens/ERC20/test/OpenZeppelinERC20.t.sol +41 -0
  56. dolmos-0.1.0/examples/tokens/ERC20/test/SoladyERC20.t.sol +41 -0
  57. dolmos-0.1.0/examples/tokens/ERC20/test/SolmateERC20.t.sol +41 -0
  58. dolmos-0.1.0/examples/tokens/ERC721/foundry.toml +6 -0
  59. dolmos-0.1.0/examples/tokens/ERC721/remappings.txt +3 -0
  60. dolmos-0.1.0/examples/tokens/ERC721/src/OpenZeppelinERC721.sol +12 -0
  61. dolmos-0.1.0/examples/tokens/ERC721/src/SoladyERC721.sol +33 -0
  62. dolmos-0.1.0/examples/tokens/ERC721/src/SolmateERC721.sol +14 -0
  63. dolmos-0.1.0/examples/tokens/ERC721/test/ERC721Test.sol +104 -0
  64. dolmos-0.1.0/examples/tokens/ERC721/test/OpenZeppelinERC721.t.sol +49 -0
  65. dolmos-0.1.0/examples/tokens/ERC721/test/SoladyERC721.t.sol +51 -0
  66. dolmos-0.1.0/examples/tokens/ERC721/test/SolmateERC721.t.sol +51 -0
  67. dolmos-0.1.0/packages/dolmos/Dockerfile +36 -0
  68. dolmos-0.1.0/packages/dolmos/README.md +15 -0
  69. dolmos-0.1.0/packages/dolmos-builder/Dockerfile +31 -0
  70. dolmos-0.1.0/packages/solvers/.dockerignore +1 -0
  71. dolmos-0.1.0/packages/solvers/Dockerfile +110 -0
  72. dolmos-0.1.0/packages/solvers/README.md +64 -0
  73. dolmos-0.1.0/pyproject.toml +89 -0
  74. dolmos-0.1.0/requirements-benchmark.txt +3 -0
  75. dolmos-0.1.0/setup.cfg +4 -0
  76. dolmos-0.1.0/src/dolmos/__init__.py +1 -0
  77. dolmos-0.1.0/src/dolmos/__main__.py +2053 -0
  78. dolmos-0.1.0/src/dolmos/assertions.py +287 -0
  79. dolmos-0.1.0/src/dolmos/bitvec.py +1009 -0
  80. dolmos-0.1.0/src/dolmos/build.py +474 -0
  81. dolmos-0.1.0/src/dolmos/bytevec.py +808 -0
  82. dolmos-0.1.0/src/dolmos/calldata.py +335 -0
  83. dolmos-0.1.0/src/dolmos/cheatcodes.py +1629 -0
  84. dolmos-0.1.0/src/dolmos/config.py +1020 -0
  85. dolmos-0.1.0/src/dolmos/console.py +131 -0
  86. dolmos-0.1.0/src/dolmos/constants.py +12 -0
  87. dolmos-0.1.0/src/dolmos/contract.py +542 -0
  88. dolmos-0.1.0/src/dolmos/env.py +166 -0
  89. dolmos-0.1.0/src/dolmos/exceptions.py +182 -0
  90. dolmos-0.1.0/src/dolmos/flamegraphs.py +240 -0
  91. dolmos-0.1.0/src/dolmos/hashes.py +775 -0
  92. dolmos-0.1.0/src/dolmos/logs.py +90 -0
  93. dolmos-0.1.0/src/dolmos/mapper.py +535 -0
  94. dolmos-0.1.0/src/dolmos/memtrace.py +183 -0
  95. dolmos-0.1.0/src/dolmos/processes.py +267 -0
  96. dolmos-0.1.0/src/dolmos/sevm.py +3855 -0
  97. dolmos-0.1.0/src/dolmos/solve.py +615 -0
  98. dolmos-0.1.0/src/dolmos/solvers.py +578 -0
  99. dolmos-0.1.0/src/dolmos/traces.py +238 -0
  100. dolmos-0.1.0/src/dolmos/ui.py +96 -0
  101. dolmos-0.1.0/src/dolmos/utils.py +1723 -0
  102. dolmos-0.1.0/src/dolmos.egg-info/PKG-INFO +240 -0
  103. dolmos-0.1.0/src/dolmos.egg-info/SOURCES.txt +230 -0
  104. dolmos-0.1.0/src/dolmos.egg-info/dependency_links.txt +1 -0
  105. dolmos-0.1.0/src/dolmos.egg-info/entry_points.txt +2 -0
  106. dolmos-0.1.0/src/dolmos.egg-info/requires.txt +15 -0
  107. dolmos-0.1.0/src/dolmos.egg-info/scm_file_list.json +242 -0
  108. dolmos-0.1.0/src/dolmos.egg-info/scm_version.json +8 -0
  109. dolmos-0.1.0/src/dolmos.egg-info/top_level.txt +1 -0
  110. dolmos-0.1.0/tests/conftest.py +12 -0
  111. dolmos-0.1.0/tests/data/multi-contract-ast.json +1 -0
  112. dolmos-0.1.0/tests/expected/all.json +7046 -0
  113. dolmos-0.1.0/tests/expected/erc20.json +206 -0
  114. dolmos-0.1.0/tests/expected/erc721.json +65 -0
  115. dolmos-0.1.0/tests/expected/ffi.json +52 -0
  116. dolmos-0.1.0/tests/expected/invariants.json +71 -0
  117. dolmos-0.1.0/tests/expected/simple.json +287 -0
  118. dolmos-0.1.0/tests/expected/solver.json +67 -0
  119. dolmos-0.1.0/tests/expected/vyper.json +108 -0
  120. dolmos-0.1.0/tests/ffi/foundry.toml +10 -0
  121. dolmos-0.1.0/tests/ffi/remappings.txt +2 -0
  122. dolmos-0.1.0/tests/ffi/test/Ffi.t.sol +74 -0
  123. dolmos-0.1.0/tests/regression/.env +24 -0
  124. dolmos-0.1.0/tests/regression/dolmos.toml +173 -0
  125. dolmos-0.1.0/tests/regression/foundry.toml +13 -0
  126. dolmos-0.1.0/tests/regression/remappings.txt +3 -0
  127. dolmos-0.1.0/tests/regression/src/Const.sol +6 -0
  128. dolmos-0.1.0/tests/regression/src/Counter.sol +83 -0
  129. dolmos-0.1.0/tests/regression/src/Create.sol +17 -0
  130. dolmos-0.1.0/tests/regression/src/List.sol +24 -0
  131. dolmos-0.1.0/tests/regression/src/SignExtend.sol +8 -0
  132. dolmos-0.1.0/tests/regression/src/Storage.sol +41 -0
  133. dolmos-0.1.0/tests/regression/test/Arith.t.sol +62 -0
  134. dolmos-0.1.0/tests/regression/test/AssertTest.t.sol +42 -0
  135. dolmos-0.1.0/tests/regression/test/Block.t.sol +46 -0
  136. dolmos-0.1.0/tests/regression/test/BlockNumber.t.sol +26 -0
  137. dolmos-0.1.0/tests/regression/test/Buffers.t.sol +60 -0
  138. dolmos-0.1.0/tests/regression/test/Byte.t.sol +38 -0
  139. dolmos-0.1.0/tests/regression/test/Call.t.sol +178 -0
  140. dolmos-0.1.0/tests/regression/test/CallAlias.t.sol +116 -0
  141. dolmos-0.1.0/tests/regression/test/Concretization.t.sol +122 -0
  142. dolmos-0.1.0/tests/regression/test/Console.t.sol +82 -0
  143. dolmos-0.1.0/tests/regression/test/Const.t.sol +17 -0
  144. dolmos-0.1.0/tests/regression/test/Constructor.t.sol +43 -0
  145. dolmos-0.1.0/tests/regression/test/Context.t.sol +300 -0
  146. dolmos-0.1.0/tests/regression/test/Counter.t.sol +135 -0
  147. dolmos-0.1.0/tests/regression/test/Create.t.sol +36 -0
  148. dolmos-0.1.0/tests/regression/test/Create2.t.sol +133 -0
  149. dolmos-0.1.0/tests/regression/test/Create3.t.sol +144 -0
  150. dolmos-0.1.0/tests/regression/test/Deal.t.sol +94 -0
  151. dolmos-0.1.0/tests/regression/test/Extcodehash.t.sol +269 -0
  152. dolmos-0.1.0/tests/regression/test/Foundry.t.sol +225 -0
  153. dolmos-0.1.0/tests/regression/test/Getter.t.sol +18 -0
  154. dolmos-0.1.0/tests/regression/test/Invalid.t.sol +26 -0
  155. dolmos-0.1.0/tests/regression/test/Invariant.t.sol +50 -0
  156. dolmos-0.1.0/tests/regression/test/InvariantProbes.t.sol +50 -0
  157. dolmos-0.1.0/tests/regression/test/InvariantSender.t.sol +57 -0
  158. dolmos-0.1.0/tests/regression/test/InvariantSender2.t.sol +110 -0
  159. dolmos-0.1.0/tests/regression/test/InvariantTarget.t.sol +149 -0
  160. dolmos-0.1.0/tests/regression/test/InvariantTarget2.t.sol +174 -0
  161. dolmos-0.1.0/tests/regression/test/InvariantTargetThis.t.sol +103 -0
  162. dolmos-0.1.0/tests/regression/test/InvariantTimestamp.t.sol +77 -0
  163. dolmos-0.1.0/tests/regression/test/Library.t.sol +25 -0
  164. dolmos-0.1.0/tests/regression/test/LibraryLinking.t.sol +19 -0
  165. dolmos-0.1.0/tests/regression/test/List.t.sol +72 -0
  166. dolmos-0.1.0/tests/regression/test/MegaMem.t.sol +477 -0
  167. dolmos-0.1.0/tests/regression/test/Natspec.t.sol +130 -0
  168. dolmos-0.1.0/tests/regression/test/OpCodesBlobBaseFee_BlobHash.t.sol +124 -0
  169. dolmos-0.1.0/tests/regression/test/OpCodesCLZ.sol +115 -0
  170. dolmos-0.1.0/tests/regression/test/Opcode.t.sol +72 -0
  171. dolmos-0.1.0/tests/regression/test/Panic.t.sol +194 -0
  172. dolmos-0.1.0/tests/regression/test/Prank.t.sol +284 -0
  173. dolmos-0.1.0/tests/regression/test/Proxy.t.sol +35 -0
  174. dolmos-0.1.0/tests/regression/test/Revert.t.sol +118 -0
  175. dolmos-0.1.0/tests/regression/test/Send.t.sol +140 -0
  176. dolmos-0.1.0/tests/regression/test/Setup.t.sol +37 -0
  177. dolmos-0.1.0/tests/regression/test/SetupPlus.t.sol +96 -0
  178. dolmos-0.1.0/tests/regression/test/SetupSymbolic.t.sol +12 -0
  179. dolmos-0.1.0/tests/regression/test/Sha3.t.sol +113 -0
  180. dolmos-0.1.0/tests/regression/test/SignExtend.t.sol +12 -0
  181. dolmos-0.1.0/tests/regression/test/Signature.t.sol +426 -0
  182. dolmos-0.1.0/tests/regression/test/SimpleState.t.sol +84 -0
  183. dolmos-0.1.0/tests/regression/test/SmolWETH.t.sol +61 -0
  184. dolmos-0.1.0/tests/regression/test/Snapshot.t.sol +159 -0
  185. dolmos-0.1.0/tests/regression/test/Solver.t.sol +39 -0
  186. dolmos-0.1.0/tests/regression/test/SortMismatch.t.sol +213 -0
  187. dolmos-0.1.0/tests/regression/test/StaticContexts.t.sol +72 -0
  188. dolmos-0.1.0/tests/regression/test/StdAssertTest.t.sol +609 -0
  189. dolmos-0.1.0/tests/regression/test/Storage.t.sol +48 -0
  190. dolmos-0.1.0/tests/regression/test/Storage2.t.sol +246 -0
  191. dolmos-0.1.0/tests/regression/test/Storage3.t.sol +118 -0
  192. dolmos-0.1.0/tests/regression/test/Storage4.t.sol +114 -0
  193. dolmos-0.1.0/tests/regression/test/Storage5.t.sol +76 -0
  194. dolmos-0.1.0/tests/regression/test/StorageSlot.t.sol +68 -0
  195. dolmos-0.1.0/tests/regression/test/Store.t.sol +60 -0
  196. dolmos-0.1.0/tests/regression/test/Struct.t.sol +128 -0
  197. dolmos-0.1.0/tests/regression/test/SvmCheatCode.t.sol +951 -0
  198. dolmos-0.1.0/tests/regression/test/SymbolicCall.t.sol +30 -0
  199. dolmos-0.1.0/tests/regression/test/TStore.t.sol +76 -0
  200. dolmos-0.1.0/tests/regression/test/TestConstructor.t.sol +31 -0
  201. dolmos-0.1.0/tests/regression/test/Token.t.sol +59 -0
  202. dolmos-0.1.0/tests/regression/test/UniswapPairAddress.t.sol +92 -0
  203. dolmos-0.1.0/tests/regression/test/UnknownCall.t.sol +81 -0
  204. dolmos-0.1.0/tests/regression/test/UnsupportedOpcode.t.sol +42 -0
  205. dolmos-0.1.0/tests/regression/test/Warp.t.sol +66 -0
  206. dolmos-0.1.0/tests/solver/foundry.toml +10 -0
  207. dolmos-0.1.0/tests/solver/remappings.txt +2 -0
  208. dolmos-0.1.0/tests/solver/test/Math.t.sol +34 -0
  209. dolmos-0.1.0/tests/solver/test/SignedDiv.t.sol +109 -0
  210. dolmos-0.1.0/tests/solver/test/Solver.t.sol +21 -0
  211. dolmos-0.1.0/tests/test_bitvec.py +307 -0
  212. dolmos-0.1.0/tests/test_bytevec.py +734 -0
  213. dolmos-0.1.0/tests/test_cli.py +399 -0
  214. dolmos-0.1.0/tests/test_config.py +447 -0
  215. dolmos-0.1.0/tests/test_dolmos.py +118 -0
  216. dolmos-0.1.0/tests/test_fixtures.py +31 -0
  217. dolmos-0.1.0/tests/test_mapper.py +305 -0
  218. dolmos-0.1.0/tests/test_natspec.py +36 -0
  219. dolmos-0.1.0/tests/test_prank.py +222 -0
  220. dolmos-0.1.0/tests/test_sevm.py +506 -0
  221. dolmos-0.1.0/tests/test_solve.py +112 -0
  222. dolmos-0.1.0/tests/test_source_map.py +119 -0
  223. dolmos-0.1.0/tests/test_traces.py +876 -0
  224. dolmos-0.1.0/tests/test_utils.py +74 -0
  225. dolmos-0.1.0/tests/test_vyper.py +330 -0
  226. dolmos-0.1.0/tests/vyper/foundry.toml +11 -0
  227. dolmos-0.1.0/tests/vyper/remappings.txt +3 -0
  228. dolmos-0.1.0/tests/vyper/src/Counter.vy +15 -0
  229. dolmos-0.1.0/tests/vyper/src/Immutable.vy +14 -0
  230. dolmos-0.1.0/tests/vyper/src/Vault.vy +21 -0
  231. dolmos-0.1.0/tests/vyper/test/CounterTest.vy +71 -0
  232. dolmos-0.1.0/tests/vyper/test/VyperTarget.t.sol +70 -0
@@ -0,0 +1,3 @@
1
+ # Migrate code style to Black
2
+ 449404c7a2b318b8203dbccbeac11c87d20c422f
3
+ 00cc14c20659cbf717594451dfc7906b295dca98
@@ -0,0 +1,36 @@
1
+ # Byte-compiled / optimized
2
+ __pycache__/
3
+
4
+ # Distribution / packaging
5
+ *.egg-info/
6
+
7
+ # Pyre type checker
8
+ .pyre/
9
+
10
+ # Vim tmp files:
11
+ *~
12
+ *.swp
13
+ *.swo
14
+
15
+ # Environments
16
+ /.env
17
+ .venv*
18
+ env/
19
+ venv/
20
+
21
+ # Foundry build files
22
+ cache/
23
+ out/
24
+
25
+ # VS Code
26
+ .vscode/
27
+
28
+ # https://docs.astral.sh/uv/concepts/projects/layout/#the-lockfile
29
+ # we go against the recommended best practice and don't add it to source control:
30
+ # - adds too much noise
31
+ # - adds friction to CI
32
+ # (at the cost of reproducible builds)
33
+ uv.lock
34
+
35
+ # https://docs.astral.sh/uv/concepts/projects/layout/#the-build-directory
36
+ build/
@@ -0,0 +1,15 @@
1
+ [submodule "tests/lib/forge-std"]
2
+ path = tests/lib/forge-std
3
+ url = https://github.com/foundry-rs/forge-std
4
+ [submodule "tests/lib/halmos-cheatcodes"]
5
+ path = tests/lib/halmos-cheatcodes
6
+ url = https://github.com/a16z/halmos-cheatcodes
7
+ [submodule "tests/lib/openzeppelin-contracts"]
8
+ path = tests/lib/openzeppelin-contracts
9
+ url = https://github.com/OpenZeppelin/openzeppelin-contracts
10
+ [submodule "tests/lib/solmate"]
11
+ path = tests/lib/solmate
12
+ url = https://github.com/transmissions11/solmate
13
+ [submodule "tests/lib/solady"]
14
+ path = tests/lib/solady
15
+ url = https://github.com/Vectorized/solady
@@ -0,0 +1,13 @@
1
+ repos:
2
+
3
+ - repo: https://github.com/astral-sh/ruff-pre-commit
4
+ # Ruff version.
5
+ rev: v0.6.2
6
+ hooks:
7
+ # Run the linter.
8
+ - id: ruff
9
+ # don't autofix by default, this runs in CI
10
+ # to run fix locally, use `ruff check src/ --fix`
11
+ # args: [ --fix ]
12
+ # Run the formatter.
13
+ - id: ruff-format
@@ -0,0 +1 @@
1
+ pip install -e ".[dev]"
@@ -0,0 +1,41 @@
1
+ # Changelog
2
+
3
+ All notable changes to dolmos are documented here. The format follows
4
+ [Keep a Changelog](https://keepachangelog.com/en/1.1.0/) and versions follow
5
+ [Semantic Versioning](https://semver.org/). Dolmos is derived from halmos; see
6
+ [NOTICE](NOTICE) for the upstream commit it is based on.
7
+
8
+ ## [Unreleased]
9
+
10
+ ## [0.1.0] - 2026-09-22
11
+
12
+ First release of dolmos.
13
+
14
+ ### Added
15
+
16
+ - CREATE address derivation from `keccak256(rlp([sender, nonce]))` and account
17
+ nonces (EIP-161), so that CREATE3-style address prediction matches execution
18
+ - nonce cheatcodes: `vm.getNonce`, `vm.setNonce`, `vm.setNonceUnsafe`,
19
+ `vm.resetNonce`
20
+ - opcodes `CLZ` (EIP-7939), `BLOBHASH` and `BLOBBASEFEE` (EIP-4844)
21
+ - experimental Vyper support: Vyper test contracts, Solidity tests targeting
22
+ Vyper contracts, `@custom:dolmos` annotations in docstrings,
23
+ `--invalid-as-failure`
24
+ - `dolmos.toml` configuration file and `@custom:dolmos` annotations
25
+ (`halmos.toml`, `@custom:halmos` and `HALMOS_ALLOW_DOWNLOAD` remain accepted)
26
+ - PyPI package and Docker image `ghcr.io/dowsers/dolmos`
27
+
28
+ ### Changed
29
+
30
+ - command, Python package and symbolic variable prefix renamed from `halmos` to
31
+ `dolmos`; downloaded solvers are cached in `~/.dolmos/solvers`
32
+
33
+ ### Fixed
34
+
35
+ - Vyper artifact lookup in the forge cache on Windows
36
+ - builds with forge ≥ 1.8: `dynamic_test_linking` is disabled when dolmos runs
37
+ `forge build`, since it rewrites `new C()` into unsupported `vm.deployCode`
38
+ calls
39
+
40
+ [Unreleased]: https://github.com/Dowsers/dolmos/compare/v0.1.0...HEAD
41
+ [0.1.0]: https://github.com/Dowsers/dolmos/releases/tag/v0.1.0
@@ -0,0 +1,94 @@
1
+ # Contributing to dolmos
2
+
3
+ Bug reports, suggestions and pull requests are welcome on
4
+ [GitHub](https://github.com/Dowsers/dolmos/issues).
5
+
6
+ ## Development Setup
7
+
8
+ Clone or fork the repository:
9
+
10
+ ```sh
11
+ # if you want to submit a pull request, fork the repository:
12
+ gh repo fork Dowsers/dolmos
13
+
14
+ # Or, if you just want to develop locally, clone it:
15
+ git clone git@github.com:Dowsers/dolmos.git
16
+
17
+ # navigate to the project directory
18
+ cd dolmos
19
+ ```
20
+
21
+ **Recommended**: set up the development environment using [uv](https://docs.astral.sh/uv/):
22
+
23
+ ```sh
24
+ # install uv
25
+ curl -LsSf https://astral.sh/uv/install.sh | sh
26
+
27
+ # this does a lot of things:
28
+ # - install a suitable python version if one is not found
29
+ # - create a virtual environment in `.venv`
30
+ # - install the main dependencies
31
+ # - install the development dependencies
32
+ # - generates a `uv.lock` file
33
+ uv sync --extra dev
34
+
35
+ # install and run the pre-commit hooks
36
+ uv run pre-commit install
37
+ uv run pre-commit run --all-files
38
+
39
+ # make changes to dolmos, then run it with:
40
+ uv run dolmos
41
+
42
+ # run the tests with:
43
+ uv run pytest
44
+
45
+ # add a dependency to the project:
46
+ uv add <dependency>
47
+
48
+ # remove a dependency from the project:
49
+ uv remove <dependency>
50
+
51
+ # update a dependency to the latest version:
52
+ uv lock --upgrade-package <dependency>
53
+
54
+ # to manually update the environment and activate it:
55
+ uv sync
56
+ source .venv/bin/activate
57
+ ```
58
+
59
+ Alternatively, you can manage the python version and the virtual environment manually using `pip` (not recommended for most users):
60
+
61
+ ```sh
62
+ # create and activate a virtual environment with a suitable python version
63
+ python3.12 -m venv .venv && source .venv/bin/activate
64
+
65
+ # install dolmos and its runtime dependencies in editable mode
66
+ python -m pip install -e ".[dev]"
67
+
68
+ # install and run the pre-commit hooks
69
+ pre-commit install
70
+ pre-commit run --all-files
71
+ ```
72
+
73
+
74
+ ## Coding Style
75
+
76
+ We recommend enabling the [ruff] formatter in your editor, but you can run it manually if needed:
77
+
78
+ ```sh
79
+ python -m ruff check src/
80
+ ```
81
+
82
+ [ruff]: <https://docs.astral.sh/ruff/>
83
+
84
+ ## GitHub Codespace
85
+
86
+ A pre-configured development environment is available as a GitHub Codespaces dev container.
87
+
88
+ ## License
89
+
90
+ By contributing, you agree that your contributions will be licensed under its [AGPL-3.0](LICENSE) License.
91
+
92
+ ## Disclaimer
93
+
94
+ See the disclaimer in the [README](README.md#disclaimer).