@@ -633,9 +633,9 @@ def estimateGas(
633633 self .check_forbidden_keys_in_transaction (estimate_gas_transaction ,
634634 ["data" , "to" ])
635635
636- if self .web3 .eth .defaultAccount is not empty :
637- # type ignored b/c check prevents an empty defaultAccount
638- estimate_gas_transaction .setdefault ('from' , self .web3 .eth .defaultAccount ) # type: ignore # noqa: E501
636+ if self .web3 .eth .default_account is not empty :
637+ # type ignored b/c check prevents an empty default_account
638+ estimate_gas_transaction .setdefault ('from' , self .web3 .eth .default_account ) # type: ignore # noqa: E501
639639
640640 estimate_gas_transaction ['data' ] = self .data_in_transaction
641641
@@ -652,9 +652,9 @@ def transact(self, transaction: Optional[TxParams] = None) -> HexBytes:
652652 self .check_forbidden_keys_in_transaction (transact_transaction ,
653653 ["data" , "to" ])
654654
655- if self .web3 .eth .defaultAccount is not empty :
656- # type ignored b/c check prevents an empty defaultAccount
657- transact_transaction .setdefault ('from' , self .web3 .eth .defaultAccount ) # type: ignore
655+ if self .web3 .eth .default_account is not empty :
656+ # type ignored b/c check prevents an empty default_account
657+ transact_transaction .setdefault ('from' , self .web3 .eth .default_account ) # type: ignore
658658
659659 transact_transaction ['data' ] = self .data_in_transaction
660660
@@ -674,9 +674,9 @@ def buildTransaction(self, transaction: Optional[TxParams] = None) -> TxParams:
674674 self .check_forbidden_keys_in_transaction (built_transaction ,
675675 ["data" , "to" ])
676676
677- if self .web3 .eth .defaultAccount is not empty :
678- # type ignored b/c check prevents an empty defaultAccount
679- built_transaction .setdefault ('from' , self .web3 .eth .defaultAccount ) # type: ignore
677+ if self .web3 .eth .default_account is not empty :
678+ # type ignored b/c check prevents an empty default_account
679+ built_transaction .setdefault ('from' , self .web3 .eth .default_account ) # type: ignore
680680
681681 built_transaction ['data' ] = self .data_in_transaction
682682 built_transaction ['to' ] = Address (b'' )
@@ -933,9 +933,9 @@ def call(
933933
934934 if self .address :
935935 call_transaction .setdefault ('to' , self .address )
936- if self .web3 .eth .defaultAccount is not empty :
937- # type ignored b/c check prevents an empty defaultAccount
938- call_transaction .setdefault ('from' , self .web3 .eth .defaultAccount ) # type: ignore
936+ if self .web3 .eth .default_account is not empty :
937+ # type ignored b/c check prevents an empty default_account
938+ call_transaction .setdefault ('from' , self .web3 .eth .default_account ) # type: ignore
939939
940940 if 'to' not in call_transaction :
941941 if isinstance (self , type ):
@@ -975,9 +975,9 @@ def transact(self, transaction: Optional[TxParams] = None) -> HexBytes:
975975
976976 if self .address is not None :
977977 transact_transaction .setdefault ('to' , self .address )
978- if self .web3 .eth .defaultAccount is not empty :
979- # type ignored b/c check prevents an empty defaultAccount
980- transact_transaction .setdefault ('from' , self .web3 .eth .defaultAccount ) # type: ignore
978+ if self .web3 .eth .default_account is not empty :
979+ # type ignored b/c check prevents an empty default_account
980+ transact_transaction .setdefault ('from' , self .web3 .eth .default_account ) # type: ignore
981981
982982 if 'to' not in transact_transaction :
983983 if isinstance (self , type ):
@@ -1017,9 +1017,9 @@ def estimateGas(
10171017
10181018 if self .address :
10191019 estimate_gas_transaction .setdefault ('to' , self .address )
1020- if self .web3 .eth .defaultAccount is not empty :
1021- # type ignored b/c check prevents an empty defaultAccount
1022- estimate_gas_transaction .setdefault ('from' , self .web3 .eth .defaultAccount ) # type: ignore # noqa: E501
1020+ if self .web3 .eth .default_account is not empty :
1021+ # type ignored b/c check prevents an empty default_account
1022+ estimate_gas_transaction .setdefault ('from' , self .web3 .eth .default_account ) # type: ignore # noqa: E501
10231023
10241024 if 'to' not in estimate_gas_transaction :
10251025 if isinstance (self , type ):
0 commit comments