Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Origin is not allowed by Access-Control-Allow-Origin #34

Closed
jaros1 opened this issue Nov 23, 2017 · 10 comments
Closed

Origin is not allowed by Access-Control-Allow-Origin #34

jaros1 opened this issue Nov 23, 2017 · 10 comments
Labels

Comments

@jaros1
Copy link
Owner

jaros1 commented Nov 23, 2017

Origin is not allowed by Access-Control-Allow-Origin. add more user friendly info about open zeronet port and vpn. Normally the problem can be fixed by opening ZeroNet port or switching to an other vpn.

@jaros1
Copy link
Owner Author

jaros1 commented Nov 24, 2017

Pause money transaction processing and wait for user feedback. Notification or confirm dialog.
Transaction should be left in a state where restart processing is possible if the user solves the problem and decides to continue.
List of money transaction, status and error message. Button with abort/retry.
Open wallet problems, Get address problems, Send money problems, missing optional files (pubkeys) etc.

@jaros1
Copy link
Owner Author

jaros1 commented Nov 24, 2017

After Origin is not allowed by Access-Control-Allow-Origin error in btc.com communication.
Ask user to check or disable VPN connection.
Sometimes btc.com allows VPN, sometimes not

@jaros1
Copy link
Owner Author

jaros1 commented Nov 25, 2017

screenshot from 2017-11-25 18-30-51

@jaros1
Copy link
Owner Author

jaros1 commented Dec 1, 2017

Incoming w2_start_mt message from other wallet request = {"msgtype":"w2_start_mt","pay_results":["edf592d91328440c860981cb4888ddd416873e75d37bbe54926597c2f913df55",null]}
row 1: verify bitcoin transactionid from sender. err = {"crossDomain":true}
row 2: send money to other wallet. error: Origin is not allowed by Access-Control-Allow-Origin

processing should stop and user should get a user friendly notification about the problem.
Could be a confirm box + retry operation after vpn issue has been fixed.
Or could be a notification + reload wallet page after the vpn issue has been fixed.
Anyway. w2_start_mt processing should stop and wait until the problem has been solved.
Should not send failed w2_end_mt message to other wallet

Added cross_domain_error dialog box to receive w2_start_mt message.

@jaros1
Copy link
Owner Author

jaros1 commented Dec 1, 2017

Test 1 failed:

issue34-test1-receiver-montreal-mn.log

MoneyNetworkAPI.js:252 MoneyNetworkZService.z_update_5_public_chat z_file_get callback 2b: merged-MoneyNetwork/1PgyTnnACGd1XRdpfiDihgKwYRRnzgz2zh/data/users/1CCiJ97XHgVeJrkbnzLgfXvYRr8QEWxnWF/1512121064902-1512121064902-1-chat.json fileWrite started (116). 1 pending ZeroNet API operation (116)
10:37:44.936 MoneyNetworkAPI.js:2193 Uncaught merged-MoneyNetwork/1PgyTnnACGd1XRdpfiDihgKwYRRnzgz2zh/data/users/1CCiJ97XHgVeJrkbnzLgfXvYRr8QEWxnWF/1512121064902-1512121064902-1-chat.jsonInvalid call. parameter 5 cb is not a callback function
z_file_write @ MoneyNetworkAPI.js:2193
z_file_write @ all.js:6042
write_file @ all.js:8586
(anonymous) @ all.js:8626
(anonymous) @ MoneyNetworkAPI.js:2103
(anonymous) @ MoneyNetworkAPI.js:2095
ZeroFrame.onMessage @ 30-ZeroFrame.js:42
(anonymous) @ 30-ZeroFrame.js:7
10:38:04.365 

Error in z_file_write calls in one of MN angularJS services. Fixed

@jaros1
Copy link
Owner Author

jaros1 commented Dec 1, 2017

Test 2: Failed. Expected cross domain error in montreal. OK send and receive money without any errors.
Todo: round satoshi in notifications: "0.00003402 tBTC / 3402.0000000000005 test satoshi"

@jaros1
Copy link
Owner Author

jaros1 commented Dec 1, 2017

Refactored JS code and added btc_cross_domain_error dialog to w2_check_mt and w2_end_mt message.
Test later.

@jaros1
Copy link
Owner Author

jaros1 commented Dec 21, 2017

See test jaros1/Money-Network#262 (comment)

@jaros1
Copy link
Owner Author

jaros1 commented Jan 3, 2018

See tst jaros1/Money-Network#262 (comment)

@jaros1
Copy link
Owner Author

jaros1 commented Jan 3, 2018

Test OK in jaros1/Money-Network#262 (comment)

@jaros1 jaros1 closed this as completed Jan 3, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant