Guest User

output with added entrypoints

a guest
Oct 2nd, 2020
227
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. (venv) $ poetry run python3 test_collatz.py
  3. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-node identity generate 0.0 --data-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-node.yjix8m0s
  4. Generating a new identity... (level: 0.00)
  5. Stored the new identity (idrLg1w9z8txLUANcH7yJ5XzLiEsGh) into '/var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-node.yjix8m0s/identity.json'.
  6.  
  7. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-node config init --data-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-node.yjix8m0s --net-addr 127.0.0.1:19730 --rpc-addr 127.0.0.1:18730 --expected-pow 0.0 --connections 500 --bootstrap-threshold 0 --private-mode --network sandbox
  8. Created /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-node.yjix8m0s/config.json for network: sandbox.
  9.  
  10. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-node run --data-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-node.yjix8m0s --no-bootstrap-peers --connections 500 --bootstrap-threshold 0 --private-mode --network sandbox --peer 127.0.0.1:19730 --peer 127.0.0.1:19731 --peer 127.0.0.1:19732 --peer 127.0.0.1:19733 --peer 127.0.0.1:19734 --peer 127.0.0.1:19735 --peer 127.0.0.1:19736 --peer 127.0.0.1:19737 --peer 127.0.0.1:19738 --peer 127.0.0.1:19739 --peer 127.0.0.1:19740 --peer 127.0.0.1:19741 --peer 127.0.0.1:19742 --peer 127.0.0.1:19743 --peer 127.0.0.1:19744 --peer 127.0.0.1:19745 --peer 127.0.0.1:19746 --peer 127.0.0.1:19747 --peer 127.0.0.1:19748 --peer 127.0.0.1:19749 --peer 127.0.0.1:19750 --peer 127.0.0.1:19751 --peer 127.0.0.1:19752 --peer 127.0.0.1:19753 --peer 127.0.0.1:19754 --peer 127.0.0.1:19755 --peer 127.0.0.1:19756 --peer 127.0.0.1:19757 --peer 127.0.0.1:19758 --peer 127.0.0.1:19759 --peer 127.0.0.1:19760 --peer 127.0.0.1:19761 --peer 127.0.0.1:19762 --peer 127.0.0.1:19763 --peer 127.0.0.1:19764 --peer 127.0.0.1:19765 --peer 127.0.0.1:19766 --peer 127.0.0.1:19767 --peer 127.0.0.1:19768 --peer 127.0.0.1:19769 --peer 127.0.0.1:19770 --peer 127.0.0.1:19771 --peer 127.0.0.1:19772 --peer 127.0.0.1:19773 --peer 127.0.0.1:19774
  11. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 rpc get /network/version
  12. { "chain_name": "TEZOS", "distributed_db_version": 0, "p2p_version": 1 }
  13.  
  14. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 -w none config update
  15. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key bootstrap1 unencrypted:edsk3gUfUPyBSfrS9CCgmCiQsTCHGkviBDusMxDJstFtojtc1zcpsh
  16. Tezos address added: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  17.  
  18. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key bootstrap2 unencrypted:edsk39qAm1fiMjgmPkw1EgQYkMzkJezLNewd7PLNHTkr6w9XA2zdfo
  19. Tezos address added: tz1gjaF81ZRRvdzjobyfVNsAeSC6PScjfQwN
  20.  
  21. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key bootstrap3 unencrypted:edsk4ArLQgBTLWG5FJmnGnT689VKoqhXwmDPBuGx3z4cvwU9MmrPZZ
  22. Tezos address added: tz1faswCTDciRzE4oJ9jn2Vm2dvjeyA9fUzU
  23.  
  24. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key bootstrap4 unencrypted:edsk2uqQB9AY4FvioK2YMdfmyMrer5R8mGFyuaLLFfSRo8EoyNdht3
  25. Tezos address added: tz1b7tUupMgCNw2cCLpKTkSD1NZzB5TkP2sv
  26.  
  27. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key bootstrap5 unencrypted:edsk4QLrcijEffxV31gGdN2HU7UpyJjA8drFoNcmnB28n89YjPNRFm
  28. Tezos address added: tz1ddb9NMYHZi5UzPdzTZMYQQZoMub195zgv
  29.  
  30. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key baker1_key unencrypted:edsk432L71B91i1sE8rQxPDMo2Yxo4qaYqhktvpt8yovaMpo1NUbBt
  31. Tezos address added: tz1UJbFsTQfdpa1qYrqHG9Ykw834AXi5WqRR
  32.  
  33. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key baker2_key unencrypted:edsk3jjD4cLvE1t3SiZKCRiH9SXnJ4jHEsVpfcuRwfe7sfbnsMGX6f
  34. Tezos address added: tz1fWJ2oeeG6h2r61XY1wen2sV87AvCqGjAU
  35.  
  36. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key baker3_key unencrypted:edsk3EVDFeDsefk1UoWWhDhnBpERhAwqHbVzWnBwA4tdUL8aBhw7RC
  37. Tezos address added: tz1SERFDUknkjJTas8sUco7dskxWrUWhTc2s
  38.  
  39. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key baker4_key unencrypted:edsk2rAmeBDrQ5d1FhDoTdifMvBsqSosmPSBhxL74huszZhfMFtiKb
  40. Tezos address added: tz1eJ9yR95LmJgVrGLvgt56T6ngCFcgjLo2S
  41.  
  42. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key baker5_key unencrypted:edsk4Ssc63dnYJUptVMaKfmHLJNMBYv9piYiRCiYjcH3gacKWP1z3v
  43. Tezos address added: tz1cwoRFe3BzJv9nZZBA5fk8uV6w9AVVrBF9
  44.  
  45. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 import secret key activator unencrypted:edsk31vznjHSSpGExDMHYASz45VZqXN4DPxvsa4hAyY8dHM28cZzp6
  46. Tezos address added: tz1TGu6TN5GSez2ndXXeDX6LgUDvLzPLqgYV
  47.  
  48. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 -block genesis activate protocol ProtoALphaALphaALphaALphaALphaALphaALphaALphaDdp3zK with fitness 1 and key activator and parameters /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tmpwr4b5py9 --timestamp 2020-10-02T21:04:39Z
  49. Injected BMGfDqvjivHr
  50.  
  51. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 remember contract baker1 SG1fpFaowYY8G7PfkYdKkGmsMziHKUfrHRHW
  52. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 remember contract baker2 SG1TLmKJHVJxQosY6iN21AW77HsAapdupxnR
  53. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 remember contract baker3 SG1hExdK69Z2RZkkQjKtLG6H4L4FGTZeGKHu
  54. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 remember contract baker4 SG1mHgeWHGMnCUMJ8jZ1Cdh3DkWEcQ88tziJ
  55. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 remember contract baker5 SG1jfZeHRzeWAM1T4zrwunEyUpwWc82D4tbv
  56. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-baker-alpha -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://127.0.0.1:18730 run with local node /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-node.yjix8m0s baker5
  57. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 originate contract even_contract transferring 0 from bootstrap1 running collatz_even.tz --init Unit --burn-cap 9
  58. Node is bootstrapped.
  59. Estimated gas: 16375000 units (will add 100000 for safety)
  60. Estimated storage: 497 bytes added (will add 20 for safety)
  61. Operation successfully injected in the node.
  62. Operation hash is 'onsxWPNk6SAiAL4DuoCA3AwSSvKY8eAeGtxg9aFPajCueodnWmw'
  63. NOT waiting for the operation to be included.
  64. Use command
  65. tezos-client wait for onsxWPNk6SAiAL4DuoCA3AwSSvKY8eAeGtxg9aFPajCueodnWmw to be included --confirmations 30 --branch BLhXb69MJbGaovkHTXFuk1znRZJAzwNrNtyRgv7ci7uZFQhw4MV
  66. and/or an external block explorer to make sure that it has been included.
  67. This sequence of operations was run:
  68. Manager signed operations:
  69. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  70. Fee to the baker: ꜩ0.002117
  71. Expected counter: 1
  72. Gas limit: 16475000
  73. Storage limit: 517 bytes
  74. Balance updates:
  75. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ................ -ꜩ0.002117
  76. fees(the baker who will include this operation,0) ... +ꜩ0.002117
  77. Origination:
  78. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  79. Credit: ꜩ0
  80. Script:
  81. { parameter
  82. (or (pair %dummyEven (contract %k nat) (nat %x))
  83. (pair %runEven (contract %k nat) (nat %x))) ;
  84. storage unit ;
  85. code { DUP ;
  86. CDR ;
  87. SWAP ;
  88. CAR ;
  89. IF_LEFT
  90. { DUP ;
  91. CAR ;
  92. NIL operation ;
  93. SWAP ;
  94. PUSH mutez 0 ;
  95. PUSH nat 4 ;
  96. DIG 4 ;
  97. CDR ;
  98. EDIV ;
  99. IF_SOME { CAR } { PUSH int 18 ; FAILWITH } ;
  100. TRANSFER_TOKENS ;
  101. CONS }
  102. { DUP ;
  103. CAR ;
  104. NIL operation ;
  105. SWAP ;
  106. PUSH mutez 0 ;
  107. PUSH nat 2 ;
  108. DIG 4 ;
  109. CDR ;
  110. EDIV ;
  111. IF_SOME { CAR } { PUSH int 14 ; FAILWITH } ;
  112. TRANSFER_TOKENS ;
  113. CONS } ;
  114. PAIR } }
  115. Initial storage: Unit
  116. No delegate for this contract
  117. This origination was successfully applied
  118. Originated contracts:
  119. KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY
  120. Storage size: 240 bytes
  121. Paid storage size diff: 240 bytes
  122. Consumed gas: 16375000
  123. Balance updates:
  124. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ... -ꜩ0.24
  125. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ... -ꜩ0.257
  126.  
  127. New contract KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY originated.
  128. Contract memorized as even_contract.
  129.  
  130. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 bake for baker5 --minimal-timestamp
  131. Injected block BL1xj3jJJWja
  132.  
  133. Oct 2 22:04:48.039 - alpha.baking.forge: found 1 valid operations (0 refused) for timestamp 2020-10-02T21:04:49-00:00 (fitness 01::0000000000000005)
  134.  
  135. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 originate contract odd_contract transferring 0 from bootstrap1 running collatz_odd.tz --init Unit --burn-cap 9
  136. Node is bootstrapped.
  137. Estimated gas: 15581000 units (will add 100000 for safety)
  138. Estimated storage: 457 bytes added (will add 20 for safety)
  139. Operation successfully injected in the node.
  140. Operation hash is 'onzf7JsCbaDf7eGBof17hDEYo2SN3jUBTpKzGGAxapi7ZRxFzRv'
  141. NOT waiting for the operation to be included.
  142. Use command
  143. tezos-client wait for onzf7JsCbaDf7eGBof17hDEYo2SN3jUBTpKzGGAxapi7ZRxFzRv to be included --confirmations 30 --branch BL1xj3jJJWjaGkLxee51jEzPXpwGMpsqFNjXEdwYPjSDQtuGNwD
  144. and/or an external block explorer to make sure that it has been included.
  145. This sequence of operations was run:
  146. Manager signed operations:
  147. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  148. Fee to the baker: ꜩ0.001998
  149. Expected counter: 2
  150. Gas limit: 15681000
  151. Storage limit: 477 bytes
  152. Balance updates:
  153. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ................ -ꜩ0.001998
  154. fees(the baker who will include this operation,0) ... +ꜩ0.001998
  155. Origination:
  156. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  157. Credit: ꜩ0
  158. Script:
  159. { parameter
  160. (or (pair %dummyOdd (contract %k int) (int %x))
  161. (pair %runOdd (contract %k int) (int %x))) ;
  162. storage unit ;
  163. code { DUP ;
  164. CDR ;
  165. SWAP ;
  166. CAR ;
  167. IF_LEFT
  168. { DUP ;
  169. CAR ;
  170. NIL operation ;
  171. SWAP ;
  172. PUSH mutez 0 ;
  173. PUSH int 5 ;
  174. DIG 4 ;
  175. CDR ;
  176. PUSH int 3 ;
  177. MUL ;
  178. ADD ;
  179. TRANSFER_TOKENS ;
  180. CONS }
  181. { DUP ;
  182. CAR ;
  183. NIL operation ;
  184. SWAP ;
  185. PUSH mutez 0 ;
  186. PUSH int 1 ;
  187. DIG 4 ;
  188. CDR ;
  189. PUSH int 3 ;
  190. MUL ;
  191. ADD ;
  192. TRANSFER_TOKENS ;
  193. CONS } ;
  194. PAIR } }
  195. Initial storage: Unit
  196. No delegate for this contract
  197. This origination was successfully applied
  198. Originated contracts:
  199. KT1EynUKUtkgGqj1ds53mvz4fr7YUnBNUpZV
  200. Storage size: 200 bytes
  201. Paid storage size diff: 200 bytes
  202. Consumed gas: 15581000
  203. Balance updates:
  204. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ... -ꜩ0.2
  205. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ... -ꜩ0.257
  206.  
  207. New contract KT1EynUKUtkgGqj1ds53mvz4fr7YUnBNUpZV originated.
  208. Contract memorized as odd_contract.
  209.  
  210. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 bake for baker5 --minimal-timestamp
  211. Injected block BM7CPGtWprnw
  212.  
  213. Oct 2 22:04:48.840 - alpha.baking.forge: found 1 valid operations (0 refused) for timestamp 2020-10-02T21:04:51-00:00 (fitness 01::0000000000000006)
  214.  
  215. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 show known contract even_contract
  216. KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY
  217.  
  218.  
  219. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 show known contract odd_contract
  220. KT1EynUKUtkgGqj1ds53mvz4fr7YUnBNUpZV
  221.  
  222.  
  223. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 originate contract main_contract transferring 0 from bootstrap1 running collatz_main.tz --init (Pair 0 (Pair "KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY" "KT1EynUKUtkgGqj1ds53mvz4fr7YUnBNUpZV")) --burn-cap 9
  224. Node is bootstrapped.
  225. Estimated gas: 25158000 units (will add 100000 for safety)
  226. Estimated storage: 860 bytes added (will add 20 for safety)
  227. Operation successfully injected in the node.
  228. Operation hash is 'oojpavAZESETCufK3YRx1tc14auEYBEHsg3h3vnjcttnuyf9MXU'
  229. NOT waiting for the operation to be included.
  230. Use command
  231. tezos-client wait for oojpavAZESETCufK3YRx1tc14auEYBEHsg3h3vnjcttnuyf9MXU to be included --confirmations 30 --branch BM7CPGtWprnwQuSktiRGPdx3ZAKBirM8178V1pMdNhYh3EwUzLk
  232. and/or an external block explorer to make sure that it has been included.
  233. This sequence of operations was run:
  234. Manager signed operations:
  235. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  236. Fee to the baker: ꜩ0.003386
  237. Expected counter: 3
  238. Gas limit: 25258000
  239. Storage limit: 880 bytes
  240. Balance updates:
  241. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ................ -ꜩ0.003386
  242. fees(the baker who will include this operation,0) ... +ꜩ0.003386
  243. Origination:
  244. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  245. Credit: ꜩ0
  246. Script:
  247. { parameter (or (unit %reset) (nat %run)) ;
  248. storage (pair (int %counter) (pair (address %onEven) (address %onOdd))) ;
  249. code { DUP ;
  250. CDR ;
  251. SWAP ;
  252. CAR ;
  253. IF_LEFT
  254. { DROP ; CDR ; PUSH int 0 ; PAIR ; NIL operation }
  255. { DUP ;
  256. PUSH nat 1 ;
  257. COMPARE ;
  258. LT ;
  259. IF { SWAP ;
  260. DUP ;
  261. CDR ;
  262. SWAP ;
  263. CAR ;
  264. PUSH int 1 ;
  265. ADD ;
  266. PAIR ;
  267. SWAP ;
  268. PUSH nat 0 ;
  269. PUSH nat 2 ;
  270. DIG 2 ;
  271. DUP ;
  272. DUG 3 ;
  273. EDIV ;
  274. IF_SOME { CDR } { PUSH int 47 ; FAILWITH } ;
  275. COMPARE ;
  276. EQ ;
  277. IF { NIL operation ;
  278. DIG 2 ;
  279. DUP ;
  280. DUG 3 ;
  281. CDAR ;
  282. CONTRACT %runEven (pair (contract %k nat) (nat %x)) ;
  283. IF_SOME {} { PUSH int 39 ; FAILWITH } ;
  284. PUSH mutez 0 ;
  285. DIG 3 ;
  286. SELF ;
  287. ADDRESS ;
  288. CONTRACT %run nat ;
  289. IF_SOME {} { PUSH int 41 ; FAILWITH } ;
  290. PAIR %k %x ;
  291. TRANSFER_TOKENS ;
  292. CONS }
  293. { NIL operation ;
  294. DIG 2 ;
  295. DUP ;
  296. DUG 3 ;
  297. CDDR ;
  298. CONTRACT %runOdd (pair (contract %k nat) (nat %x)) ;
  299. IF_SOME {} { PUSH int 40 ; FAILWITH } ;
  300. PUSH mutez 0 ;
  301. DIG 3 ;
  302. SELF ;
  303. ADDRESS ;
  304. CONTRACT %run nat ;
  305. IF_SOME {} { PUSH int 41 ; FAILWITH } ;
  306. PAIR %k %x ;
  307. TRANSFER_TOKENS ;
  308. CONS } }
  309. { DROP ; NIL operation } } ;
  310. PAIR } }
  311. Initial storage:
  312. (Pair 0
  313. (Pair "KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY" "KT1EynUKUtkgGqj1ds53mvz4fr7YUnBNUpZV"))
  314. No delegate for this contract
  315. This origination was successfully applied
  316. Originated contracts:
  317. KT19iXxzBHsnGsbqJZhQ1pMWNoLQSXiTBB2i
  318. Storage size: 603 bytes
  319. Paid storage size diff: 603 bytes
  320. Consumed gas: 25158000
  321. Balance updates:
  322. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ... -ꜩ0.603
  323. tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx ... -ꜩ0.257
  324.  
  325. New contract KT19iXxzBHsnGsbqJZhQ1pMWNoLQSXiTBB2i originated.
  326. Contract memorized as main_contract.
  327.  
  328. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 bake for baker5 --minimal-timestamp
  329. Injected block BLHcPS1Yqnv8
  330.  
  331. Oct 2 22:04:50.364 - alpha.baking.forge: found 1 valid operations (0 refused) for timestamp 2020-10-02T21:04:53-00:00 (fitness 01::0000000000000007)
  332.  
  333. # /Users/dariuscognac/Documents/GitHub/tezos/tezos-client -base-dir /var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0 -endpoint http://localhost:18730 transfer 0 from bootstrap1 to main_contract --entrypoint run --burn-cap 9 --arg 42
  334. Node is bootstrapped.
  335. This simulation failed:
  336. Manager signed operations:
  337. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  338. Fee to the baker: ꜩ0
  339. Expected counter: 4
  340. Gas limit: 1040000000
  341. Storage limit: 60000 bytes
  342. Transaction:
  343. Amount: ꜩ0
  344. From: tz1KqTpEZ7Yob7QbPE4Hy4Wo8fHG8LhKxZSx
  345. To: KT19iXxzBHsnGsbqJZhQ1pMWNoLQSXiTBB2i
  346. Entrypoint: run
  347. Parameter: 42
  348. This transaction was BACKTRACKED, its expected effects (as follow) were NOT applied.
  349. Updated storage:
  350. (Pair 1
  351. (Pair 0x011bf36ba2b2a7fd703cbaae2a98fa91cd9efe756100
  352. 0x01462b1405048e565d35705213838f2a58bd479fc700))
  353. Storage size: 603 bytes
  354. Consumed gas: 55346638
  355. Internal operations:
  356. Transaction:
  357. Amount: ꜩ0
  358. From: KT19iXxzBHsnGsbqJZhQ1pMWNoLQSXiTBB2i
  359. To: KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY
  360. Entrypoint: runEven
  361. Parameter: (Pair 0x010c7019e012d694bf115c1c054498aeca7b0766520072756e 42)
  362. This transaction was BACKTRACKED, its expected effects (as follow) were NOT applied.
  363. Updated storage: Unit
  364. Storage size: 240 bytes
  365. Consumed gas: 23707328
  366. Transaction:
  367. Amount: ꜩ0
  368. From: KT1B8ZR6RTEaNsgvPwWrcNCqEbrHSATU56JY
  369. To: KT19iXxzBHsnGsbqJZhQ1pMWNoLQSXiTBB2i
  370. Entrypoint: run
  371. Parameter: 21
  372. This operation FAILED.
  373.  
  374.  
  375. Runtime error in contract KT19iXxzBHsnGsbqJZhQ1pMWNoLQSXiTBB2i:
  376. 01: { parameter (or (unit %reset) (nat %run)) ;
  377. 02: storage (pair (int %counter) (pair (address %onEven) (address %onOdd))) ;
  378. 03: code { DUP ;
  379. 04: CDR ;
  380. 05: SWAP ;
  381. 06: CAR ;
  382. 07: IF_LEFT
  383. 08: { DROP ; CDR ; PUSH int 0 ; PAIR ; NIL operation }
  384. 09: { DUP ;
  385. 10: PUSH nat 1 ;
  386. 11: COMPARE ;
  387. 12: LT ;
  388. 13: IF { SWAP ;
  389. 14: DUP ;
  390. 15: CDR ;
  391. 16: SWAP ;
  392. 17: CAR ;
  393. 18: PUSH int 1 ;
  394. 19: ADD ;
  395. 20: PAIR ;
  396. 21: SWAP ;
  397. 22: PUSH nat 0 ;
  398. 23: PUSH nat 2 ;
  399. 24: DIG 2 ;
  400. 25: DUP ;
  401. 26: DUG 3 ;
  402. 27: EDIV ;
  403. 28: IF_SOME { CDR } { PUSH int 47 ; FAILWITH } ;
  404. 29: COMPARE ;
  405. 30: EQ ;
  406. 31: IF { NIL operation ;
  407. 32: DIG 2 ;
  408. 33: DUP ;
  409. 34: DUG 3 ;
  410. 35: CDAR ;
  411. 36: CONTRACT %runEven (pair (contract %k nat) (nat %x)) ;
  412. 37: IF_SOME {} { PUSH int 39 ; FAILWITH } ;
  413. 38: PUSH mutez 0 ;
  414. 39: DIG 3 ;
  415. 40: SELF ;
  416. 41: ADDRESS ;
  417. 42: CONTRACT %run nat ;
  418. 43: IF_SOME {} { PUSH int 41 ; FAILWITH } ;
  419. 44: PAIR %k %x ;
  420. 45: TRANSFER_TOKENS ;
  421. 46: CONS }
  422. 47: { NIL operation ;
  423. 48: DIG 2 ;
  424. 49: DUP ;
  425. 50: DUG 3 ;
  426. 51: CDDR ;
  427. 52: CONTRACT %runOdd (pair (contract %k nat) (nat %x)) ;
  428. 53: IF_SOME {} { PUSH int 40 ; FAILWITH } ;
  429. 54: PUSH mutez 0 ;
  430. 55: DIG 3 ;
  431. 56: SELF ;
  432. 57: ADDRESS ;
  433. 58: CONTRACT %run nat ;
  434. 59: IF_SOME {} { PUSH int 41 ; FAILWITH } ;
  435. 60: PAIR %k %x ;
  436. 61: TRANSFER_TOKENS ;
  437. 62: CONS } }
  438. 63: { DROP ; NIL operation } } ;
  439. 64: PAIR } }
  440. At line 53 characters 50 to 58,
  441. script reached FAILWITH instruction
  442. with 40
  443. Fatal error:
  444. transfer simulation failed
  445.  
  446. Traceback (most recent call last):
  447. File "test_collatz.py", line 64, in <module>
  448. scenario_basic_call()
  449. File "test_collatz.py", line 58, in scenario_basic_call
  450. '--arg', '42'])
  451. File "/Users/dariuscognac/Documents/GitHub/tezos/tests_python/client/client.py", line 384, in transfer
  452. res = self.run(cmd)
  453. File "/Users/dariuscognac/Documents/GitHub/tezos/tests_python/client/client.py", line 164, in run
  454. (stdout, _, _) = self.run_generic(params, admin, check, trace)
  455. File "/Users/dariuscognac/Documents/GitHub/tezos/tests_python/client/client.py", line 153, in run_generic
  456. completed_process.check_returncode()
  457. File "/Users/dariuscognac/anaconda3/lib/python3.7/subprocess.py", line 409, in check_returncode
  458. self.stderr)
  459. subprocess.CalledProcessError: Command '['/Users/dariuscognac/Documents/GitHub/tezos/tezos-client', '-base-dir', '/var/folders/r5/yk8yg2xs1gs8xzkn5l8vr72w0000gn/T/tezos-client.058sgjc0', '-endpoint', 'http://localhost:18730', 'transfer', '0', 'from', 'bootstrap1', 'to', 'main_contract', '--entrypoint', 'run', '--burn-cap', '9', '--arg', '42']' returned non-zero exit status 1.
  460. (venv) $
RAW Paste Data