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

Zcash Bitcore doesn't send notifications on bitcoind/addresstxid #1

Closed
karelbilek opened this issue Oct 26, 2016 · 5 comments
Closed

Comments

@karelbilek
Copy link

Bitcore at https://explorer.testnet.z.cash doesn't send any notifications on bitcoind/addresstxid.

I am not sure if it's an issue with the code itself or with your deployment. (I am leaving the issue here, since it's the only insight/bitcore repo, that has issue tracking.)

A simple code, that works in bitcoin testnet and doesn't work with your server. (I wrote it for browser but it should probably work for node too.)

Bitcoin Testnet:

<script src="https://cdn.socket.io/socket.io-1.4.5.js"></script>
<script>
var endpoint = 'https://testnet.blockexplorer.com';
var connectionType = 'polling';
var address = 'mgswWyysmViMqYmn5XEj1pVz7rVUftVEBP';
var socket = io(endpoint, {transports: [connectionType]})

socket.on('bitcoind/addresstxid', function() {alert('Saw a transaction!');});
socket.emit('subscribe', 'bitcoind/addresstxid', [address]);
</script>

Use your own address, send a testnet transaction there and it works.

Zcash testnet:

<script src="https://cdn.socket.io/socket.io-1.4.5.js"></script>
<script>
var endpoint = 'https://explorer.testnet.z.cash';
var connectionType = 'polling';
var address = 'tmHyHq7Ec5oPXBDdyfDHAuqWphwEXxK5yZ9';
var socket = io(endpoint, {transports: [connectionType]})

socket.on('bitcoind/addresstxid', function() {alert('Saw a transaction!');});
socket.emit('subscribe', 'bitcoind/addresstxid', [address]);
</script>

Doesn't work.

Note that notifications in general work. This will alert at each block.

<script src="https://cdn.socket.io/socket.io-1.4.5.js"></script>
<script>
var endpoint = 'https://explorer.testnet.z.cash';
var connectionType = 'polling';
var socket = io(endpoint, {transports: [connectionType]})

socket.on('bitcoind/hashblock', function() {alert('Saw a block!');});
socket.emit('subscribe', 'bitcoind/hashblock');
</script>
@karelbilek
Copy link
Author

(This is currently blocking mytrezor integration, since we use these notifications.)

@karelbilek
Copy link
Author

as I wrote to slack - my bet is it's some combination of multibyte prefixes and zmq (that are used by notifications)

@str4d
Copy link
Owner

str4d commented Oct 28, 2016

Looking at this now.

@karelbilek
Copy link
Author

karelbilek commented Nov 1, 2016

For what it's worth, I just tried the same thing with waterhole.io and their zcash bitcore (and livenet zcash), and it seems there is the same issue there.

So it is 90% with the code and not with the deployment.

@karelbilek
Copy link
Author

It's fixed here - I tested it on my private server, it fixes the issue and notifications arrive

str4d/bitcore-lib-zcash#1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants