Pages:
Author

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

sr. member
Activity: 449
Merit: 250

Hey bud,

My implementation would look at this in the literal sense of the spec.  So 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8 would be the sender since it was the largest single input.

It could be argued that this is not a mastercoin transaction (no data packets) so doesn't need to abide by the same rules, but I'm not sure we want to open that proverbial door!

Quote
Has a single or the largest input signed by the sending address.

Sendmany is not a great way to do this as we have no control over the inputs used (and would have to work around bitcoind 'account' handling (a concept internal to bitcoind/qt, not the protocol).

Would it help if I built an encodedexpayment function into the lib that handles this?

Thanks!

EDIT: Sorry, I see you already asked for an encodedexpayment-style function a few days ago - must have missed that somehow.  Yep no problems, I'll let you know when it's ready Smiley

Zathras,

My code is missing "the largest single input is the reference".   I will update it and reparse everything.   

I'm also trying to build encodedexpayment so that i can remove the "sendmany" from the wallet.

Thanks again!

 

legendary
Activity: 1386
Merit: 1000
KawBet.com - Anonymous Bitcoin Casino & Sportsbook
I think Zathras should comment since I can't detected why their are being invalidated on his end. Once I know the reason I can compare it to my validation checking to see which of the implementations has the correct interpretation of the spec.
Thanks Tachi -
I'll stand by until Zathras has a chance to look it over.  Meanwhile, keep up the great work. 
hero member
Activity: 938
Merit: 1000
I think Zathras should comment since I can't detected why their are being invalidated on his end. Once I know the reason I can compare it to my validation checking to see which of the implementations has the correct interpretation of the spec.
legendary
Activity: 1834
Merit: 1019
I hope to start testing before the end of the year. I think most implementations are nearing completion.

I've only been 10-15% away from full blockchain synch for the past two weeks... hopefully progress will both converge by the end of this month Smiley
hero member
Activity: 938
Merit: 1000
I hope to start testing before the end of the year. I think most implementations are nearing completion.
sr. member
Activity: 240
Merit: 250
I don't suppose there is any chance of an update as to how long till the Distributed exchange may be up and running? I know it's nearly impossible to provide an exact date or anything, but a rough idea would be nice, days, weeks, months?

I don't mean to nag you guys, and I know it's not easy! The reason that I ask is that a new system for the current buying and selling order book is being discussed, and it would be good to have a rough idea of how much longer we may actually be using it before the guys running it spend their time setting up something a bit more advanced! Cheers  Smiley
legendary
Activity: 1260
Merit: 1031
Rational Exuberance
Pull request 6 merged:

Quote
Mastercoin messages that also have a reference output to the seller address, for instance if the buyer wants to change his offer, should not be counted towards the actual purchase of Mastercoins.

Pull request 7 merged:

Quote
## Unlocking features

Not all features described in this document are active by default. Each feature will be unlocked on a certain block once it's deemed stable. Only Test Mastercoin transactions will be allowed if a feature is not unlocked yet. All other messages will be invalidated. The only exception to this rule is the Simple Send message, this has been enabled since Exodus.

I consider both of these changes quite uncontroversial. We agreed to #6 awhile back, and it is super-obvious to me that we must take the approach outlined in #7. If this is controversial to anybody, please let me know.
sr. member
Activity: 266
Merit: 250
What use case scenarios are we enabling here?

To date we have always applied the logic that the sender is the address with the largest input - I'm trying to see where the value is in deviating from that.

Thanks! Smiley


It is a Payment transaction
5697c55a0fb5ee61f6e9c78cb9c84cef23e11c84c68cd6e2821b8869489b808c


1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2
1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8 (0.00009 BTC - Output) n=1
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2

If its the largest input, 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8  (0.00009) is the reference.
Is it is the largest total input, 1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00018) is the reference.


The  sender is really 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8.  It is payment for a purchase offer. But using the sendmany method it created the input transaction above.

Hey bud,

My implementation would look at this in the literal sense of the spec.  So 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8 would be the sender since it was the largest single input.

It could be argued that this is not a mastercoin transaction (no data packets) so doesn't need to abide by the same rules, but I'm not sure we want to open that proverbial door!

Quote
Has a single or the largest input signed by the sending address.

Sendmany is not a great way to do this as we have no control over the inputs used (and would have to work around bitcoind 'account' handling (a concept internal to bitcoind/qt, not the protocol).

Would it help if I built an encodedexpayment function into the lib that handles this?

Thanks!

EDIT: Sorry, I see you already asked for an encodedexpayment-style function a few days ago - must have missed that somehow.  Yep no problems, I'll let you know when it's ready Smiley
sr. member
Activity: 449
Merit: 250
What use case scenarios are we enabling here?

To date we have always applied the logic that the sender is the address with the largest input - I'm trying to see where the value is in deviating from that.

Thanks! Smiley


It is a Payment transaction
5697c55a0fb5ee61f6e9c78cb9c84cef23e11c84c68cd6e2821b8869489b808c


1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2
1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8 (0.00009 BTC - Output) n=1
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2

If its the largest input, 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8  (0.00009) is the reference.
Is it is the largest total input, 1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00018) is the reference.


The  sender is really 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8.  It is payment for a purchase offer. But using the sendmany method it created the input transaction above.
sr. member
Activity: 266
Merit: 250
What use case scenarios are we enabling here?

To date we have always applied the logic that the sender is the address with the largest input - I'm trying to see where the value is in deviating from that.

Thanks! Smiley
sr. member
Activity: 449
Merit: 250
Are you always invalidating it? Or only if there are two purchase offers on both of the addresses? I think it would add flexibility if we would allow multi-input payments we just need to track which inputs have an offer open.
I also agree on the flexibility of allowing multi input as payment but only for one purchase offer.

 If there are 2 purchase offers for both address , payment transaction will be applied only to 1 purchase offer of one the of the address (lesser n value)

Currently I invalidated  the transaction.  Will change the code if this is approved.

Quote
I just posted our proposal for a reference implementation, comments/critique welcome.

Currently reading it. Will post comments soon.
hero member
Activity: 938
Merit: 1000
Are you always invalidating it? Or only if there are two purchase offers on both of the addresses? I think it would add flexibility if we would allow multi-input payments we just need to track which inputs have an offer open.

In other news:

I just posted our proposal for a reference implementation, comments/critique welcome.
sr. member
Activity: 449
Merit: 250
What kind of payment is this suppose to be? A payment for the distributed exchange?

I guess we need to think of a way to properly handle this case. I'm guessing that we could backtrace and see if one of these addresses did a Purchase Offer. If both of them did a purchase offer we invalidate the transaction. Could that work?


It supposed to be a payment of 1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8.

The wallet has 2 address
1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb

then I used sendmany api function and that was the result.  My implementation also invalidated it  =)
hero member
Activity: 938
Merit: 1000
What kind of payment is this suppose to be? A payment for the distributed exchange?

I guess we need to think of a way to properly handle this case. I'm guessing that we could backtrace and see if one of these addresses did a Purchase Offer. If both of them did a purchase offer we invalidate the transaction. Could that work?
sr. member
Activity: 449
Merit: 250
The transaction below has multiple inputs
5697c55a0fb5ee61f6e9c78cb9c84cef23e11c84c68cd6e2821b8869489b808c


1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2
1NZC9Pk4Rt1mVe5dL8w2fShXJppyJU7Vq8 (0.00009 BTC - Output) n=1
1BKpa19m5Xy9SvSzC5djPWtCfbuynSDwmb (0.00006 BTC - Output) n=2


Which one of the address will be the reference address?
hero member
Activity: 938
Merit: 1000
Devs, please take a look at this pull request and comment on the spec.
member
Activity: 77
Merit: 10
Forbes covers Mastercoin Decentralized Exchange. This is all thanks to you guys : )
 
http://www.forbes.com/sites/jasperhamill/2013/11/30/fed-up-with-bitcoin-heres-how-to-start-your-own-currency

And well done Michael Terpin, you are the man. Best Media Lead in Bitcoin. He knows his stuff. Great article.

Great article! I'm sure it'll bring people here to try and see when this awesome Mastercoin platform will be available. Perhaps someone could give a short summary of where we are now and what still needs to be done before Distributed Exchange is ready for use?
sr. member
Activity: 449
Merit: 250
Ok lets start a new Mymastercoins Wallet thread.

https://bitcointalk.org/index.php?topic=355739.new#new.  I created the package using visual studio 2010 (publish) Maybe installer is outdated.  Will check it in a clean install.



Btw someone is posting a lot of .00001 tmsc transactions.

http://mymastercoins.com/Transactions.aspx


newbie
Activity: 53
Merit: 0
MyMastercoins Wallet

http://mymastercoins.com/MyMSCWallet.aspx


Please post here if you find any bugs.  Thanks to Zathras for the send multisig  Smiley

Edit
The package folder contains the windows installer.
The source code in vb.net is also included (under folder source code) You can compile it in vs 2010.

Hey Bitoy - great job - based on the screen shots, it looks very promising.

I tried to install on a vm running windows 8.1 - installation failed during SQL Express installation.

Code:
ERROR DETAILS
Following errors were detected during this operation.
* [12/2/2013 9:29:47 PM] System.Deployment.Application.InvalidDeploymentException (HashValidation)
- Application manifest has either a different computed hash than the one specified or no hash specified at all.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, Uri& appSourceUri, String& appManifestPath)
at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp)
at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState& subState, ActivationDescription actDesc)
at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
--- Inner Exception ---
System.Deployment.Application.InvalidDeploymentException (HashValidation)
- File, MyMastercoinsWallet.exe.manifest, has a different computed hash than specified in manifest.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.ComponentVerifier.VerifyFileHash(String filePath, Hash hash)
at System.Deployment.Application.ComponentVerifier.VerifyFileHash(String filePath, HashCollection hashCollection)
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)

Based on that and the event log, it appears that sql express 2008 is not compatible with 8.1 and its also complaining about the validation hash.  I'm guessing SP3 or may be required in this case.  Will need to take a closer look when I have more time.

Thanks for uploading!

Edit - You're call, but it may be useful to start a thread for your wallet discussion.  I guess its up to you and the other devs how you'd like to organize the various topics but still make it easy to find things etc... I guess the supposed dedicated mastercoin forum should help with this..

The same thing happened to me aswell, only I'm running windows 7 so It probably doesn't have anything to do with the OS.

I'll still leave error details here in the case that you spot something different:


Code:
ERROR SUMMARY
Below is a summary of the errors, details of these errors are listed later in the log.
* Activation of C:\Users\Marin\Downloads\MyMastercoinsWalletBeta-master\MyMastercoinsWalletBeta-master\package\MyMastercoinsWallet.application resulted in exception. Following failure messages were detected:
+ Application manifest has either a different computed hash than the one specified or no hash specified at all.
+ File, MyMastercoinsWallet.exe.manifest, has a different computed hash than specified in manifest.

COMPONENT STORE TRANSACTION FAILURE SUMMARY
No transaction error was detected.

WARNINGS
There were no warnings during this operation.

OPERATION PROGRESS STATUS
* [12/3/2013 10:09:28 AM] : Activation of C:\Users\Marin\Downloads\MyMastercoinsWalletBeta-master\MyMastercoinsWalletBeta-master\package\MyMastercoinsWallet.application has started.
* [12/3/2013 10:09:33 AM] : Processing of deployment manifest has successfully completed.
* [12/3/2013 10:09:33 AM] : Installation of the application has started.

ERROR DETAILS
Following errors were detected during this operation.
* [12/3/2013 10:09:33 AM] System.Deployment.Application.InvalidDeploymentException (HashValidation)
- Application manifest has either a different computed hash than the one specified or no hash specified at all.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, Uri& appSourceUri, String& appManifestPath)
at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp)
at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState& subState, ActivationDescription actDesc)
at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
--- Inner Exception ---
System.Deployment.Application.InvalidDeploymentException (HashValidation)
- File, MyMastercoinsWallet.exe.manifest, has a different computed hash than specified in manifest.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.ComponentVerifier.VerifyFileHash(String filePath, Hash hash)
at System.Deployment.Application.ComponentVerifier.VerifyFileHash(String filePath, HashCollection hashCollection)
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)

COMPONENT STORE TRANSACTION DETAILS
No transaction information is available.
full member
Activity: 201
Merit: 100
MyMastercoins Wallet

http://mymastercoins.com/MyMSCWallet.aspx


Please post here if you find any bugs.  Thanks to Zathras for the send multisig  Smiley

Edit
The package folder contains the windows installer.
The source code in vb.net is also included (under folder source code) You can compile it in vs 2010.

Hey Bitoy - great job - based on the screen shots, it looks very promising.

I tried to install on a vm running windows 8.1 - installation failed during SQL Express installation.

Code:
ERROR DETAILS
Following errors were detected during this operation.
* [12/2/2013 9:29:47 PM] System.Deployment.Application.InvalidDeploymentException (HashValidation)
- Application manifest has either a different computed hash than the one specified or no hash specified at all.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, Uri& appSourceUri, String& appManifestPath)
at System.Deployment.Application.ApplicationActivator.DownloadApplication(SubscriptionState subState, ActivationDescription actDesc, Int64 transactionId, TempDirectory& downloadTemp)
at System.Deployment.Application.ApplicationActivator.InstallApplication(SubscriptionState& subState, ActivationDescription actDesc)
at System.Deployment.Application.ApplicationActivator.PerformDeploymentActivation(Uri activationUri, Boolean isShortcut, String textualSubId, String deploymentProviderUrlFromExtension, BrowserSettings browserSettings, String& errorPageUrl)
at System.Deployment.Application.ApplicationActivator.ActivateDeploymentWorker(Object state)
--- Inner Exception ---
System.Deployment.Application.InvalidDeploymentException (HashValidation)
- File, MyMastercoinsWallet.exe.manifest, has a different computed hash than specified in manifest.
- Source: System.Deployment
- Stack trace:
at System.Deployment.Application.ComponentVerifier.VerifyFileHash(String filePath, Hash hash)
at System.Deployment.Application.ComponentVerifier.VerifyFileHash(String filePath, HashCollection hashCollection)
at System.Deployment.Application.DownloadManager.DownloadApplicationManifest(AssemblyManifest deploymentManifest, String targetDir, Uri deploymentUri, IDownloadNotification notification, DownloadOptions options, Uri& appSourceUri, String& appManifestPath)

Based on that and the event log, it appears that sql express 2008 is not compatible with 8.1 and its also complaining about the validation hash.  I'm guessing SP3 or may be required in this case.  Will need to take a closer look when I have more time.

Thanks for uploading!

Edit - You're call, but it may be useful to start a thread for your wallet discussion.  I guess its up to you and the other devs how you'd like to organize the various topics but still make it easy to find things etc... I guess the supposed dedicated mastercoin forum should help with this..
Pages:
Jump to: