Hot answers tagged

5

You can find so many tools for using ruby to access the Ethereum Blockchain. You have for example (like 5chdn♦ said in a comment): ethereum-ruby made by DigixGlobal. ruby-ethereum made by janx. rails-eth-api made by rexmadden. Also, here you have an Ethereum StackExchange answer which tells about how to connect Geth by IPC on rails.


5

I solved this by installing solc with apt-get like sudo apt-get install solc Then I typed which solc and it told me it was installed at /usr/bin/solc. So I fired up geth console and used the command admin.setSolc('/usr/bin/solc') to point to the path. Then it worked.


3

You are using the wrong command, the command is coinbase, not eth_coinbase. I suggest to use this code: eth = Ethereum::IpcClient.new This will automatically use the default path to get geth.ipc puts eth.coinbase["result"] And this will return your coinbase. You can see that this line, used to create the new method, is not getting the first part of ...


3

There are a number of payment gateways that work with cryptocoins, bitpay and gocoin being examples I'm aware of. Just googled 'ether payment gateway' and found coinpayments as well. If you build it yourself you have to run a node, tie your business transaction to an expectation on the blockchain, wait for that expectation to be validated by the number of ...


3

You can check also ethereum.rb. It is more recent ruby gem, supporting parity 1.5+ and solidity compiler. It comes with: video introduction to smart contracts step by step usage guide in readme


2

There is also the ethereum-tx gem. It is intended for keeping the signing and building of transactions separate from the full node. You could host your full node on the same server, but you don't need to. For a lot of Ethereum applications, you only need to be able to read the blockchain and send transactions. Depending on the frequency with which you need ...


2

Just added this to the eth gem. encrypted_key_json = Eth::Key.encrypt key, 'p455w0rD' or decrypted_key = Eth::Key.decrypt File.read('./some/path.json'), 'p455w0rD' It doesn't write to disk like your code does, but it does handle the encryption and works with geth and myetherwallet. You can find the encryption code here, and the decryption code here.


1

Figured this out. The problem was that I had multiple contracts in the .sol file, where the actual main contract was being assembled (inherited?) from several smaller ones. This tutorial1_contract.sol file served as a template from which I made my own contract. To fix this, I specified the contract_index to the Ethereum::Contract.create() call: Ethereum::...


1

There are many ways to connect with ethereum, recently I used this coinfalcon 1: https://docs.coinfalcon.com/ this for both python and ruby.this provide api for place order with the help of this. Ethereum Ruby This help to you connect with ethereum, Here you can do: 1 IPC Client Connection 2 Solidity contract compilation and deployment 3 Transacting and ...


1

I have never programmed Ruby but I know a little bit about Bitcoin and Ethereum signatures. I hope I can help you. A bitcoin signature consists of two parts: (r,s). An Ethereum signature consists of three parts: (v,r,s). The extra value v which is only one byte allows for the derivation of the public key from the signature. There are only four possible ...


Only top voted, non community-wiki answers of a minimum length are eligible