SOVED: I thought Test2 was buying 3 AXX, but in fact it was selling 3 XLM. Don't forget to check the ordering and meaning of parameters!
I'm having trouble explaining what's going on with my bid and offers:
Issuer: GD57JZ42YKIEDLCFIZD2BW6LIYN7KIOEMFSIL37WZ5RS7DPLEW6DOOWG
Asset: AXX
Test1: GC5RQZPRI2SXMOL5JP2QTJXO72IAJLGMNU7TG5ADU6OMYDEJI3APJTZI
Balance: 444 AXX
Test2: GBPJWQBGYSIWHFDLDKNO4XMHUC7RUOX7GBORLG4ZKUFGKWMPW77OIHXA
Balance: 77 AXX
They each create an offer:
Test1: sell 20 AXX
Test2: buy 3 AXX
What I expected to happen is:
Test1 balance: 441 AAX (444 - 3)
Test2 balance: 80 AAX (77 + 3)
Sell offer: 17 AXX (20 - 3)
What actually happened was:
Test1 balance: 424 AAX (444 - 20)
Test2 balance: 97 AAX (77 + 20)
Buy offer: 2.9 AAX (3 - 0.1)
...
So my questions are:
- Why did Test2 get 20 AAX when it only wanted 3?
- Why is there a buy offer of 2.9 AAX?
I'm hoping this is just my misunderstanding of the documentation.
Edit: Here's the links to operations for Test1 and Test2:
https://www.stellar.org/laboratory/#explorer?resource=operations&endpoint=for_account&values=eyJhY2NvdW50X2lkIjoiR0M1UlFaUFJJMlNYTU9MNUpQMlFUSlhPNzJJQUpMR01OVTdURzVBRFU2T01ZREVKSTNBUEpUWkkifQ%3D%3D&network=test
https://www.stellar.org/laboratory/#explorer?resource=operations&endpoint=for_account&values=eyJhY2NvdW50X2lkIjoiR0JQSldRQkdZU0lXSEZETERLTk80WE1IVUM3UlVPWDdHQk9STEc0WktVRkdLV01QVzc3T0lIWEEifQ%3D%3D&network=test
And as you can see, the trades for Test2 indicate taking 20 and not 3?
https://www.stellar.org/laboratory/#explorer?resource=trades&endpoint=for_account&values=eyJhY2NvdW50X2lkIjoiR0M1UlFaUFJJMlNYTU9MNUpQMlFUSlhPNzJJQUpMR01OVTdURzVBRFU2T01ZREVKSTNBUEpUWkkifQ%3D%3D&network=test
https://www.stellar.org/laboratory/#explorer?resource=trades&endpoint=for_account&values=eyJhY2NvdW50X2lkIjoiR0JQSldRQkdZU0lXSEZETERLTk80WE1IVUM3UlVPWDdHQk9STEc0WktVRkdLV01QVzc3T0lIWEEifQ%3D%3D&network=test