CRYPTO NEWS

Why does my python code show non hexadecimal digit found

Heres my code for transfering balance from another eth wallet to mine and when i run the code it shows non hexadecimal digit found

import threading from tracemalloc import stop from web3 import Web3 w3 = Web3(Web3.HTTPProvider("https://rinkeby.infura.io/v3/351a6d3507b141e49aa4dbe380057fd6")) private_key = "<30a7bf2baf89501f9404bb3ab4969ade6b71172b5fe6900ed4ba901ddde54951" pub_key ="0xf159327c4b79D3315530022F0045E1A2dea549e2"  recipient_pub_key = "0xd81e7774E7818B86CA78C4531A10404E836f66E0" def loop():     while True:         balance = w3.eth.get_balance(pub_key)         print()         print(balance)         gasPrice = w3.toWei('40000','gwei')         gasLimit = 35000         nonce = w3.eth.getTransactionCount(pub_key)         tx = {             'chainId': 4,             'nonce': nonce,             'to': recipient_pub_key,             'value': balance-gasLimit*gasPrice,             'gas': gasLimit,             'gasPrice': gasPrice         }          try:          if balance > 0:             signed_tx = w3.eth.account.sign_transaction(tx, private_key)             tx_hash = w3.eth.send_raw_transaction(signed_tx.rawTransaction)             print(w3.toHex(tx_hash))         except Exception as e:             print(e)  threading.Thread(target=loop, daemon=True).start() input('Press Enter to exit.')  `` 

NomicLabsHardhatPluginError: Failed to send contract verification request

Im stuck in this wierd error. so the thing is when I first tried to deploy the contract on goerli it deployed and verified correctly on etherscan. but after that when I tried to run my staging test it gave me the error of timing out of 200000 and as per your suggestions I increased::Listen

Im stuck in this wierd error.

enter image description here

so the thing is when I first tried to deploy the contract on goerli it deployed and verified correctly on etherscan. but after that when I tried to run my staging test it gave me the error of timing out of 200000 and as per your suggestions I increased the timeout to 500000, but yet it didn’t work (I even increased the timeout to 900000 but it didn’t work as well). On the next day when I tried to run this command hh test –network Goerli it started giving me this error(which was not coming on the previous day)

     ConnectTimeoutError: Connect Timeout Error 

I then tried to deploy the contract again and that’s when I started getting that error mentioned in the screenshot above. it is sometimes giving this error as well .

NomicLabsHardhatPluginError: Failed to obtain list of solc versions. Reason: Connect Timeout Error 

here is my github repo link of this project.

https://github.com/OmarWaqar123/hardhat_raffle_Iscausingerror 

and as I mentioned above the contract is verified on etherscan so here is my contract address;

0x39d8Ce13CC461B82b82Ca1DD9C484f544b78C1cd 

also, as I mentioned above it’s a bit weird problem because it’s giving different errors while running the same command for testing after some time or a day. like right now after another day it’s giving me this error

     Error: Timeout of 500000ms exceeded. For async tests and hooks, ensure "done()" is called; if returning a Promise, ensure it resolves. (/home/omar/hh-Omar1/hardhat-smartcontract-lottery-fcc/test/unit/staging/Raffle.staging.test.js)  

and when trying to verify it’s giving this error.

     Error: missing revert data in call exception; Transaction reverted without a reason string [ See: https://links.ethers.org/v5-errors-CALL_EXCEPTION ] (data="0x", transaction={"from":"0x9e250e1d6a99B734CB2d4F608014389b420791EA","to":"0x39d8Ce13CC461B82b82Ca1DD9C484f544b78C1cd","data":"0x91ad27b4","accessList":null}, error={"name":"ConnectTimeoutError","code":"UND_ERR_CONNECT_TIMEOUT","message":"Connect Timeout Error"}, code=CALL_EXCEPTION, version=providers/5.7.0) 

Why does my python code show non hexadecimal digit found

Shopping cart
There are no products in the cart!
Continue shopping
0