Hot answers tagged

5

This is described in web3py Documentation Once you have your provider set and web3 instantiates you can do: signed_txn = w3.eth.account.signTransaction(dict( nonce=w3.eth.getTransactionCount('yourAddress'), gasPrice = w3.eth.gasPrice, gas = 100000, to='recipientAddress', value=web3.toWei(12345,'ether') ), 'yourprivatekey') w3.eth....


3

Yes you can, follow below steps: Write a smart contract, Deploy smart contract in Eth network Use web3.py to integrate/call smart contract/eth method's Documentation SDK


3

I managed to make it work by running geth --genesis customGenesis.json --rpc --rpcport "9012" --rpcaddr "0.0.0.0" --rpccorsdomain "*" --datadir testchain --networkid 1234 console From what I understood, this works but it's less secure. I would like to find a safer way of doing it. Also, I had to change something in the script part which is now <!------...


2

You cannot run more than one program to listen and serve on a single port on the same computer: If you want to serve your Apache web page on the port 9002, choose another port for geth to serve it's RPC requests on. For example, use port 9001 for geth RPC: geth --genesis customGenesis.json \ --rpc --rpcaddr "146.169.45.149" --rpcport "...


2

ChainID was introduced in EIP-155 to prevent replay attacks between the main ETH and ETC chains, which both have a networkID of 1. For the Ethereum Mainnet the ChainID is 1 you can check the ChainId on the table at the end of EIP-155 When you create a new wallet with pywallet the output shows you the private key you can see this in the documentation


1

The following script fetches blocks and filters transactions to/from the given address. You can modify it to suit your needs. #!/usr/bin/python import argparse import json import web3 from web3 import Web3 from hexbytes import HexBytes # Exports transactions to a JSON file where each line # contains the data returned from the JSONRPC interface provider = ...


1

This is hard to debug without seeing your actual code. If it's falling over on the require line it's most likely failing to load the web3 javascript file, or loading it after you've placed your script. Look in the developer console of your browser and see if it's telling you anything, and also whether it's making the network requests for the JavaScript files ...


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