From 6aa053728fa0a0ec5372dbfeb9131ea872771d8f Mon Sep 17 00:00:00 2001
From: Robert Martin-Legene <robert@martin-legene.dk>
Date: Tue, 30 Mar 2021 21:11:07 -0300
Subject: [PATCH] parches

---
 bin/libbfa/__init__.py      | 10 +++++-----
 bin/libbfa/requirements.txt |  1 +
 2 files changed, 6 insertions(+), 5 deletions(-)

diff --git a/bin/libbfa/__init__.py b/bin/libbfa/__init__.py
index 61f8f96..a57c900 100755
--- a/bin/libbfa/__init__.py
+++ b/bin/libbfa/__init__.py
@@ -181,20 +181,20 @@ class Account:
         signed = web3.Web3().eth.account.sign_transaction(tx, self.key)
         return signed
 
-    # if kwargs has extragas=50000 then we add that number to the amount
-    # of gas for the transaction
     def calculate_tx_details(self, w3: web3.Web3, *args, **kwargs) -> dict:
-        # Nonce may have increase on the network without us noticing
+        # if kwargs has extragas=50000 then we add that number to the amount
+        # of gas for the transaction
+        afunction = kwargs.get('function')
+        # Nonce may have increased on the network without us noticing
         # or past transactions may not yet have been mined (and a flooded
         # txpool).
         # This is a resonable fix (try not to send too many transactions)
         # If you use waitForTransactionReceipt() between each transaction
         # you will not have problems because of this.
-        afunction = kwargs.get('function')
         self.nonce = max(self.nonce, w3.eth.getTransactionCount(self.address))
         # Set minimum gasPrice to 1 Gwei, but allow more if the network says so.
         details = {
-            'chainId': w3.eth.chain_id(),
+            'chainId': w3.eth.chain_id,
             'gasPrice': min(w3.toWei('1', 'gwei'), w3.eth.gasPrice),
             'nonce': self.nonce,
             'from': self.address,
diff --git a/bin/libbfa/requirements.txt b/bin/libbfa/requirements.txt
index 08b1a03..4a94107 100644
--- a/bin/libbfa/requirements.txt
+++ b/bin/libbfa/requirements.txt
@@ -2,3 +2,4 @@ web3
 rusty-rlp
 ecdsa
 Crypto
+dnspython
-- 
GitLab