#StackBounty: #go-ethereum #web3js #events #websocket #healthcheck Healtcheck on Websocket

Bounty: 50

I try to find that in the documentation but no success..

I would like to know the best way to do an healthcheck on my websocket connection to geth (Yesterday, I discover that I did not receive the new event since few days without any reason).

I did a custom stuff but I don’t think this a best practice :/

const web3 = new Web3(new Web3.providers.WebsocketProvider(networkUri));

setInterval(() => {
  console.log('Check WS status');
  let subscription;
  new Promise((resolve, reject) => {
    subscription = web3.eth.subscribe('pendingTransactions')
      .on('data', function () {
        return resolve(true);
      })
      .on('error', function () {
        return reject(false);
      });
  })
    .then(() => {
      console.log('OK');
    })
    .catch(() => {
      console.log('NOK');
      reconnect();
    })
    .finally(() => {
      // unsubscribes the subscription
      subscription.unsubscribe(function (error, success) {
        if (success)
          console.log('Successfully unsubscribed!');
      });
    })
}, 30000);

Regards


Get this bounty!!!

#StackBounty: #go-ethereum #web3js web3.eth.subscribe not working?

Bounty: 50

Running geth with websocket:

geth --fast --cache=512 --ws --wsorigins="*" --wsapi "db,eth,net,ssh,miner,web3,personal,admin"

Then connecting with web3 in a Node.js app:

const Web3 = require('web3');

var web3 = new Web3(new Web3.providers.WebsocketProvider("ws://localhost:8546"));

console.log(web3.version);

web3.eth.subscribe('pendingTransactions', function(err, res) {
    console.log('Here')
    console.log(err)
    console.log(res)
}).on('data', function(transaction) {
    console.log('Here 2')
    console.log(transaction)
});

“Here”, “Here 2” do not print to the console. The subscription does not seem to activate. web3.version and other web3 commands work fine.


Geth version: 1.7.1-stable

Web3 version: 1.0.0-beta.22


Get this bounty!!!

#StackBounty: #go-ethereum #mining #coinbase how do i cash out mined ethereum?

Bounty: 50

I’ved tried my luck on ethereum mining with this https://github.com/angelomilan/ethereum-guides/blob/master/GPU-cloud_mining.md
And I think I have some ethereum.

> eth.getBalance(eth.coinbase).toNumber();
5000000000000000000
> web3.fromWei(eth.getBalance(eth.coinbase), "ether")
5

UPDATE:
I tried to send using this but has this error:

eth.sendTransaction({from:eth.accounts[0], to:"0x21389ab987979ae987", value: web3.toWei(0.0005, "ether"), gas:5000})

Error: intrinsic gas too low


> eth.getBlock("latest").gasLimit
5003

> net.peerCount
0

What is intrinsic gas too low and how to solve this, my gasLimit is 5003. What is all this and how to I would say pump more gas ?

My question is now how do I convert it to cash ? I cant figure that out. I believe on the .ethereum hidden folder contains the coinbase wallet. How do I then cash it out ?


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!

#StackBounty: #solidity #go-ethereum #string Send request failed { code: -32602, message: 'invalid argument 0: json: cannot unmarsh…

Bounty: 50

I am new to ethereum and deploying my first contract with simple method getting following error:

[2018-03-24 11:08:14.364] [ERROR] ipcProviderBackend - Send request failed { code: -32602,
  message: 'invalid argument 0: json: cannot unmarshal non-string into Go value of type common.Hash' }

Following is the contract method in solidity that i am calling:

function testContract(string title,string _description,
                           address _contractAddressOfAsset,
                           string _recordIdOfAsset,
                           uint _deadline,
                           uint _startingPrice,
                           uint _reservePrice,
                           uint _distributionCut,
                           address _distributionCutAddress) public returns (bool k) {


        test=title;
        return true;
    }

Here ,
test is the global variable of type string.

Note: I have deployed this contract in the private network and this contract from the mist browser

Following are the version details of geth:

Geth
Version: 1.7.3-stable
Git Commit: 4bb3c89d44e372e6a9ab85a8be0c9345265c763a
Architecture: amd64
Protocol Versions: [63 62]
Network Id: 1
Go Version: go1.9
Operating System: linux
GOPATH=
GOROOT=/usr/lib/go-1.9


Get this bounty!!!