Skip to content

Commit

Permalink
fix: test order subscription
Browse files Browse the repository at this point in the history
  • Loading branch information
annasambrook committed Dec 2, 2024
1 parent f209483 commit 9c2d330
Show file tree
Hide file tree
Showing 10 changed files with 25 additions and 21 deletions.
14 changes: 7 additions & 7 deletions packages/packages.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,15 @@
"contract/valory/mech_activity/0.1.0": "bafybeibmqmle5fnal3gxlpdmcos2kogzra4q3pr3o5nh7shplxuilji3t4",
"contract/valory/staking_token/0.1.0": "bafybeiep4r6qyilbfgzdvx6t7zvpgaioxqktmxm7puwtnbpb2ftlib43gy",
"contract/valory/relayer/0.1.0": "bafybeicawmds6czx7db2lcktvexwrp245jpekgulndtos5s5zdid3ilvq4",
"skill/valory/market_manager_abci/0.1.0": "bafybeicztk62pslofv6ui3aw3giw2tnvlfwfmatqbyvvzv4ampneu6isqa",
"skill/valory/decision_maker_abci/0.1.0": "bafybeihnflr5sfvdcahviwb6jleevxlzuqrijwvs3abrguvbrn34rti4oa",
"skill/valory/trader_abci/0.1.0": "bafybeigdgggk3ghy46x65ky5c76fy7mci3iniq22dd6uutdunzqj6yazlq",
"skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeigaunkiw3ek3xrmxt35v62o3mohwpq7gbx6mdybebta5rq65c7jju",
"skill/valory/market_manager_abci/0.1.0": "bafybeigmea7hrb42fj5v6pwjzww3vibvoov5qd7raiv5didzvrikxs242i",
"skill/valory/decision_maker_abci/0.1.0": "bafybeigsrmbaalqtl3moyrpiv4sl2pse5cxmqy56rxco3x3gkdnt4d3gii",
"skill/valory/trader_abci/0.1.0": "bafybeicnqymssye7iunnxdeodxv7frjgizlqxv65a32me5ms7hcq5vkhge",
"skill/valory/tx_settlement_multiplexer_abci/0.1.0": "bafybeianqmo466ksztcqsw2hhxw3yl3afto6okfjyy2ot6a34krez6acwq",
"skill/valory/staking_abci/0.1.0": "bafybeictd5pxhscuhqntvctb7l5lfjausxt2m22rg5mkaiuj4cwwcxpvne",
"skill/valory/check_stop_trading_abci/0.1.0": "bafybeib75qrimmvensqmskdp5kzki5ijjwolqk2ojekeommakaf64mzn54",
"agent/valory/trader/0.1.0": "bafybeibqjelcx6ls2ezwembpxzemgvths3ebbt6oqr32v4eln437ulwspq",
"service/valory/trader/0.1.0": "bafybeiexftzugkvbxq4iw26mp4ct72pwysodyym54sg3xqbttgs5yagiey",
"service/valory/trader_pearl/0.1.0": "bafybeiabzfl6duoy3rksaara6fjdly5eunxs3upbckuwdspn6etx5ju6eu"
"agent/valory/trader/0.1.0": "bafybeibxruliur6cpcgsepjw7o63pabbhmlezomjovjpd6tmnetwtxyt6u",
"service/valory/trader/0.1.0": "bafybeibl2vxhbzbwunwspiesx6hsgveeojxdscye36hscndx4zzb57xb6q",
"service/valory/trader_pearl/0.1.0": "bafybeiby7h7va27ycecfef6l3e2xsnzhsc7iemdn3v2trt456grk7dkupu"
},
"third_party": {
"protocol/open_aea/signing/1.0.0": "bafybeihv62fim3wl2bayavfcg3u5e5cxu3b7brtu4cn5xoxd6lqwachasi",
Expand Down
8 changes: 4 additions & 4 deletions packages/valory/agents/trader/aea-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ skills:
- valory/reset_pause_abci:0.1.0:bafybeigrdlxed3xlsnxtjhnsbl3cojruihxcqx4jxhgivkd5i2fkjncgba
- valory/termination_abci:0.1.0:bafybeib5l7jhew5ic6iq24dd23nidcoimzqkrk556gqywhoziatj33zvwm
- valory/transaction_settlement_abci:0.1.0:bafybeic7q7recyka272udwcupblwbkc3jkodgp74fvcdxb7urametg5dae
- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigaunkiw3ek3xrmxt35v62o3mohwpq7gbx6mdybebta5rq65c7jju
- valory/market_manager_abci:0.1.0:bafybeicztk62pslofv6ui3aw3giw2tnvlfwfmatqbyvvzv4ampneu6isqa
- valory/decision_maker_abci:0.1.0:bafybeihnflr5sfvdcahviwb6jleevxlzuqrijwvs3abrguvbrn34rti4oa
- valory/trader_abci:0.1.0:bafybeigdgggk3ghy46x65ky5c76fy7mci3iniq22dd6uutdunzqj6yazlq
- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeianqmo466ksztcqsw2hhxw3yl3afto6okfjyy2ot6a34krez6acwq
- valory/market_manager_abci:0.1.0:bafybeigmea7hrb42fj5v6pwjzww3vibvoov5qd7raiv5didzvrikxs242i
- valory/decision_maker_abci:0.1.0:bafybeigsrmbaalqtl3moyrpiv4sl2pse5cxmqy56rxco3x3gkdnt4d3gii
- valory/trader_abci:0.1.0:bafybeicnqymssye7iunnxdeodxv7frjgizlqxv65a32me5ms7hcq5vkhge
- valory/staking_abci:0.1.0:bafybeictd5pxhscuhqntvctb7l5lfjausxt2m22rg5mkaiuj4cwwcxpvne
- valory/check_stop_trading_abci:0.1.0:bafybeib75qrimmvensqmskdp5kzki5ijjwolqk2ojekeommakaf64mzn54
- valory/mech_interact_abci:0.1.0:bafybeid6m3i5ofq7vuogqapdnoshhq7mswmudhvfcr2craw25fdwtoe3lm
Expand Down
2 changes: 1 addition & 1 deletion packages/valory/services/trader/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ license: Apache-2.0
fingerprint:
README.md: bafybeigtuothskwyvrhfosps2bu6suauycolj67dpuxqvnicdrdu7yhtvq
fingerprint_ignore_patterns: []
agent: valory/trader:0.1.0:bafybeibqjelcx6ls2ezwembpxzemgvths3ebbt6oqr32v4eln437ulwspq
agent: valory/trader:0.1.0:bafybeibxruliur6cpcgsepjw7o63pabbhmlezomjovjpd6tmnetwtxyt6u
number_of_agents: 4
deployment:
agent:
Expand Down
2 changes: 1 addition & 1 deletion packages/valory/services/trader_pearl/service.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ license: Apache-2.0
fingerprint:
README.md: bafybeibg7bdqpioh4lmvknw3ygnllfku32oca4eq5pqtvdrdsgw6buko7e
fingerprint_ignore_patterns: []
agent: valory/trader:0.1.0:bafybeibqjelcx6ls2ezwembpxzemgvths3ebbt6oqr32v4eln437ulwspq
agent: valory/trader:0.1.0:bafybeibxruliur6cpcgsepjw7o63pabbhmlezomjovjpd6tmnetwtxyt6u
number_of_agents: 1
deployment:
agent:
Expand Down
7 changes: 4 additions & 3 deletions packages/valory/skills/decision_maker_abci/skill.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ description: This skill is responsible for the decision making and placing the b
license: Apache-2.0
aea_version: '>=1.0.0, <2.0.0'
fingerprint:
.coverage: bafybeiamyhdetx6urx43npwxxsid2o26dt5akzyvtyvyeb33v4h4rhrqii
README.md: bafybeia367zzdwndvlhw27rvnwodytjo3ms7gbc3q7mhrrjqjgfasnk47i
__init__.py: bafybeih563ujnigeci2ldzh7hakbau6a222vsed7leg3b7lq32vcn3nm4a
behaviours/__init__.py: bafybeih6ddz2ocvm6x6ytvlbcz6oi4snb5ee5xh5h65nq4w2qf7fd7zfky
Expand Down Expand Up @@ -68,14 +69,14 @@ fingerprint:
tests/states/test_decision_request.py: bafybeigqbakm2olkwvcngertjplhnmu6on6tp6hxn7lxygi2gf5a5eurbe
tests/states/test_final_states.py: bafybeiftfd3ovaqpfe7t5ry7maiziavk74wl66d6zo6ikhgodznormd2nm
tests/states/test_handle_failed_tx.py: bafybeibuepj6fko7ba3bef6nybzetilni2iwgkxd5xeazqskadbad3l2zq
tests/states/test_order_subscription.py: bafybeiag37uk5mitjm4yadcpr67icfmmzeucdlgvqoct4y4jeyhnebyyoi
tests/states/test_order_subscription.py: bafybeienk43nsbhekzndztykcwyt7rqisiesu7qzscrhqdqvsonkzbtteq
tests/states/test_randomness.py: bafybeib3eqjv6mhlprzda7d4viddn5alrfqteq6juyg3ccejseoywcsbey
tests/states/test_redeem.py: bafybeiezdnfrxukb2xpwffrr357g2anmdkwy7wo3nphvlggipq5xrdzr7a
tests/states/test_sampling.py: bafybeifvbzikke6wtex2p5j7fsnpdbj4qqxl5vh2lm2m2apgvuqdonoyzm
tests/states/test_tool_selection.py: bafybeib7js3dj7647t33o5ybfqftwytxktwrvhbri5yuyymg6znj6y7xxa
tests/test_dialogues.py: bafybeibulo64tgfrq4e5qbcqnmifrlehkqciwuavublints353zaj2mlpa
tests/test_handlers.py: bafybeihpkgtjjm3uegpup6zkznpoaxqpu6kmp3ujiggrzbe73p5fzlq7im
tests/test_payloads.py: bafybeifolgd3qvhxd5psrif4seo5a7ywzz6uumkgfisy7ipoxzeqsspzfu
tests/test_payloads.py: bafybeiez44b2dzcwfb5zbtwkv4stdb53twjllq5jkx4jm4iivguyytt6we
tests/test_rounds.py: bafybeigifftusd4ew42tyvyrr55o2uehhcik2gdq3atkpjwwlqdeskedty
utils/__init__.py: bafybeiazrfg3kwfdl5q45azwz6b6mobqxngxpf4hazmrnkhinpk4qhbbf4
utils/nevermined.py: bafybeigallaqxhqopznhjhefr6bukh4ojkz5vdtqyzod5dksshrf24fjgi
Expand All @@ -101,7 +102,7 @@ protocols:
- valory/http:1.0.0:bafybeifugzl63kfdmwrxwphrnrhj7bn6iruxieme3a4ntzejf6kmtuwmae
skills:
- valory/abstract_round_abci:0.1.0:bafybeib733xfbndtpvkf44mtk7oyodnficgloo6xhn7xmqxxeos33es65u
- valory/market_manager_abci:0.1.0:bafybeicztk62pslofv6ui3aw3giw2tnvlfwfmatqbyvvzv4ampneu6isqa
- valory/market_manager_abci:0.1.0:bafybeigmea7hrb42fj5v6pwjzww3vibvoov5qd7raiv5didzvrikxs242i
- valory/transaction_settlement_abci:0.1.0:bafybeic7q7recyka272udwcupblwbkc3jkodgp74fvcdxb7urametg5dae
- valory/mech_interact_abci:0.1.0:bafybeid6m3i5ofq7vuogqapdnoshhq7mswmudhvfcr2craw25fdwtoe3lm
- valory/staking_abci:0.1.0:bafybeictd5pxhscuhqntvctb7l5lfjausxt2m22rg5mkaiuj4cwwcxpvne
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ def test_end_block_updates_sync_data(
with patch.object(
SubscriptionRound,
"most_voted_payload_values",
new_callable=MagicMock(return_value=[None, None, None, "new_agreement_id"]),
new_callable=MagicMock(return_value=[None, None, None, "new_agreement_id", 10000]),
):
# Call the `end_block` method to trigger the update
result = round_instance.end_block()
Expand All @@ -148,6 +148,7 @@ def test_end_block_updates_sync_data(
sync_data, event = result
# Assert that the agreement_id was updated to the new_agreement_id
assert getattr(sync_data, "agreement_id", None) == "new_agreement_id"
assert getattr(sync_data, "wallet_balance", None) == 10000
assert event is not None


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@
"tx_submitter": "dummy tx submitter",
"tx_hash": "dummy tx hash",
"mocking_mode": True,
"wallet_balance": 10000
},
),
(
Expand Down
1 change: 1 addition & 0 deletions packages/valory/skills/market_manager_abci/skill.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ description: This skill implements the MarketManager for an AEA.
license: Apache-2.0
aea_version: '>=1.0.0, <2.0.0'
fingerprint:
.coverage: bafybeiamyhdetx6urx43npwxxsid2o26dt5akzyvtyvyeb33v4h4rhrqii
README.md: bafybeie6miwn67uin3bphukmf7qgiifh4xtm42i5v3nuyqxzxtehxsqvcq
__init__.py: bafybeigrtedqzlq5mtql2ssjsdriw76ml3666m4e2c3fay6vmyzofl6v6e
behaviours.py: bafybeifzt6vykvvgr5rtzmzdbo7bfsxi765xsljdfrktrq35ogf6cdhmna
Expand Down
6 changes: 3 additions & 3 deletions packages/valory/skills/trader_abci/skill.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@ skills:
- valory/reset_pause_abci:0.1.0:bafybeigrdlxed3xlsnxtjhnsbl3cojruihxcqx4jxhgivkd5i2fkjncgba
- valory/transaction_settlement_abci:0.1.0:bafybeic7q7recyka272udwcupblwbkc3jkodgp74fvcdxb7urametg5dae
- valory/termination_abci:0.1.0:bafybeib5l7jhew5ic6iq24dd23nidcoimzqkrk556gqywhoziatj33zvwm
- valory/market_manager_abci:0.1.0:bafybeicztk62pslofv6ui3aw3giw2tnvlfwfmatqbyvvzv4ampneu6isqa
- valory/decision_maker_abci:0.1.0:bafybeihnflr5sfvdcahviwb6jleevxlzuqrijwvs3abrguvbrn34rti4oa
- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeigaunkiw3ek3xrmxt35v62o3mohwpq7gbx6mdybebta5rq65c7jju
- valory/market_manager_abci:0.1.0:bafybeigmea7hrb42fj5v6pwjzww3vibvoov5qd7raiv5didzvrikxs242i
- valory/decision_maker_abci:0.1.0:bafybeigsrmbaalqtl3moyrpiv4sl2pse5cxmqy56rxco3x3gkdnt4d3gii
- valory/tx_settlement_multiplexer_abci:0.1.0:bafybeianqmo466ksztcqsw2hhxw3yl3afto6okfjyy2ot6a34krez6acwq
- valory/staking_abci:0.1.0:bafybeictd5pxhscuhqntvctb7l5lfjausxt2m22rg5mkaiuj4cwwcxpvne
- valory/check_stop_trading_abci:0.1.0:bafybeib75qrimmvensqmskdp5kzki5ijjwolqk2ojekeommakaf64mzn54
- valory/mech_interact_abci:0.1.0:bafybeid6m3i5ofq7vuogqapdnoshhq7mswmudhvfcr2craw25fdwtoe3lm
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ protocols:
- valory/ledger_api:1.0.0:bafybeihdk6psr4guxmbcrc26jr2cbgzpd5aljkqvpwo64bvaz7tdti2oni
skills:
- valory/abstract_round_abci:0.1.0:bafybeib733xfbndtpvkf44mtk7oyodnficgloo6xhn7xmqxxeos33es65u
- valory/decision_maker_abci:0.1.0:bafybeihnflr5sfvdcahviwb6jleevxlzuqrijwvs3abrguvbrn34rti4oa
- valory/decision_maker_abci:0.1.0:bafybeigsrmbaalqtl3moyrpiv4sl2pse5cxmqy56rxco3x3gkdnt4d3gii
- valory/staking_abci:0.1.0:bafybeictd5pxhscuhqntvctb7l5lfjausxt2m22rg5mkaiuj4cwwcxpvne
- valory/mech_interact_abci:0.1.0:bafybeid6m3i5ofq7vuogqapdnoshhq7mswmudhvfcr2craw25fdwtoe3lm
behaviours:
Expand Down

0 comments on commit 9c2d330

Please sign in to comment.