Pages:
Author

Topic: 300 BTC Coding Contest: Distributed Exchange (MasterCoin Developer Thread) - page 19. (Read 129207 times)

sr. member
Activity: 284
Merit: 250
@grazcoin
I had a send of TMSC fail me.
I tried to send 0.118 TMSC from 14Q2NNiF5YzDZCjo7vrBuHdbZcmHRJyW3j to 1NVNkPqSLo4N2seaZCzAkVFPjcGLPJSZAZ.
The result was "Transaction sent" and the following link popped up, but the TX doesnt seem to exist.
https://blockchain.info/tx/85f63d87fe1aefacc9b85178565d4c065cfb3284fc440438d8bb8aec75ef5b5e

masterchain's server only prepares the raw transaction. From that moment, everything is done on the client, and the tx is sent to blockchain.info - so I have no logs from that moment.
From the logs of the transaction generation that you mentioned (see below), everything looks fine - maybe the fee is a little too low.
What could go wrong:
1. currently the tx is published indirectly using blockchain.info. Maybe something died on the way there. (soon there will be the option to publish directly using masterchain.info).
2. blockchain.info decided that the fee is too low (?)

I suggest that you try again, and if it doesn't work, send here the raw transaction as well as the signed transaction for inspection.

logs:
prepare_send_tx_for_signing: plain dataHex: --0100000000000000020000000000b40dc00000000000000000000000000000--
prepare_send_tx_for_signing: obfus dataHex: 029b07f670d5fc1b4e93be50bf51493046167bbd8bc133e1d012dde615a2383bfb
get_nearby_valid_pubkey: trying 029b07f670d5fc1b4e93be50bf51493046167bbd8bc133e1d012dde615a2383bfb
get_nearby_valid_pubkey: valid  029b07f670d5fc1b4e93be50bf51493046167bbd8bc133e1d012dde615a2383bfc
prepare_send_tx_for_signing: valid dataHex: 029b07f670d5fc1b4e93be50bf51493046167bbd8bc133e1d012dde615a2383bfc
prepare_send_tx_for_signing: change address is 14Q2NNiF5YzDZCjo7vrBuHdbZcmHRJyW3j
prepare_send_tx_for_signing: too_address is 1NVNkPqSLo4N2seaZCzAkVFPjcGLPJSZAZ
prepare_send_tx_for_signing: total inputs value is 298280
prepare_send_tx_for_signing: fee is 10000
prepare_send_tx_for_signing: dust limit is 5430
prepare_send_tx_for_signing: BIP11 script is 1 [ 029abce7b350f33266ff19ed9389bbdc0fda3692fe084aa87163b7de2e77052534 ] [ 029b07f670d5fc1b4e93be50bf51493046167bbd8bc133e1d012dde615a2383bfc ] 2 checkmultisig
Added input a7120ed05e1b42f48fec59d0a3b56202d15a0bb8272653f995ac584f16e67c09:3
Added output sending 5430 Satoshis to 1EXoDusjGwvnjZUyKkxZ4UHEf77z6A5S4P.
Added output sending 5430 Satoshis to 1NVNkPqSLo4N2seaZCzAkVFPjcGLPJSZAZ.
Added output sending 10860 Satoshis to 1 [ 029abce7b350f33266ff19ed9389bbdc0fda3692fe084aa87163b7de2e77052534 ] [ 029b07f670d5fc1b4e93be50bf51493046167bbd8bc133e1d012dde615a2383bfc ] 2 checkmultisig.
Added output sending 266560 Satoshis to 14Q2NNiF5YzDZCjo7vrBuHdbZcmHRJyW3j.

hero member
Activity: 938
Merit: 1000
I've added PR #39 (Graz's suggestion) and a variation PR #40.

Developers please read and give your +1 or -1's. Even without these PR's there are plenty of things to deal with.

I'm trying to improve the consensus tools we have available this week to add support for a service which can do consensus on the transaction level so we can more easily determine where our DEx implementations differ. In two weeks time I probably won't have to struggle to find the time to work on all this. Can't wait Smiley
legendary
Activity: 1260
Merit: 1031
Rational Exuberance
The guys from engine.co found a potential race condition where the user could accidentally create a new sell order when they were trying to change an old one, because the old one had already been bought.

At my suggestion, Marv made this pull request to add a 2-confirmation time limit after a sale is complete before that address can initiate a new sell offer: https://github.com/mastercoin-MSC/spec/pull/38

I'm posting here because not respecting the time limit will lead to consensus divergence, so I want to make sure everybody is aware of it.

Thanks!

Perhaps it's the lack of sleep but I don't like the fact that this has been merged already, up till now everything we did was democratic. Shouldn't we discuss such a major change in the protocol before merging it? I would appreciate it if at least some examples could be given in how this is suppose to work before and after the merge.

I also think this pull request should be open for discussion like any other pull request.
my opinion:
I don't think this solution really solves this race condition, e.g. due to difference in fee amount and inputs complexity of the buy/sell change transactions, the sell offer change can still get merged 2 confirmations later, and then we're in the same race condition state.

Alternative solution would be to keep only the option to cancel the offer (amount zero), and omit the option to change it.
If one wants to make a change, he can first cancel the old offer, and then create a new one.

EDIT: it would be also much easier to implement, and reduce complexity.


My plus 1 for this idea. Separate messages make a lot of sense to me.

any update on this? J.R.?
I would like to update the implementation.


Apologies for jumping the gun on this guys! I was worried people would get bogged down waiting for a decision on this Smiley

I'm very happy to accept a pull request adding a cancel command instead. Is somebody available to jump on that task? I want to avoid hearing "I haven't made much progress because I'm waiting on a decision about issue X." Smiley
newbie
Activity: 34
Merit: 0
@grazcoin
I had a send of TMSC fail me.
I tried to send 0.118 TMSC from 14Q2NNiF5YzDZCjo7vrBuHdbZcmHRJyW3j to 1NVNkPqSLo4N2seaZCzAkVFPjcGLPJSZAZ.
The result was "Transaction sent" and the following link popped up, but the TX doesnt seem to exist.
https://blockchain.info/tx/85f63d87fe1aefacc9b85178565d4c065cfb3284fc440438d8bb8aec75ef5b5e
newbie
Activity: 34
Merit: 0

Bitoy will be able to help you better but just a few pages back I had issues and found..

-Make sure you have none of you're files in your MyMastercoins folder set to read only! (You can do this by Right Click: Properties and make sure the box is un-checked) (Additionally make sure you have Full Control as an Administrator, you can do this as well by Right Click: Properties: Security make sure you have "Full Control")

Though that shouldn't have anything to do with Exception thrown: File not found.

I had a issue with the main setup.exe so I actually go into the MyMastercoinsTCW_1_0_0_1 folder and run MyMastercoinsTCW (Application).

None of the files are read-only.
How did you run MyMastercoinsTCW (Application) from the MyMastercoinsTCW_1_0_0_1 folder? If I try that, I get: ' You cannot start application MyMastercoinsTCW from this location because it is already installed from a different location'.
I have MyMastercoinsTCW (Application) twice, once in the mymastercoinsTCW folder and the other in MyMastercoinsTCW_1_0_0_1. If I run the one from mymastercoinsTCW I get the file not found stuff again. Is having MyMastercoinsTCW (Application) twice the problem?
newbie
Activity: 34
Merit: 0
Clearing cache fixed it, thanks.

Keep up the good work  Smiley
sr. member
Activity: 284
Merit: 250
Did you change something with sell offers, grazcoin? Because when I look at any of them now I see :

Transaction    {{transactionInformation.tx_hash}}
Sell offer details Seller    {{transactionInformation.from_address}}
Currency    {{transactionInformation.currency_str}}
Price per coin    {{transactionInformation.formatted_price_per_coin}} ฿/{{currency}} DO NOT POST SESC LINKS
Amount for sell    {{transactionInformation.formatted_amount}}
Amount available    {{transactionInformation.formatted_amount_available}}
Bitcoin amount desired    {{transactionInformation.formatted_bitcoin_amount_desired}} ฿
Fee required    {{transactionInformation.formatted_fee_required}} ฿
Payment timeframe (blocks)    {{transactionInformation.formatted_block_time_limit}}
Information Transaction type    {{transactionInformation.tx_type_str}}
Transaction ID    {{transactionInformation.tx_hash|characters:30}}
Included in block    {{transactionInformation.block}}
Index in block    {{transactionInformation.index}}
Block time    {{transactionInformation.tx_time | date:'yyyy-MM-dd HH:mm:ss UTC'}}
Transaction method    {{transactionInformation.method}}
Valid    

Yesterday it showed real values.

I just keep updating the site. Please press refresh ;-)
It is only browser's cache that makes this problem.

newbie
Activity: 34
Merit: 0
Did you change something with sell offers, grazcoin? Because when I look at any of them now I see :

Transaction    {{transactionInformation.tx_hash}}
Sell offer details Seller    {{transactionInformation.from_address}}
Currency    {{transactionInformation.currency_str}}
Price per coin    {{transactionInformation.formatted_price_per_coin}} ฿/{{currency}}
Amount for sell    {{transactionInformation.formatted_amount}}
Amount available    {{transactionInformation.formatted_amount_available}}
Bitcoin amount desired    {{transactionInformation.formatted_bitcoin_amount_desired}} ฿
Fee required    {{transactionInformation.formatted_fee_required}} ฿
Payment timeframe (blocks)    {{transactionInformation.formatted_block_time_limit}}
Information Transaction type    {{transactionInformation.tx_type_str}}
Transaction ID    {{transactionInformation.tx_hash|characters:30}}
Included in block    {{transactionInformation.block}}
Index in block    {{transactionInformation.index}}
Block time    {{transactionInformation.tx_time | date:'yyyy-MM-dd HH:mm:ss UTC'}}
Transaction method    {{transactionInformation.method}}
Valid    

Yesterday it showed real values.
sr. member
Activity: 284
Merit: 250
The guys from engine.co found a potential race condition where the user could accidentally create a new sell order when they were trying to change an old one, because the old one had already been bought.

At my suggestion, Marv made this pull request to add a 2-confirmation time limit after a sale is complete before that address can initiate a new sell offer: https://github.com/mastercoin-MSC/spec/pull/38

I'm posting here because not respecting the time limit will lead to consensus divergence, so I want to make sure everybody is aware of it.

Thanks!

Perhaps it's the lack of sleep but I don't like the fact that this has been merged already, up till now everything we did was democratic. Shouldn't we discuss such a major change in the protocol before merging it? I would appreciate it if at least some examples could be given in how this is suppose to work before and after the merge.

I also think this pull request should be open for discussion like any other pull request.
my opinion:
I don't think this solution really solves this race condition, e.g. due to difference in fee amount and inputs complexity of the buy/sell change transactions, the sell offer change can still get merged 2 confirmations later, and then we're in the same race condition state.

Alternative solution would be to keep only the option to cancel the offer (amount zero), and omit the option to change it.
If one wants to make a change, he can first cancel the old offer, and then create a new one.

EDIT: it would be also much easier to implement, and reduce complexity.


My plus 1 for this idea. Separate messages make a lot of sense to me.

any update on this? J.R.?
I would like to update the implementation.
sr. member
Activity: 284
Merit: 250
@grazcoin looks great, I like your site and would love to participate, but I can't seem to get it to work.
Whenever I try to add an address to the wallet, I end up with an empty wallet with no addresses in it.
I think you can only add addresses that received MSC or TMSC.


thanks, I thought so too but i got the same effect when trying to add an address with MSC in it.

edit:
I see now that I can still try to use the DEx functions and I dont really need to have the address in my wallet.
the effect should be the same, right?

right.
the wallet is only for convenience - it lists your addresses and balances, and suggest these addresses whenever you click "send here" or "accept". The functionality of DEx (as well as simple send) is identical with and without wallet.

sr. member
Activity: 284
Merit: 250
@grazcoin looks great, I like your site and would love to participate, but I can't seem to get it to work.
Whenever I try to add an address to the wallet, I end up with an empty wallet with no addresses in it.
I think you can only add addresses that received MSC or TMSC.

Indeed. For now, a wallet can only have addresses that already received MSC/TMSC.
If you want to work with an address that *doesn't have yet* MSC/TMSC, you should first send MSC/TMSC to that address (using a wallet of an address that does have such coins, and the button send).
Once you have MSC/TMSC on that address, you can add it to a wallet.

sr. member
Activity: 449
Merit: 250
I couldnt get Bitoy's MyMscWallet to work. I get 'Exception thrown:File not found' every time I run the executable.
I've tried it on a 32bit and 64bit system, getting the same problem.
When I update the settings(which seems to work, since the values are persistent), I get the same error twice.

Hi jakecnn

Please post a screen shot of the error to
https://bitcointalksearch.org/topic/mymastercoins-wallet-355739

After updating, close then try to restart the program.


(When I post the files directly to github, the setup doesn't work something to do with file checksum.  So I zipped it before sending  to github.)

hero member
Activity: 1232
Merit: 683
Tontogether | Save Smart & Win Big
I couldnt get Bitoy's MyMscWallet to work. I get 'Exception thrown:File not found' every time I run the executable.
I've tried it on a 32bit and 64bit system, getting the same problem.
When I update the settings(which seems to work, since the values are persistent), I get the same error twice.

Bitoy will be able to help you better but just a few pages back I had issues and found..

-Make sure you have none of you're files in your MyMastercoins folder set to read only! (You can do this by Right Click: Properties and make sure the box is un-checked) (Additionally make sure you have Full Control as an Administrator, you can do this as well by Right Click: Properties: Security make sure you have "Full Control")

Though that shouldn't have anything to do with Exception thrown: File not found.

I had a issue with the main setup.exe so I actually go into the MyMastercoinsTCW_1_0_0_1 folder and run MyMastercoinsTCW (Application).




newbie
Activity: 10
Merit: 0
@grazcoin looks great, I like your site and would love to participate, but I can't seem to get it to work.
Whenever I try to add an address to the wallet, I end up with an empty wallet with no addresses in it.
I think you can only add addresses that received MSC or TMSC.


thanks, I thought so too but i got the same effect when trying to add an address with MSC in it.

edit:
I see now that I can still try to use the DEx functions and I dont really need to have the address in my wallet.
the effect should be the same, right?
newbie
Activity: 34
Merit: 0
@grazcoin looks great, I like your site and would love to participate, but I can't seem to get it to work.
Whenever I try to add an address to the wallet, I end up with an empty wallet with no addresses in it.
I think you can only add addresses that received MSC or TMSC.
newbie
Activity: 34
Merit: 0
I couldnt get Bitoy's MyMscWallet to work. I get 'Exception thrown:File not found' every time I run the executable.
I've tried it on a 32bit and 64bit system, getting the same problem.
When I update the settings(which seems to work, since the values are persistent), I get the same error twice.
newbie
Activity: 10
Merit: 0
@grazcoin looks great, I like your site and would love to participate, but I can't seem to get it to work.
Whenever I try to add an address to the wallet, I end up with an empty wallet with no addresses in it.
sr. member
Activity: 284
Merit: 250
quote from mastercoin-tools:

Available new docs on http://masterchain.info/downloads

Testing format suggestion (partially done):
https://masterchain.info/downloads/DEx_test_plan.pdf

screenshot:


and icons list (lexicon):
https://masterchain.info/downloads/masterchain_icons_list.pdf

You are welcome to extend this document (pptx files on downloads directory), and fill in tests.
Grazcoin
newbie
Activity: 34
Merit: 0
Yep, zero inputs error, works now. Thanks.
sr. member
Activity: 284
Merit: 250
Masterchain.info/HybridWebWallet:
I'm getting ERROR in the source script field when I prepare a simple send of TMSC or a sell offer. I've verified the address before and got an OK.

The exact errors from the server are not yet shown on the html page, and it will be fixed soon (you could still see the server's output that contains the errors with chrome developer tools).
I assume there were no available bitcoin funds on that address ("zero inputs" error), so no valid transaction could be contracted - am I right?
If not, please give me more details of which address/time it was (or simply reproduce the same error), and I could check the logs.

Pages:
Jump to: